Uploaded image for project: 'Beam'
  1. Beam
  2. BEAM-3132

elasticsearch Bad Request during ConnectionConfiguration create

    XMLWordPrintableJSON

    Details

    • Type: Bug
    • Status: Open
    • Priority: Trivial
    • Resolution: Unresolved
    • Affects Version/s: 2.1.0
    • Fix Version/s: None
    • Component/s: io-java-elasticsearch
    • Labels:
      None
    • Environment:
      docker

      Description

      I am getting the following when connecting to a elastic search instance
      Runner: Spark

      code
      {{ ConnectionConfiguration connectionConfiguration = ConnectionConfiguration.create(new String[]

      {"http://elasticsearch:9200"}

      ,"bigindex_write","bigindex");
      }}
      Error
      {{FATAL: Connection to elasticsearch elasticsearch:9200 failedNov 01, 2017 1:13:15 PM .listener.Kafka2Elastic main
      SEVERE: FATAL: Connection to elasticsearch elasticsearch:9200 failed
      org.elasticsearch.client.ResponseException: GET http://elasticsearch:9200/: HTTP/1.1 400 Bad Request
      {"error":{"root_cause":[

      {"type":"illegal_argument_exception","reason":"empty headers are not allowed []"}

      ],"type":"illegal_argument_exception","reason":"empty headers are not allowed []"},"status":400}
      at org.elasticsearch.client.RestClient$1.completed(RestClient.java:310)
      at org.elasticsearch.client.RestClient$1.completed(RestClient.java:299)
      at org.apache.http.concurrent.BasicFuture.completed(BasicFuture.java:119)
      at org.apache.http.impl.nio.client.DefaultClientExchangeHandlerImpl.responseCompleted(DefaultClientExchangeHandlerImpl.java:177)
      at org.apache.http.nio.protocol.HttpAsyncRequestExecutor.processResponse(HttpAsyncRequestExecutor.java:436)
      at org.apache.http.nio.protocol.HttpAsyncRequestExecutor.inputReady(HttpAsyncRequestExecutor.java:326)
      at org.apache.http.impl.nio.DefaultNHttpClientConnection.consumeInput(DefaultNHttpClientConnection.java:265)
      at org.apache.http.impl.nio.client.InternalIODispatch.onInputReady(InternalIODispatch.java:81)
      at org.apache.http.impl.nio.client.InternalIODispatch.onInputReady(InternalIODispatch.java:39)
      at org.apache.http.impl.nio.reactor.AbstractIODispatch.inputReady(AbstractIODispatch.java:114)
      at org.apache.http.impl.nio.reactor.BaseIOReactor.readable(BaseIOReactor.java:162)
      at org.apache.http.impl.nio.reactor.AbstractIOReactor.processEvent(AbstractIOReactor.java:337)
      at org.apache.http.impl.nio.reactor.AbstractIOReactor.processEvents(AbstractIOReactor.java:315)
      at org.apache.http.impl.nio.reactor.AbstractIOReactor.execute(AbstractIOReactor.java:276)
      at org.apache.http.impl.nio.reactor.BaseIOReactor.execute(BaseIOReactor.java:104)
      at org.apache.http.impl.nio.reactor.AbstractMultiworkerIOReactor$Worker.run(AbstractMultiworkerIOReactor.java:588)
      at java.lang.Thread.run(Thread.java:748)
      }}

        Attachments

          Activity

            People

            • Assignee:
              Unassigned
              Reporter:
              orjan.lundberg@gmail.com ORJAN LUNDBERG
            • Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

              • Created:
                Updated: