# JDBC input is not working when added with Kafka input

**URL:** https://discuss.elastic.co/t/jdbc-input-is-not-working-when-added-with-kafka-input/279221
**Category:** Logstash
**Created:** [July 21, 2021, 3:50am UTC](https://discuss.elastic.co/t/jdbc-input-is-not-working-when-added-with-kafka-input/279221 "2021-07-21T03:50:33Z")
**Posts on this page:** 5
**Page:** 1

<div class="post-metadata">

### Author: ![adityaPsl](https://avatars.discourse-cdn.com/v4/letter/a/e47c2d/32.png) [@adityaPsl](https://discuss.elastic.co/u/adityaPsl)
#### Post date: [July 21, 2021, 3:50am UTC](https://discuss.elastic.co/t/jdbc-input-is-not-working-when-added-with-kafka-input/279221/1 "2021-07-21T03:50:33Z")

</div>

Hello Team,

I am trying to configure multiple inputs in a pipeline

```auto
input {
  jdbc {
  }
  kafka {
  }
  kafka {
  }
}

```

but when i run the pipeline only kafka messages i am getting and jdbc input is not working.  
Could you please help me understand if we can have different types of inputs in single pipeline.

Thank you ,  
Aditya

---

<div class="post-metadata">

### Author: ![AquaX](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/aquax/32/92006_2.png) [@AquaX](https://discuss.elastic.co/u/AquaX)
#### Post date: [July 21, 2021, 3:29pm UTC](https://discuss.elastic.co/t/jdbc-input-is-not-working-when-added-with-kafka-input/279221/2 "2021-07-21T15:29:27Z")

</div>

You should consider setting up multiple pipelines.

> **[Multiple Pipelines | Logstash Reference \[7.13\] | Elastic](https://www.elastic.co/guide/en/logstash/current/multiple-pipelines.html)**

---

<div class="post-metadata">

### Author: ![adityaPsl](https://avatars.discourse-cdn.com/v4/letter/a/e47c2d/32.png) [@adityaPsl](https://discuss.elastic.co/u/adityaPsl)
#### Post date: [July 21, 2021, 5:52pm UTC](https://discuss.elastic.co/t/jdbc-input-is-not-working-when-added-with-kafka-input/279221/3 "2021-07-21T17:52:02Z")

</div>

Thank you @AquaX for your reply.  
Yes, i am considering that, just one thing, I want to reuse same filter and ouput section,, even I am looking at sending data from one pipeline to another pipeline , but it is again just taking one input section to another file, so was thinking of adding jdbc section to the same input section.  
any thoughts, on this approach

---

<div class="post-metadata">

### Author: ![AquaX](https://sea2.discourse-cdn.com/elastic/user_avatar/discuss.elastic.co/aquax/32/92006_2.png) [@AquaX](https://discuss.elastic.co/u/AquaX)
#### Post date: [July 21, 2021, 9:08pm UTC](https://discuss.elastic.co/t/jdbc-input-is-not-working-when-added-with-kafka-input/279221/4 "2021-07-21T21:08:23Z")

</div>

I think the problem is that the kafka and jdbc input plugins both work differently. The JDBC works on a schedule while the kafka does not.  
I'm sure you can get them to work but you may need to set a schedule for the JDBC plugin and then wait for that to execute.  
The pipeline-pipeline communication could work as well. Check out this example:

> **[Pipeline-to-Pipeline Communication | Logstash Reference \[7.13\] | Elastic](https://www.elastic.co/guide/en/logstash/current/pipeline-to-pipeline.html#collector-pattern)**

---

<div class="post-metadata">

### Author: ![system](https://us1.discourse-cdn.com/elastic/original/3X/1/a/1ac57faf039f6b580b3f104ef42a2a89e41014de.png) [@system](https://discuss.elastic.co/u/system)
#### Post date: [August 18, 2021, 9:08pm UTC](https://discuss.elastic.co/t/jdbc-input-is-not-working-when-added-with-kafka-input/279221/5 "2021-08-18T21:08:49Z")

</div>

This topic was automatically closed 28 days after the last reply. New replies are no longer allowed.
