Spring

 Is there any proper documentation on Spring Integration Java DSL?

praveen buya's profile image
praveen buya posted Jun 25, 2020 06:47 PM

We are looking for Outbound oracle database integration using spring integration , where we will have multiple oracle databases(50+) and based on some condition we have to insert records into particular database from either of 50+ databases. We are looking for an option using Spring Integration but we did not find proper source to achieve using this with SI java DSL.

Daniel Mikusa's profile image
Daniel Mikusa

There's quite a bit of docs on the Java DSL here -> https://docs.spring.io/spring-integration/docs/5.3.1.RELEASE/reference/html/dsl.html#java-dsl

 

You can also find the JDBC related docs here, although the examples on this page are using XML -> https://docs.spring.io/spring-integration/docs/5.3.1.RELEASE/reference/html/jdbc.html#jdbc

 

If you want to see how to do something with the Java DSL, you just need to cross reference. For example, if I want to see how to use the JDBC inbound channel adapter, you can look at the Java DSL instructions for defining an inbound channel adapter and apply that to your particular channel adapter (applying usually means just creating an instance of the right object).

 

https://docs.spring.io/spring-integration/docs/5.3.1.RELEASE/reference/html/dsl.html#java-dsl-inbound-adapters

 

-------

 

I think the tricky part about your question is the large number of data sources that you're going to need to define. My understanding is that the JDBC related SI components are based around working with a single data source. In theory, you could create 50 data sources and associated SI components, but I'm guessing that probably wouldn't be too efficient. 50 data source pools along is going to be a lot of overhead. I think you're going to need to think through how you want that to work exactly.

 

Hope that helps!

praveen buya's profile image
praveen buya

@Daniel Mikusa - Tanzu Support​ Thanks for your response, i will give it a try and keep you posted on this approach. Thanks again for your help.