Uploaded image for project: 'Camel'
  1. Camel
  2. CAMEL-12774

Error during type conversion from type: java.lang.String to the required type: org.elasticsearch.action.update.UpdateRequest

    XMLWordPrintableJSON

    Details

    • Estimated Complexity:
      Unknown

      Description

      When I try to update es document using Update method of camel-elasticsearch-rest endpoint I got this error

      Caused by: org.apache.camel.TypeConversionException: Error during type conversion from type: java.lang.String to the required type: org.elasticsearch.action.update.UpdateRequest with value {teststringupdate-key2=teststringupdate-value2} due java.lang.IllegalArgumentException: The number of object passed must be even but was [1]

      This is because method doc(java.lang.String source) org.elasticsearch.action.update does not exist in

      <elasticsearch-rest-version>6.1.1</elasticsearch-rest-version>.

      In attach you can see test for this issue.

        Attachments

        1. ElasticsearchUpdateStringTest.java
          1 kB
          Ivan Bolshakov
        2. ElasticsearchGetSearchDeleteExistsUpdateTest.java
          4 kB
          Ivan Bolshakov

          Activity

            People

            • Assignee:
              acosentino Andrea Cosentino
              Reporter:
              johnbolshakov Ivan Bolshakov
            • Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: