Posts

Showing posts with the label talend

Talend ESB: query a database directly in the mediation perspective

Image
When exposing a database as a REST or SOAP service, lot of users use: the integration perspective to create a service, but they don’t leverage Camel the mediation perspective to create a route containing a cTalendJob However, there’s an easy alternative. Using the mediation perspective, we can use directly a datasource exposed in the runtime (Karaf) as an OSGi service, and directly use Camel components. The advantages of this approach are: The same DataSource is shared by different routes and services. It means that we can use a PooledDataSource and optimize the connections to the database. We don’t use any Talend job, and directly leverage Camel native components. Route design in the studio We create a route in the mediation perspective of the studio. First, in the Spring tab, we add the DataSource OSGi service lookup. To do so, we add the spring-osgi namespace and use the osgi:reference element: <beans .... xmlns:osgi="http://www.springframework.org/schem...

Talend ESB Continous Integration, part1: Using Camel Test Kit

Image
Introduction In this serie of articles, I will show how to setup a Continuous Integration solution mixing Talend ESB tools, Maven, and Jenkins. The purpose is to decouple the design (performed in the studio), the tests (both unit and integration tests), and the deployment of the artifacts. The developers that use the studio should never directly upload to the Maven repository (Archiva in my case). I propose to implement the following steps: the developers use the studio to design their routes: the metadata (used to generate the code) are stored in the subversion. The studio “only” checkouts and commits on subversion: it never directly upload to the artifact repository. a continuous integration tool (Jenkins in my case) uses Maven. The Maven POM leverages the Talend commandline (a studio without the GUI) to checkout, generate the code, and publish to the artifact repository. The Maven POM is also used to execute unit tests, eventually integration tests, and cleanly cut off th...