title: How to send data from HTTP input to ElasticSearch using Logstash ans jdbc_streaming filter?
body: <p>I want to send data from <strong>Http</strong> to <b>elasticsearch</b> using <b>logstash</b> and I want to enrich my data using <strong>jdbc_streaming</strong> filter plugin. This is my logstash config: <br></p>
  
  <pre><code>input {
    http {
      id =&gt; "sensor_data_http_input"
      user =&gt; "sensor_data"
      password =&gt; "sensor_data"
    }
  }
  
  filter {
    jdbc_streaming {
      jdbc_driver_library =&gt; "E:\ElasticStack\mysql-connector-java-8.0.18\mysql-connector-java-8.0.18.jar"
      jdbc_driver_class =&gt; "com.mysql.jdbc.Driver"
      jdbc_connection_string =&gt; "jdbc:mysql://localhost:3306/sensor_metadata"
      jdbc_user =&gt; "elastic"
      jdbc_password =&gt; "hide"
      statement =&gt; "select st.sensor_type as sensorType, l.customer as customer, l.department as department, l.building_name as buildingName, l.room as room, l.floor as floor, l.location_on_floor as locationOnFloor, l.latitude, l.longitude from sensors s inner join sensor_type st on s.sensor_type_id=st.sensor_type_id inner join location l on s.location_id=l.location_id where s.sensor_id= :sensor_identifier"
      parameters =&gt; { "sensor_identifier" =&gt; "sensor_id"}
      target =&gt; lookupResult
    }
    mutate {
      rename =&gt; {"[lookupResult][0][sensorType]" =&gt; "sensorType"}
      rename =&gt; {"[lookupResult][0][customer]" =&gt; "customer"}
      rename =&gt; {"[lookupResult][0][department]" =&gt; "department"}
      rename =&gt; {"[lookupResult][0][buildingName]" =&gt; "buildingName"}
      rename =&gt; {"[lookupResult][0][room]" =&gt; "room"}
      rename =&gt; {"[lookupResult][0][floor]" =&gt; "floor"}
      rename =&gt; {"[lookupResult][0][locationOnFloor]" =&gt; "locationOnFloor"}
  
      add_field =&gt; {
              "location" =&gt; "%{lookupResult[0]latitude},%{lookupResult[0]longitude}"
          }
  
      remove_field =&gt; ["lookupResult", "headers", "host"]
    }
  }
  
  output {
    elasticsearch {
      hosts =&gt;["localhost:9200"]
      index =&gt; "sensor_data-%{+YYYY.MM.dd}"
      user =&gt; "elastic"
      password =&gt; "hide"
    }
  }
  </code></pre>
  
  <p>But when I start logstash, I see following error: <br>
  <br></p>
  
  <pre><code>[2020-01-09T22:57:16,260]
  [ERROR][logstash.javapipeline]
  [main] Pipeline aborted due to error {
      :pipeline_id=&gt;"main", 
      :exception=&gt;#&lt;TypeError: failed to coerce jdk.internal.loader.ClassLoaders$AppClassLoader to java.net.URLClassLoader&gt;, 
      :backtrace=&gt;[
          "org/jruby/java/addons/KernelJavaAddons.java:29:in `to_java'", 
          "E:/ElasticStack/Logstash/logstash-7.4.1/vendor/bundle/jruby/2.5.0/gems/logstash-filter-jdbc_streaming-1.0.7/lib/logstash/plugin_mixins/jdbc_streaming.rb:48:in `prepare_jdbc_connection'", 
          "E:/ElasticStack/Logstash/logstash-7.4.1/vendor/bundle/jruby/2.5.0/gems/logstash-filter-jdbc_streaming-1.0.7/lib/logstash/filters/jdbc_streaming.rb:200:in `prepare_connected_jdbc_cache'", 
          "E:/ElasticStack/Logstash/logstash-7.4.1/vendor/bundle/jruby/2.5.0/gems/logstash-filter-jdbc_streaming-1.0.7/lib/logstash/filters/jdbc_streaming.rb:116:in `register'", "org/logstash/config/ir/compiler/AbstractFilterDelegatorExt.java:56:in `register'", 
          "E:/ElasticStack/Logstash/logstash-7.4.1/logstash-core/lib/logstash/java_pipeline.rb:195:in `block in register_plugins'", "org/jruby/RubyArray.java:1800:in `each'", 
          "E:/ElasticStack/Logstash/logstash-7.4.1/logstash-core/lib/logstash/java_pipeline.rb:194:in `register_plugins'", 
          "E:/ElasticStack/Logstash/logstash-7.4.1/logstash-core/lib/logstash/java_pipeline.rb:468:in `maybe_setup_out_plugins'", 
          "E:/ElasticStack/Logstash/logstash-7.4.1/logstash-core/lib/logstash/java_pipeline.rb:207:in `start_workers'", 
          "E:/ElasticStack/Logstash/logstash-7.4.1/logstash-core/lib/logstash/java_pipeline.rb:149:in `run'", 
          "E:/ElasticStack/Logstash/logstash-7.4.1/logstash-core/lib/logstash/java_pipeline.rb:108:in `block in start'"], 
      :thread=&gt;"#&lt;Thread:0x17fa8113 run&gt;"
  }
  [2020-01-09T22:57:16,598]
  [ERROR][logstash.agent] Failed to execute action {
      :id=&gt;:main, 
      :action_type=&gt;LogStash::ConvergeResult::FailedAction, 
      :message=&gt;"Could not execute action: PipelineAction::Create&lt;main&gt;, action_result: false", 
      :backtrace=&gt;nil
  }
  </code></pre>
  
  <p>I am enriching my http input with some data in my mysql database but it doesn't start logstash at all.</p>