Talend ESB
Talend ESB
5.6.2
Talend ESB
Copyleft
This documentation is provided under the terms of the Creative Commons Public License (CCPL). For more
information about what you can and cannot do with this documentation in accordance with the CCPL, please read:
http://creativecommons.org/licenses/by-nc-sa/2.0/
This document may include documentation produced at The Apache Software Foundation which is licensed under
The Apache License 2.0.
Notices
Talend and Talend ESB are trademarks of Talend, Inc.
Apache CXF, CXF, Apache Karaf, Karaf, Apache Cellar, Cellar, Apache Camel, Camel, Apache Maven, Maven,
Apache Archiva, Archiva, Apache Syncope, Syncope, Apache ActiveMQ, ActiveMQ, Apache Log4j, Log4j,
Apache Felix, Felix, Apache ServiceMix, ServiceMix, Apache Ant, Ant, Apache Derby, Derby, Apache Tomcat,
Tomcat, Apache ZooKeeper, ZooKeeper, Apache Jackrabbit, Jackrabbit, Apache Santuario, Santuario, Apache
DS, DS, Apache Avro, Avro, Apache Abdera, Abdera, Apache Chemistry, Chemistry, Apache CouchDB,
CouchDB, Apache Kafka, Kafka, Apache Lucene, Lucene, Apache MINA, MINA, Apache Velocity, Velocity,
Apache FOP, FOP, Apache HBase, HBase, Apache Hadoop, Hadoop, Apache Shiro, Shiro, Apache Axiom,
Axiom, Apache Neethi, Neethi, Apache WSS4J, WSS4J are trademarks of The Apache Foundation. Eclipse
Equinox is a trademark of the Eclipse Foundation, Inc. SoapUI is a trademark of SmartBear Software. Hyperic is
a trademark of VMware, Inc. Nagios is a trademark of Nagios Enterprises, LLC.
All other brands, product names, company names, trademarks and service marks are the properties of their
respective owners.
This product includes software developed at AOP Alliance (Java/J2EE AOP standards), ASM, AntlR, Apache
ActiveMQ, Apache Ant, Apache Avro, Apache Axiom, Apache Axis, Apache Axis 2, Apache Batik, Apache
CXF, Apache Camel, Apache Chemistry, Apache Common Http Client, Apache Common Http Core, Apache
Commons, Apache Commons Bcel, Apache Commons JxPath, Apache Commons Lang, Apache Derby Database
Engine and Embedded JDBC Driver, Apache Geronimo, Apache Hadoop, Apache Hive, Apache HttpClient,
Apache HttpComponents Client, Apache JAMES, Apache Log4j, Apache Lucene Core, Apache Neethi, Apache
POI, Apache Pig, Apache Qpid-Jms, Apache Tomcat, Apache Velocity, Apache WSS4J, Apache WebServices
Common Utilities, Apache Xml-RPC, Apache Zookeeper, Box Java SDK (V2), CSV Tools, DataStax Java Driver
for Apache Cassandra, Ehcache, Ezmorph, Ganymed SSH-2 for Java, Google APIs Client Library for Java, Google
Gson, Groovy, Guava: Google Core Libraries for Java, H2 Embedded Database and JDBC Driver, HsqlDB,
Ini4j, JClouds, JLine, JSON, JSR 305: Annotations for Software Defect Detection in Java, JUnit, Jackson Java
JSON-processor, Java API for RESTful Services, Jaxb, Jaxen, Jettison, Jetty, Joda-Time, Json Simple, MetaStuff,
Mondrian, OpenSAML, Paraccel JDBC Driver, PostgreSQL JDBC Driver, Resty: A simple HTTP REST client
for Java, Rocoto, SL4J: Simple Logging Facade for Java, SQLite JDBC Driver, Simple API for CSS, SshJ, StAX
API, StAXON - JSON via StAX, Talend Camel Dependencies (Talend), The Castor Project, The Legion of the
Bouncy Castle, W3C, Woden, Woodstox : High-performance XML processor, XML Pull Parser (XPP), Xalan-
J, Xerces2, XmlBeans, XmlSchema Core, Xmlsec - Apache Santuario, Zip4J, atinject, dropbox-sdk-java: Java
library for the Dropbox Core API, google-guice. Licensed under their respective license.
Table of Contents
Chapter 1. Introduction to Talend ESB solutions ............................................................ 1
1.1. Talend ESB Features . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2
1.1.1. Web Services Support . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 2
1.1.2. Standard OSGi Runtime . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 3
1.1.3. Messaging . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 4
1.1.4. Talend Studio . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 4
1.2. Talend ESB products and architecture . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7
1.2.1. Talend ESB Standard Edition (SE) . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 7
1.2.2. Talend Open Studio for ESB . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 8
1.2.3. Talend Enterprise ESB . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 10
1.2.4. Talend Platforms . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 12
Chapter 2. Getting started with Talend ESB ................................................................. 13
2.1. Prerequisites to using Talend ESB products . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 14
2.2. Downloading and installing the software . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 14
2.2.1. For the Community products . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 14
2.2.2. For the Enterprise and Platform products . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 15
2.3. Creating an alternate container for the Demos . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 15
2.4. Starting the software . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 16
2.4.1. Starting Talend Runtime . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 17
2.4.2. Starting the Talend Administration Center . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 18
2.4.3. Starting the Talend Studio . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 22
2.4.4. Starting the ESB dashboards . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 25
2.5. Software prerequisites for the Demos . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 26
Chapter 3. Basic deployment and runtime use cases ....................................................... 27
3.1. Building and deploying Data Services and Routes using the Studio . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 28
3.1.1. Building a simple SayHello data service . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 28
3.1.2. Accessing the events in the ESB Dashboards . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 40
3.1.3. SayHelloRoute example . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 42
3.2. Building and deploying REST Services using the Studio . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 47
3.2.1. Building a simple REST service . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 48
3.2.2. Deploying the REST service . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 60
3.2.3. Building a simple REST Service consumer . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 70
3.2.4. Accessing the events in the ESB Dashboards . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 75
3.3. Building and deploying Data Services and Routes using Java . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 76
3.3.1. The Rent-a-Car demo example . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 76
3.3.2. Deploying the demo . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 79
3.3.3. Running the demo . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 81
3.3.4. Uninstalling the demo . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 84
3.4. Importing the Rent-a-Car Java demo into Eclipse . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 85
3.4.1. Building the project files . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 85
3.4.2. Importing into Eclipse . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 85
3.4.3. Running the examples . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 85
Chapter 4. Advanced deployment and runtime use cases with SOA Governance ................ 87
4.1. Rent-a-Car demo using Service Locator and Service Activity Monitoring . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 88
4.1.1. Installing and starting the Service Locator and Service Activity Monitoring . . . . . . . . . . . . . . . . . . . . . . . . . . 88
4.1.2. Uninstalling previous features . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 90
4.1.3. Building the demo with Service Activity Monitoring and Service Locator enabled . . . . . . . . . . . . . . . . . . . 90
4.1.4. Installing the Rent-a-Car examples features . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 91
4.1.5. Running the demo in one container to generate Service Activity Monitoring data . . . . . . . . . . . . . . . . . . . . . 92
4.1.6. Running the demo in two containers - simulating server failover with Service Locator . . . . . . . . . . . . . . . 94
4.1.7. Accessing the events in the ESB Dashboards . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 96
4.1.8. Uninstalling the demo features . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 98
4.2. Rent-a-Car demo using the Security Token Service to provide WS-Security based SAML
Authentication . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 98
4.2.1. Configuring logging . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 98
4.2.2. Building the demo with Security enabled . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 99
4.2.3. Uninstalling the demo features . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 100
4.3. Rent-a-Car demo using the Artifact Repository . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 100
4.3.1. Downloading and installing Nexus Artifact Repository . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 101
4.3.2. Publishing the demo to the Artifact Repository . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 101
4.3.3. Deploying the demo to Talend ESB Standard Edition with Nexus Artifact Repository . . . . . . . . . . . . . . 103
4.3.4. Deploying the demo from Artifact Repository to Talend Runtime with Talend Administration
Center . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 103
4.4. Rent-a-Car demo using XKMS . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 106
4.4.1. Configuring the XKMS service for the demo . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 106
4.4.2. Building the Rent-a-Car demo example . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 107
4.5. Accessing all ESB event logs in Talend Administration Center . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . . 108
This chapter gives a high level overview of Talend ESB solutions, their components and features, including the
Talend Runtime, an OSGi container, the support for Web Services, and the Talend Studio.
It also describes the packages that are available, and details of the architecture of each of them.
Talend invests, promotes and nurtures the underlying technology of Talend ESB through its participation in
the Apache Software Foundation (ASF), a leading open source community recognized for its transparency and
for delivering enterprise-grade, freely available software products that are designed and built from a diverse
community of users. Increasingly, the open source communities—rather than the vendors of proprietary software
—are driving the next generation of innovations.
Leveraging Apache CXF, Apache Camel and Apache ActiveMQ open source integration projects, Talend ESB
makes enterprise-class integration accessible by delivering a cost-effective and easy-to-use way to integrate and
expand systems and applications.
An open source services framework, Apache CXF helps companies build and develop services using front-end
programming APIs like JAX-WS and JAX-RS.
Apache Camel is a powerful open source integration framework that lets you leverage EIPs to implement routing,
transformation and mediation rules.
Powered by Apache ActiveMQ, the most popular open source messaging provider, each message broker can
handle myriad connections while processing thousands of persistent messages per second.
Apache CXF provides a lightweight, modular architecture that is supported by the popular Spring Framework. So
it works with your application, regardless of the platform on which it is running. It can be run as:
Apache CXF supports all important Web services standards and fully complies to the Java API for XML Web
Services (JAX-WS) specification. JAX-WS defines annotations that allow you to tell a tool like CXF how
your standalone Java application should be represented in a Web services context. Two types of Web services
development with CXF are possible:
1. Contract-first development:
WSDLs define what operations and types a Web service provides. This is often referred to as a Web services
contract, and in order to communicate with a Web service, you must satisfy the contract. Contract-first
development means that you start out by writing a WSDL file (either by hand or with the help of tooling), and
then generating stub Java class implementations from the WSDL file by using a tool like CXF.
2. Code-first development:
The other way to develop Web services is by starting out with a Java class and then letting the Web service
framework handle the job of generating a WSDL contract for you. This is the easiest mode of development,
but it also means that the tool (CXF in this case) is in control of what the contract will be. When you want to
fine-tune your WSDL file, it may be better to go for contract-first approach.
Apache has been certified and tested to work with the broadest set of vendors’ Web services implementations.
Users benefit from this interoperability testing, which reduces the overall cost and complexity for application
integration.
Talend ESB supports the creation of SOAP and REST Web services and offers the best WS-* functionality in
the market, including support for WS- Addressing, WS-Reliable Messaging, and WS-Security over both HTTP
and JMS transports.
In addition, the Web services stack in Talend ESB distributions goes well beyond Apache CXF, with support for:
• Central deployment and configuration options via Web User Interfaces and JMX based APIs
• Hot deployment: Karaf monitors any file inside the [home]/deploy directory (for example: XML files to create
a database connection pool, Jar and Kar files for drivers, and so on). So if a file is copied into this directory,
it is automatically installed inside the runtime; subsequently this can be updated or deleted, and Karaf will act
correspondingly.
• Dynamic configuration: Services are usually configured through a standard OSGi service, using property files,
which are monitored; changes are propagated to the service.
• Managing instances: Karaf provides simple console commands for managing multiple instances.
• See Building and deploying Data Services and Routes using Java for an example of using Karaf. For further
information, please see the Talend ESB Container Administration Guide and http://karaf.apache.org/.
1.1.3. Messaging
Enterprise messaging software has been used for integration projects more than 30 years now. Not only is
messaging a style of communication between applications, it is also a widely adopted style of integration between
applications. Messaging fulfills the need for both notification and asynchronous, loosely coupled interoperation
between applications.
Talend ESB embeds Apache ActiveMQ message broker to support a number of different messaging options.
ActiveMQ is written in Java and implements the JMS specification. In addition to that, many other features
are added on top to provide high availability, performance, scalability, reliability, and security for enterprise
messaging.
The job of the message broker is to transport events between distributed applications, guaranteeing that they reach
their intended recipients. The broker therefore must be highly available, performant, and scalable for this goal,
which Apache ActiveMQ provides an easy to use way in Talend ESB, as it is embedded in Talend Runtime.
• an Integration perspective
• a Mediation perspective
The core of the Integration perspective comprises four major applications (Business Modeler, Job Designer,
Service Designer, and Metadata Manager) within a single graphical development environment based on Eclipse.
A Service in the 'Services' node is a Web-Service defined by a WSDL. The WSDL can be just imported, created
from scratch in the tooling using the embedded graphical WSDL editor or an existing WSDL can be imported
and then edited within the studio. In this case the Service is based on this WSDL information and each service
operation can then be implemented in the Job Design node.
A data service Job is a graphical design, of one or more components connected together, that allows you to set
up and run data service operations. Jobs address all of the different sources and targets that you need for data
integration processes and combine it with Web services.
Additionally, in Enterprise and Platform studios, you can use the shared repository feature to work in larger teams,
and share resources. It has the facility of team collaboration - team members can store and share their business
models, integration and service jobs, integration services and metadata in an industry-standard source manager
(SVN). This promotes reusability of objects and code, as well as facilitating the design of development best
practices. There are also more extended productivity features like Wizards (for example, for SAP) and deployment
options (Publish to artifact repository) available in those Talend Studios.
More information on this can be found in the Talend Studio User Guide.
Apache Camel
The Mediation functionality of Talend ESB is based on the popular Apache Camel project. The core of the Camel
framework is a routing engine. It allows you to define routing rules, that accept and send messages through
Components. There are no restrictions on the message format - for example, Java objects, XML, JSON, plain text
and so on, can be used. These routing rules are based on the book “Enterprise Integration Patterns” from Gregor
Hohpe; Bobby Woolf; et al.
Thus, Apache Camel is a framework allowing developers to assemble Endpoints / Processors into workflows
(Routes) to achieve higher level functionality. It facilitates application integration by leveraging Enterprise
Integration Patterns (EIPs) to essentially assemble scalable services, and make message-based system integration
simpler to design and implement. Camel is an open source Java framework that lets you use EIPs to implement
routing and mediation rules using a Java-based Domain Specific Language (DSL). This means you get completion
of routing rules that can easily and rapidly be updated if requirements change.
EIP and hence Camel are focused on asynchronous messaging patterns because asynchronous patterns are
necessary for scalability. But asynchronous messaging is more complex. Camel wraps that complexity in a
common framework which is widely understood by integration developers.
Because of the high-level abstractions in Camel (for example, Message, Exchange, Component, Endpoint), you
can use the same APIs to interact with various systems. For example, every route implements Component and
Endpoint APIs and works with the same basic Message and Exchange structure. Each component is implemented
to work with specific protocols and data types. So you can wire together very different protocols and system very
easily while using the same patterns and routing semantics.
Camel mediates both formats and transports between different endpoints. Typically, this allows Services to
communicate with each other, via Camel mediation, even if using different message formats, and written using
different languages. It also makes adding functionality like logging and tracking easy. Camel is also very
lightweight and can be embedded or deployed anywhere you like, such as in a standalone Java application, Web
application, or an OSGi bundle.
You can use the Java Domain Specific Language (DSL) to specify a route. For example:
From(“file:directory”).to(“jms:queuename”)
This simple statement polls files from a directory and sends the content of each file as a JMS message to a JMS
queue. This can be done because Camel provides a uniform interface based on the Exchange object. For that
matter, Camel is a really useful and powerful tool as it includes data formats and type converters for automatic
and easy message transformation. It can also be used to extract, transform and load the content of those files.
Mediation perspective
On top of Apache Camel, and integrated with the Talend Studio, the Route Builder (Mediation perspective) is a
GUI that allows a developer to build these Routes in a visual way.
You can run the Routes in a standalone mode or export them as OSGi Bundles which can be easily deployed
within the Talend Runtime container. Additionally in the Enterprise and Platform studios, you can use the shared
repository feature to work in larger teams.
Out of the box, Talend ESB supports over 80 protocols and data types, through its extensive library of components.
These components enable a Route to connect over transports, use APIs, and understand data formats. You can
also create your own components very easily; the component API is very concise. Talend ESB has a modular
architecture, which allows any component to be loaded into Camel, regardless of whether the component ships
with Camel, is from a third party, or is your own custom creation. The creation of your own components (for
example, for processing, connectivity, routing, and so on) is simple and well documented.
• Service Locator—Talend ESB Standard Edition provides automatic and transparent failover and load balancing
through a newly developed extension to Apache CXF that allows for dynamic endpoint registration and lookup
through Apache Zookeeper.
For more information, see Rent-a-Car demo using Service Locator and Service Activity Monitoring and the
Talend ESB Infrastructure Services Configuration Guide.
• Service Activity Monitoring—By capturing events and storing activity information, Talend ESB Standard
Edition facilitates more in-depth analysis of service activity, including service response times, traffic patterns,
service lifecycle and auditing.
For more information, see Rent-a-Car demo using Service Locator and Service Activity Monitoring and the
Talend ESB Infrastructure Services Configuration Guide.
• Security Token Service (STS) Framework—Talend ESB Standard Edition includes an STS Framework that
supports Security Assertion Markup Language (SAML 2.0) to federate security credentials across applications
and domains. This allows clients and services to securely and transparently authenticate during connections
without the need for custom coding. This STS Framework is another significant contribution that Talend has
made to the Apache CXF community.
For more information, see Rent-a-Car demo using the Security Token Service to provide WS-Security based
SAML Authentication and the Talend ESB Infrastructure Services Configuration Guide.
• The blue block represents a Talend Studio API where you can carry out data integration or data service processes,
mediation routes and services. For more information, see their corresponding chapters in the Talend Open Studio
for ESB User Guide.
• The other blocks represent Talend ESB Standard Edition which is composed of one or more Talend Runtimes
and the additional ESB infrastructure services:
• In red, one or more Talend Runtimes (execution container) deployed inside your information system. Talend
Runtime enables you to deploy and execute the Jobs, Routes, and Services created in the Talend Studio. For
more information on how to deploy items in Talend Runtime, see the Talend Open Studio for ESB User Guide,
and for more information about Talend Runtime itself, see the Talend ESB Container Administration Guide.
If you have several Talend Runtimes on which to deploy the Services and Routes, you will be able to load
balance their execution according to your needs. All instances of Talend Runtime will communicate between
each other via the Service Locator to identify the one more likely to deploy and execute them.
• In orange, a monitoring database gathering log information of the execution of your data processes and service
activity.
Data processes log information can be captured in the Talend Studio with the use of tFlowMeterCatcher,
tStatCatcher, tLogCatcher components. For more information, see the Talend Components Reference
Guide. And to automate the functionalities of the tFlowMeterCatcher, tStatCatcher, tLogCatcher
components without using them, you can use the Stats & Logs tab. For more information regarding Stats &
Logs, see the Talend Open Studio for ESB User Guide.
The Service Activity Monitoring allows the end-users to monitor service calls. It provides monitoring and
consolidated event information that they can use to understand the underlying requests and replies that
compose the event, monitor faults that may be unexpectly generated and support the system management
decisions. For more information on the Service Activity Monitoring, see its corresponding chapter in the
Talend ESB Infrastructure Services Configuration Guide.
• In addition to Service Locator and Service Activity Monitoring, Talend Runtime provides Security Token
Service functionalities which can be used to establish a trust relationship between a client and a Web service,
particularly if they are in different security domains. The Security Token Service is used to issue a security
token, that is, a collection of claims such as name, role, and authorization code, for the client to access the
service. The message receiver only must know the STS certificate for verifying the token signature to get a
trusted statement of the authentication information.
For more information on the installation of all these applications, see the Talend Installation and Upgrade Guide.
• The light blue block includes one or more Talend Studio APIs and Web browsers that could be on the same
or on different machines.
From the Studio API, end-users can carry out technical processes: data integration or data service processes,
mediation routes and services, and publish them on the Artifact Repository. The Talend Studio allows the user
to work on any project for which he has authorization. For more information, see the Talend Studio User Guide.
From the Web browser, end-users connect to the remotely based Talend Administration Center through a
secured HTTP protocol.
The end-user category in this description may include developers, project managers, administrators and any
other person involved in building Web, REST and data services, and mediation routes. Each of these end-users
will use either the Talend Studio or Talend Administration Center or both of them depending on the company
policy.
• The violet block includes a web-based Talend Administration Center (application server) connected to two
shared repositories: one based on an SVN server and one based on a database server.
The Talend Administration Center enables the management and administration of all projects. Administration
metadata (user accounts, access rights and project authorization for example) is stored in the database server
and project metadata (Jobs, Business Models, Routines, Routes, Services for example) is stored in the SVN
server (to easily share them between the different end-users).
Talend Administration Center also enables you to access and manage the Routes or Services created from the
Talend Studio and published into the artifact repository, and set up and monitor their deployment and execution
in the Talend Runtime.
Furthermore, Talend Administration Center enables you to access and use your ESB artifacts more securely,
and to manage the users who will only access resources to which they are authorized. In fact, with Talend
Administration Center, you can store and manage your service resources and their policy-based security in a
dedicated repository, the Service Registry. The Service Registry itself is part of the Talend ESB Container,
however, from Talend Administration Center, you can centralize, maintain and distribute services and policies.
This way, your company’s services and policies will stay accessible, consistent and reusable at all time. In
addition to service security, Talend Administration Center provides authorization capabilities that enables you
to give specific users, and roles, access rights to specific services. The users and their role should primarily
be defined in the Talend Identity Management Service Web application (based on Apache Syncope), also
accessible via Talend Administration Center.
Finally, from Talend Administration Center, you can monitor and search through events collected across
distributed containers. Those Events can be logs from the Talend Runtime container (Jobs, Routes, etc.), OSGi
events generated by Talend Runtime (information about bundles) and Service Activity Monitoring events. For
more information about the different events that can be monitored, indexed and searched and how to configure
their collection, see the Talend ESB Infrastructure Services Configuration Guide.
For more information, see the Talend Administration Center User Guide
• The dark blue block represents the artifact repository that stores all the:
• Routes and Services that are published from the Talend Studio and are ready to be deployed and executed
in Talend Runtime.
You can access those artifacts via the Artifact repository Web application accessible from the ESB Publisher
and the Software update pages of the Talend Administration Center.
• The red block represents one or more Talend Runtimes (execution container) deployed inside your information
system. The Talend Runtime deploys and executes the technical processes according to the set up defined in
the Talend Administration Center Web application. Those processes are Routes and Services retrieved from
the artifact repository.
If you have several Talend Runtimes on which to deploy the Service and Route artifacts, you will be able to load
balance their execution according to your needs. All instances of Talend Runtime will communicate between
each other via the Service Locator to identify the one more likely to deploy and execute the artifact(s) set to
deployment in Talend Administration Center. The Talend Runtime elected for the deployment will request for
the artifact(s) to deploy and execute from the Artifact Repository and the Artifact Repository will thus send
the artifact(s) requested along with all the dependencies needed for its/their execution to the Talend Runtime,
Talend Runtime that will deploy and execute them.
• The orange block represents the Monitoring with the Activity Monitoring Console and the Service Activity
Monitoring.
The Activity Monitoring Console allows end-users to monitor the execution of technical processes. It provides
detailed monitoring capabilities that can be used to consolidate collected log information, understand the
underlying data flows interaction, prevent faults that could be unexpectedly generated and support the system
management decisions.
The Service Activity Monitoring allows the end-users to monitor service calls. It provides monitoring and
consolidated event information that the end-user can use to understand the underlying requests and replies
that compose the event, monitor faults that may be unexpectly generated and support the system management
decisions.
For more information on the installation of all these applications, see the Talend Installation and Upgrade Guide.
The major steps to follow to get started with the software are described in the following sections:
For a complete list of installation requirements, compatible software and software versions:
• If you are using the Talend Studio, see the Talend Installation and Upgrade Guide.
• If you are using Talend ESB Standard Edition, see the corresponding Talend Installation Guide.
<TalendRuntimePath> is used for the directory where Talend Runtime is installed. This is typically the full path of either
Runtime_ESBSE or Talend-ESB-VA.B.C, depending on the version of the software that is being used. Please substitute
appropriately.
For instance, the Talend Runtime examples are in the <TalendRuntimePath>/examples/talend directory.
Depending on the version of the product you are using, see the sections:
• Talend ESB Standard Edition, an OSGi container based on Apache Karaf with additional Infrastructure Services.
• Talend Open Studio for ESB, that includes both a Studio and an ESB Runtime. The ESB Runtime is the exact
equivalent of the Talend ESB Standard Edition product.
For an overview of these products, see Introduction to Talend ESB solutions in this guide.
• For the use cases documented in Building and deploying Data Services and Routes using the Studio and Building
and deploying REST Services using the Studio, you will need to install and start both the Studio and ESB
Runtime of the Talend Open Studio for ESB, with Infrastructure Services enabled.
• Whereas for the use cases documented in Building and deploying Data Services and Routes using Java, Rent-
a-Car demo using Service Locator and Service Activity Monitoring, Rent-a-Car demo using the Security Token
Service to provide WS-Security based SAML Authentication, you will only need the Talend ESB Standard
Edition (or the ESB Runtime of Talend Open Studio for ESB), with Infrastructure Services enabled.
• The use case documented in Rent-a-Car demo using the Artifact Repository is more addressed to users of the
Enterprise and Platform products, as it requires a repository management software, included by default in those
products. However, the use of an external repository management software is also possible with the community
products.
• The use case documented in Rent-a-Car demo using XKMS is addressed to users of the Enterprise and Platform
products only, as it requires the encryption functionalities available in those products.
• Installation and starting of the Talend Open Studio for ESB and Infrastructure Services, please follow the
instructions of the Talend Open Studio for ESB Installation and Upgrade Guide.
• Installation and starting of the Talend ESB Standard Edition and Infrastructure Services, please follow the
instructions of the Talend ESB Standard Edition Installation Guide.
To install the Enterprise or Platform editions, it is recommended to use the Talend Installer. Alternatively, please
follow the instructions available in the Talend Installation and Upgrade Guide provided to you in the email.
For an overview of these products, see Introduction to Talend ESB solutions in this guide.
The second container matches a common real world situation of client and server running on different containers.
It is a copy of the Talend Runtime container that you can launch separately and deploy applications into. This
second container is needed in the SayHelloRoute part of the SayHello example - see SayHelloRoute example, and
in the Service Locator part of the Rent-a-Car example - see Rent-a-Car demo using Service Locator and Service
Activity Monitoring.
For users of Talend ESB Standard Edition or Talend Open Studio for ESB, respectively take directly the TESB_SE-
VA.B.C package you downloaded or the Runtime_ESBSE folder extracted from the installation of the Talend Open
Studio for ESB, and copy its container folder.
For Enterprise and Platform customers, take the Talend-ESB-VA.B.C package you downloaded, and copy its
container folder. You can also directly use the Talend Runtime package (Talend-Runtime-VA.B.C), which is
the exact equivalent of the container folder of the Talend ESB.
For the Enterprise and Platform customers who installed Talend ESB via the Talend Installer, you will have to
copy the esb/container folder.
3. Create a copy of directory container with all its content by executing the relevant command:
In order to avoid conflicts between the two container instances, the configuration of the alternate-container
needs to be adjusted.
3. Wait until the initialisation phase has finished. To make sure the Talend Runtime is started with all its bundles
created and active, run the following command:
list
4. Execute the following command at the alternate container prompt to call Talend Runtime configuration
adaptation script that will set another unique group of settings:
source scripts/configureC1.sh
The settings are now updated and saved locally. The next time you run the alternate container, the new settings
will be used, and both container and alternate-container can be running at the same time.
5. It is not required for the following demos, but if you would like to create a third or fourth container, copy the
original container directory to a third location (see above). Again, start running the third container and use
the following command at the container prompt to call another adaptation script:
source scripts/configureC2.sh
If you get the "Port already in use" exception when starting an alternate container, recheck that there is not already a container
running using the default parameters. If you still get the error, it may also be that the port is in use by an unrelated process,
so update the configuration files in the alternate-container/etc folder by hand accordingly.
First, make sure you installed properly the product by following the instructions described in the Talend
Installation and Upgrade Guide.
Depending to the software you need to use, follow the instructions described in:
It is recommended to read Prerequisites to using Talend ESB products before starting this section, and then
download the Talend Runtime as described in Downloading and installing the software.
• Service Locator
and also:
When the container starts up, you will see a short introduction (similar to the one below) followed by the
Talend Runtime container console command prompt:
After starting the Talend Runtime container, you need to wait a few seconds for initialization to complete before
entering the commands. Karaf, on which the Talend Runtime container is built, starts the non core bundles in the
background. So even if the console is already available, the commands may not.
This will list all the OSGi Bundles installed in the Talend Runtime container and let you know if they are
active yet, or not.
For further information, see the Talend Installation and Upgrade Guide.
You can find further information about the Talend Runtime container and how to get started with it in the Talend
ESB Container Administration Guide.
Now, the Service Locator, Service Activity Monitoring and Security Token Service services are running as
features in the Talend Runtime container.
For the Enterprise and Platform Talend ESB, this command works the same as for the Talend ESB Standard
Edition and the Talend Open Studio for ESB, but it installs and starts additional services (for example: Service
Registry, Authorization, and so on).
2. For demo purpose, Enterprise and Platform users need to change the default security management system,
the Talend Identity Management Service, to the Talend ESB Standard Edition and Talend Open Studio for
ESB default one, the JAAS authentication handler, which is easier to use, and does not require the installation
of additional software.
tesb:switch-sts-jaas
For more information on how to launch each of the above services individually or as standalone, see the Talend
Installation and Upgrade Guide.
And for more information on Talend ESB Infrastructure Services, see the Talend ESB Infrastructure Services
Configuration Guide.
From the Talend Administration Center, you will be able to create a new remote project, create a new user account
for yourself and give access right for yourself to this newly created project. The advantage of such remote projects
is that several users can work collaboratively on the same centralized project, which is the least for company-
scale projects.
You will also be able to manage the publishing and deployment of ESB artifacts like SOAP services, REST service
Jobs, and Routes developed via the Talend Studio into the Talend Runtime container directly from the Talend
Administration Center. To do so, you have to connect the Talend Administration Center to the Talend Runtime
container. For more information, see Connecting the Talend Runtime to the Talend Administration Center.
This will launch the servlet container (by default, Apache Tomcat) holding the Talend Administration Center.
3. Once started, log in to Talend Administration Center with the default account: [email protected]/admin.
If you manually installed the product, it means that you deployed the Talend Administration Center in your own
servlet container, so simply run that container to start the Talend Administration Center.
Most of the warnings displaying are due to the fact that you did not start all the modules of the product yet. For
example:
• Commandline/secondary will get green only if you decide to use and start a secondary commandline, which
will not be the case in the following demo use cases.
• ESB Service Locator and SAM should be green if you started the Talend ESB and its Infrastructure Services.
• ESB Identity and Access Management will get green only if you install and start the Talend Identity
Management Service, which will not be the case in the following demo use cases.
• ESB Service Registry should be green if you started the Talend ESB and its Infrastructure Services.
• Software Update will get green if you start the dedicated Archiva Artifact Repository, which will not be the
case in the following demo use cases. Although Archiva Artifact Repository is deprecated.
1. For the Commandline/primary section of the Talend Administration Center Configuration page,
simply start the commandline: cmdline/start_cmdline.bat (Windows) or cmdline/start_cmdline.sh
(Linux) if you used the Talend Installer.
If you manually installed the Commandline, go to the directory where you installed it and execute
commandline.bat (Windows), or commandline-linux.sh or commandline-linux_x86_64.sh (Linux),
depending on your version of Linux.
2. For the ESB Publisher and Conductor section of the Talend Administration Center Configuration page,
simply start the Talend Nexus Artifact Repository.
The Artifact Repository is provided with the Talend Administration Center. So, if you installed the product
via the Talend Installer, you will find it in the tac folder of your installation, in a Artifact-Repository-
Nexus-VA.B.C.D.E subfolder. If you installed the product manually, the Artifact Repository will be available
in the Talend Administration Center package as well (Talend-AdministrationCenter-rXXXXXX-VA.B.C).
3. Configure the Log4j parameters by filling in the path to technical and business log files.
The Technical logstash appender parameter will get green when you will start the Talend Log Server, by
executing start_logserver.bat (Windows) or start_logserver.sh (Linux).
4. Configure the Svn parameters by filling in the connection information to your svn.
To do so, you have to first install a subversion server if you are on Windows, as Linux embeds subversion,
and create two repositories in your subversion server: one for your Talend projects, and one for the external
libraries that will get downloaded when starting the Studio.
Then, fill in the connection information to those two repositories in the Svn configuration entry in the Talend
Administration Center.
3. Fill in the Data panel to the right with your Talend Administration Center and Svn credentials.
Make sure to assign both Designer and Operation manager roles to the account, to be able to respectively
use the Studio and manage the deployment of ESB artifacts from the Talend Administration Center.
4. Click Save. The new account you created displays on the list.
5. Click the Projects link in the left-hand menu, and in the Projects page, create a new project.
7. In the Project panel to the right, put the name of your project in the Label field.
8. Click Save. The new project you created displays on the list.
9. Click the Project authorizations link in the left-hand menu, and in the Project authorizations page, give
access right to the project to the user account you just created.
10. In the Project panel to the left, click the project to select it.
11.
In the User Authorizations panel to the right, click the Read write icon of the user: .
1. Click the Servers page in the menu to the left to display the list of servers.
If you installed the product via the Talend Installer, depending on your license, one server, the Jobserver,
might already be installed and display by default: serv1.
2. Create a new server by clicking Add > Add server. The Execution server form displays to the right.
• Host: 127.0.0.1
• TOS_ESB-win-*.exe (Windows) or TOS_ESB-linux-gtk-* (Linux) for Talend Open Studio for ESB.
2. For the Enterprise or Platform product, if you manually installed the Studio, you will be asked to load a
license file at this point. Browse to where your license file is located, and click OK to load it.
In the Talend Studio login screen, put the name of your project in the Create a New Project field and click
Create.
2. The [New project] wizard opens for the project details. Do not hesitate to add a description of your project.
Click Finish. The login screen displays again but with this new project. Click Open.
3. If you have already registered to the TalendForge (tutorials, support, and so on), connect to it here. If not,
please enter your details to create an account. You can also Skip this step for the moment.
4. The [Welcome] page in the Talend Studio is now displayed while the initialization of the studio finishes.
Click the [x] button of this [Welcome] page to close it and access the Talend Studio main screen.
1. Create a new connection based on the account you created in the Talend Administration Center:
Click the [...] button next to the Connection list. The [Connection] wizard displays.
3. In the Name field, put the name you want to give to that connection.
4. In the User E-mail and User Password, fill in the credential of the user account created in the Talend
Administration Center.
5. In the Web-app Url, put the URL address of the Talend Administration Center.
6. Click the Check url button to check that the connection to the Talend Administration Center is successful.
8. In the Talend Studio login screen, the fields are filled in with the connection information.
In the Project and SVN Branch lists, all the projects and their branches to which you have access and can
work on should be listed.
Here, as you only created one project and did not create any branch in it, you have nothing to select.
10. If you want to connect to the Talend online community and benefit from it, create or connect to it from this
wizard. You can also Skip this step.
11. To finish the starting up of the studio, you will be asked in a [Additional Talend Packages] wizard to
install required and optional third-party libraries. Please do so to be able to fully benefit from the studio's
functionalities. So, make sure the Required and Optional third-party libraries check boxes are selected
and click Finish.
12. In the [Download external modules] wizard that displays, click the Accept all button at the bottom of the
wizard to accept all the licenses of the external modules used in the studio.
13. A [Migration tasks done] wizard displays informing you of possible migration tasks, simply click OK to
close the wizard.
14. The [Welcome] page in the Talend Studio is now displayed while the initialization of the studio finishes.
Click the [x] button of this [Welcome] page to close it and access the Talend Studio main screen.
To be able to access it, you first need to start the Talend Administration Center (for more information, see Starting
the Talend Administration Center), and the Talend Log Server.
1. If you installed the product via the Talend Installer, go to the directory named logserv, and double-click the
following executable file: start_logserver.bat (Windows) or start_logserver.sh (Linux).
If you downloaded the Talend-LogServer-VA.B.C.D.zip package, unzip it and double-click the following
executable file: start_logserver.bat (Windows) or start_logserver.sh (Linux).
tesb:stop-el-server
persistence.event.db.active.default=false
search.active.default=true
elasticsearch.available=true
4. Go back to the Talend ESB Container console and execute the following command to start again the Event
Logging service now that it is correctly set up:
tesb:start-el-default
5. As you used the tesb:start-all command to start all the Infrastructure Services in the Talend Runtime
container when first starting it, the Service Activity Monitoring services were started as well. So you now
need to stop them to only start the Service Activity Monitoring retrieval service that is useful for the ESB
Dasboards. To do so, execute the following commands:
tesb:stop-sam
tesb:start-sam-retrieval-service
6. Now that all the needed services are started, start the Event Logging listeners for Service Activity Monitoring
and Service Locator events via the following commands:
tesb:start-el-samlistener
tesb:start-el-locatorlistener
For more information about the configuration, see the Talend ESB Infrastructure Services Configuration Guide
and the Talend Administration Center User Guide.
For more information on how to access the logs generated when executing the examples of this guide, see:
Accessing the events in the ESB Dashboards, Accessing the events in the ESB Dashboards, and Accessing all ESB
event logs in Talend Administration Center.
Apache Maven 3.0.3 is used to build the "export the service" part of the SayHello example (see Exporting the
service and running it in a Talend Runtime container) and all of the Rent-a-car demos. So, Apache Maven should
be downloaded from http://maven.apache.org/ and installed, and the mvn executable should be in your Path
environment variable.
When running mvn for the first time, HTTP access to the Internet is required, in order to download the required
artifacts (and subsequently to get the most recent versions). The local Maven repository is expected to be created
in its default location, that is, the standard Maven configuration should not be modified.
• With the Building and deploying Data Services and Routes using the Studio, you will learn how to create routes
and services in the Talend Studio and how to deploy them into the Talend Runtime.
• With the Building and deploying REST Services using the Studio, you will learn how to create a REST service
in the Talend Studio, how to deploy it into the Talend Runtime and how to call it via a REST consumer Job.
• With the Building and deploying Data Services and Routes using Java, you will learn how to compile Apache
CXF services and deploy them into the Talend Runtime.
• With the Importing the Rent-a-Car Java demo into Eclipse, you will learn how to import services as a project
into Eclipse.
For more use cases about creating services, routes and data service jobs with the Talend Studio and deploying them
into the Talend Runtime, testing the service with a soapUI project, and unit testing the route using the Apache
Camel Testing framework, see the Theory into practice appendix for ESB in the Talend Studio User Guide.
For more use cases on how to publish and execute a service, a route and a data service job, and how to monitor the
service endpoints and service activities in the Talend Administration Center, see the Theory into practice appendix
for ESB in the Talend Administration Center User Guide.
If you are only interested in Java-based ESB development, you can skip this section and continue to the Building and
deploying Data Services and Routes using Java
2. Build a simple SayHello data service, in which a consumer sends a number of names to a service, which then
prints "Hello!" to each of them in turn.
This section gives enough information to create and run the demo. For a comprehensive look at the Talend Studio User
Interface, please see the Talend Studio User Guide.
For more details on specific components mentioned in this demo, please see the Talend Components Reference Guide for
data services components and Talend ESB Mediation Components Reference Guide for mediation components.
3. Export the service to a Talend Runtime container, and run the consumer again.
Creating a service
In this section, you will create a WSDL which defines the external contract to the Web service that clients can
use. (See Web Services Support for more information).
1. To create the service, right-click Services in the left hand menu and select Create Service.
2. Enter the name SayHelloService, purpose Demo and a description of the service, and click Next.
3. In the next step called [Assign WSDL], select Create new WSDL and click Finish to return to the main
screen.
4. Now the main window has a [SayHelloService_0.1.wsdl] tab displayed. This WSDL contains
a new port (SayHelloServicePort) for the service, and default request and response operations
(SayHelloServiceOperationRequest and SayHelloServiceOperationResponse respectively). Hover over
the grey arrows to the right of the operations to display their parameters:
It is possible to make changes to the operations - add new operations and edit existing ones. However, the
default operations are enough for this demo example.
• Click on the border of a square to move the shape itself around the grid.
• Undo or edit these changes by right-clicking the square and selecting the appropriate actions.
• Click the center of a square for actions particular to the component (for example, examining details of the component).
1. Save the service details and WSDL Request / Response data types to the Metadata so that they can be
accessible to other components. So, in Services, right-click SayHelloService 0.1 and select Import WSDL
Schemas.
This option imports the WSDL metadata from the service into the Repository, under the Metadata > File
xml. This allows you to share the operations details across services and other components.
2. Implement the operation - expand the elements displayed in SayHelloService 0.1, right-click
SayHelloServiceOperation 0.1 and select Assign Job. In the wizard, select Create a new Job and Assign
it to this Service Operation, and click Next.
Keep the default name and prefix SayHelloServicePortType_SayHelloServiceOperation, and click Finish.
This creates a new job, which allows to implement the operations using components in the main grid.
4. Now add some business logic. tXMLMap is a component that transforms and routes data from single or
multiple sources to single or multiple destinations. Perform a search for the tXMLMap component in the
Palette on the right hand side. There may be two instances found under different sections, but they are both
the same, so select either. Drag and drop it between the two ESB components.
5. Right-click the center of tESBProviderRequest_1 and select Row, then Main and drop the end of the line
on tXMLMap_1.
6. Next, right-click tXMLMap_1 and select Row, then Main and drop the end of the line on
tESBProviderResponse_1. Give it the name Response, and click OK. Click the default Yes when asked if
you wish to import the schemas.
1. Now customize the service operation to match the scenario. Double-click tXMLMap_1 to open its editor.
tXMLMap is used to route the information from the request to the response, and make use of the existing
schema information from the WDSL.
2. Under main :row1 on the left hand side, right-click payload and select Import from Repository. In the
[Metadata] wizard that appears, navigate from File XML to SayHelloServiceOperationRequest0.1, select
it and click OK.
3. In the same way, on the right hand side, import the default response type, right-click payload then Import
from repository > File XML and select SayHelloServiceOperationResponse 0.1.
Click OK.
So, the request and response operations are implemented from the existing schemas.
4. Next, simply link the request schema to the response one: left-click in on the left hand side and drag it to the
out expression in the response on the right hand side.
5. Next, modify the default expression that is sent. On the right hand side, under Expression, click the
HelloServiceRequest value, and click the [...] button beside it. Edit the expression (which will evaluate to a
name) by clicking in the field, and add "Hello " + before it, and +"!" after it.
Click OK. You will see the updated expression now on the right hand side. Click OK to return to the main
Job design window.
6. Finally, in order to see more as the Job executes, add a logging component. This is done simply by searching
for tLog in the palette, and dragging tLogRow from the Palette on the right hand side and dropping it on the
Response link between the tXMLMap_1 and tESBProviderResponse_1.
Do a quick check now to make sure this part is working, by clicking the tab Run (Job SayHello...) in middle
section in the bottom half of the window, and then clicking the Run button.
The Job is compiled, and the log output shows that the Web service has been assigned a port 8090 and has been
published for other services to use.
In Talend Studio you can test each Service operation which you implement in a Job Design individually to check that its
implementation is ok. If you would like to test the entire service with multiple operations, you need to export the service
and deploy in the runtime. It is not possible to test a service with multiple operations in the Talend Studio.
1. To test the service, you can also create a small consumer Job. Right-click Job Designs and select Create
Job. In the Name field, type SayHelloConsumer, and the purpose is Demo. Click Finish.
2. Now in the [Job SayHelloConsumer 0.1] tab, search for tFixedFlowInput in the palette, and drag and drop it
onto the grid. Similarly, drag and drop tXMLMap, tESBConsumer, and tLogRow (twice) as shown below.
The tFixedFlowInput components generates as many lines and columns as you want using context variables,
and the tESBConsumer calls a specified method from the invoked Web service, and returns a class, based
on parameters.
3. Now configure the components. Double-click the center of tFixedFlowInput_1 and in Component tab
below, select Use Inline Table. Then click the [...] button next to Edit schema to open the Schema editing
window.
In this window, click [+] to add a string argument, and rename newColumn to Name and click OK to close
this window.
4. Returning to the tFixedFlowInput_1 Component tab, use the [+] button to add sample rows, and
successively replace the "newLine" text with names "Peter", "Alice" and "Bob".
This is the example data that the consumer will send to the SayHelloService.
5. Now, in the Job SayHelloConsumer 0.1 Job, link the components as before, by right-clicking and dragging
tFixedFlowInput_1 > row > main to tXMLMap_1. Then right-click tXMLMap_1 > row and name this
new Output Request (click the default yes to get the schema of the target component), and drop the end on
tESBConsumer_1.
6. Now double-click the tXMLMap to configure it as before. On the right hand side, click payload
> Import From Repository. In the [Metadata] wizard that appears navigate from File XML to
SayHelloServiceOperationRequest 0.1, and select it. This enables you to call the service operation. Click
OK.
7. Now left-click and drag Name on the left hand side to the in parameter on the right hand side and click OK
to return to the main window.
8. Finally, take care of the response outputs. Right-click the center of tESBConsumer_1, drag and select Row
> Response and drop the end on tLogRow_1 so that any responses should go there. Similarly, right-click
tESBConsumer_1, select Row > fault and drop the end on tLogRow_2 so that any faults should go there.
In summary, tFixedFlowInput generates "Peter", "Alice", "Bob", these will be passed by tXMLMap to
tESBConsumer, which will do three corresponding invocations on the target provider.
1. Now, point the consumer at the correct WSDL endpoint for the Service. So go to the Component tab of
the tESBConsumer component, and edit the endpoint there to reference the correct service. Click the [...]
button next to Service Configuration, and the WSDL configuration window opens. Paste in "http://
localhost:8090/services/SayHelloService" to replace the service address there, giving a full address
of "http://localhost:8090/services/SayHelloService?WSDL" and click the refresh button to the
right to load the information. Click Finish.
2. Finally, run the consumer Job. Click the Run (Job SayHelloConsumer) tab, and click Run. The Job builds
and executes, and the three names in a Hello message display in the output.
So, the creation and execution of a SayHello consumer and provider in Talend Studio is successful.
1. Before exporting the service, first start a Talend Runtime container, and make sure all its Infrastructure
Services have been started, as described in Starting Talend Runtime.
2. For Enterprise and Platform users who want to see the Service Activity Monitoring and Service Locator events
generated when executing this SayHello use case in the Talend Administration Center ESB Dashboards, make
sure to start them as described in Starting the ESB dashboards.
3. Additionally, for Enterprise and Platform users who want to use the ESB Dasboards, you need to configure
some settings before exporting the service. Under Services, right-click SayHelloService 0.1 and select ESB
Runtime Options. In the dialog box, select the Use Service Activity Monitoring and Use Service Locator
check boxes.
4. Now export the service. Under Services, right-click SayHelloService 0.1 and select Export Service. In the
[Save As] window, specify a folder. Click Finish.
This process builds and exports the service to the specified directory, as a SayHelloService-0.1.kar file.
5. Copy the SayHelloService-0.1.kar file, and paste it into the deploy folder of the Talend Runtime
container, The service starts directly.
Enterprise and Platform users can also deploy the service via the Talend Administration Center Web
application, for more information, see Publishing and deployment from the Talend Administration Center.
6. Since this is a dynamic loading environment, the service starts running automatically. To see it in the Talend
Runtime container window, type in the list command at the console prompt.
7. To check if the service has correctly been deployed, go to http://localhost:8040/services, and the
SayHelloService service will be listed.
The port that the service is running at has changed, and now uses the Talend Runtime container port, which
is by default 8040, so update the port. Under Job Designs, open the SayHelloConsumer 0.1 Job. Click the
middle of tESBConsumer_1. Then go to the Component tab.
9. Click the [...] button next to Service configuration, which opens a WSDL settings window.
10. Update the port number to use the Talend Runtime container port - so change 8090 to 8040, and click the
refresh button.
11. Now run the consumer job as before from the Run tab, and you see the same output as before.
12. If you look at the output in the Talend Runtime container, you also see the Hello messages generated by the
server running in the container.
So that is how to create a simple SayHello consumer and service, running them in the Talend Studio, and also
running the service in the Talend Runtime container.
In the Talend Administration Center Web application, click Monitoring > Logging in the menu tree view:
To access the event logs about the service endpoints, click the ESB Locator Endpoints dashboard:
To access the event logs about the service activity, click the ESB SAM dashboard:
For more displays of the ESB Dashboards, see Accessing all ESB event logs in Talend Administration Center.
Finally, you will run the consumer from the first example, and show the messages coming from the consumer,
and being routed to the correct service.
2. Create a new route by right-clicking Routes > Create Route. Give the name SayHelloRoute and purpose
is Demo, and click Finish.
3. Now you will notice that the palette has changed from the one in the Integration perspective to the Mediation
perspective. You will create a typical content-based route, dragging and dropping components from the palette
to the route grid.
The request message is coming in from the consumer, so drag and drop the Messaging > cCXF component,
which intercepts messages coming into server endpoints.
Then, as you want to create a content-based route, drag and drop the Routing > cMessageRouter component,
which reroutes messages depending on a set of conditions.
Then add two more instances of Messaging > cCXF for the two target services.
Having multiple cCXF components with the same label in a Route is not supported.
It is recommended to label each component with a unique name to better identify its role in the Route.
Having duplicate labels may cause problems for the code generation of some components.
4. To implement this, just add some parameters. So, click cCXF_1, and then click the Component tab below:
• As a Talend Open Studio for ESB first time user, you will be asked to install external libraries in the Studio
to be able to use some components as the cCXF, so please follow the instructions and install them.
• In the Wsdl File field, specify the URL of the WSDL from the original service. Use the http://
address to get the live background service information. It is in "http://localhost:8040/services/
SayHelloService?WSDL", for all three services.
• In the Dataformat list, select PAYLOAD, as you are looking at the message body.
At any point, you can save the current information by selecting File > Save or clicking the Save icon in the top left
hand corner.
5. Repeat the previous step for the other components: cCXF_2 - except that the port number in the Address
field is 8040, and for cCXF_3 where the port number in the Address field is 8041.
So, in summary, you create a request on port 8042 (cCXF_1), and send it to either port 8040 (cCXF_2) or
8041 (cCXF_3), depending on the contents of the message.
6. So now, connect the components together. Connect cCXF_1 to cMessageRouter_1 by right-clicking the
center of cCXF_1 and selecting Row > Route and dropping the end onto cMessageRouter_1.
7. Then create a When trigger for one service, by right-clicking cMessageRouter_1, selecting Trigger > When
and dropping the end on cCXF_2.
9. Configure the When condition: right-click the when1 line, which brings up a small dialog.
In the Type list, select simple, and the Condition is "${bodyAs(String)} contains 'Alice'".
This way, any message with "Alice" in the body will be routed to a service in a Talend Runtime container
that listens on port 8040.
2. Then copy of the kar file of the service you created (Talend ESB installation directory /container/deploy/
SayHelloService-0.1.kar), and paste it into the deploy folder of the alternate container.
3. To test that all has been configured correctly, before adding the consumer, go to the route created in the studio
and execute it. Click the Run button in Run (Job SayHelloRoute) tab:
This checks that the CXF configuration information is syntactically correct. It also gives an output of "0
rows" on the grid, which reflect the flow of messages, so that you know that the parts are connecting. Leave
the job running.
If you get syntax errors, then click on each component in turn, and examine it in the Component tab. Check in
particular that the double quotes are all there, and that the port numbers are correct.
4. Now, switch back to the consumer to run the demo for real. Click Integration perspective in the top right
hand corner. Then open the SayHelloConsumer 0.1. Update the port number, so click the Component tab
of the tESBConsumer, and the [...] button next to Service Configuration. Update the port number to be
8040, and click the refresh button to retrieve the WSDL information. Now update the endpoint to be that of
the route - http://localhost:8042/services/SayHelloService.
5. Now send a request by running the consumer job by clicking on the tab Run (Job SayhelloConsumer) and
click Run. The "Hello Peter", "Hello Alice", "Hello Bob" display in the consumer output as before. The main
grid shows "3 rows", that is, the three messages being passed along with none going to fault.
6. Now look at the Route SayHelloRoute 0.1 tab, 1 message went to the cCXF_2 provider and 2 messages
went to the cCXF_3 provider.
7. And if you look at the output in the two containers, you also see that the messages have been routed correctly.
This is the output for one container:
This screen shows the route being exported to a /container/deploy directory in a Talend Runtime so that it is
directly deployed, but it can also be stored elsewhere and copied to the deploy directory later.
If you are only interested in Java-based ESB development, you can skip this section and continue to the Building and
deploying Data Services and Routes using Java
1. Install the software as described in Downloading and installing the software and run it as described in Starting
the software.
At least, both the Talend Studio and the Talend Runtime should be started.
2. Build a simple REST service that will explore the data of a simple database table containing information
about employees.
However, for the sake of the demo, the following use case will be using a simple tFixedFlowInput component
instead of a database connection component, but feel free to adapt it to use a database instead if you feel
confortable enough.
4. Build a simple REST consumer that will send a request to the service.
This section gives enough information to create and run the demo. For a comprehensive look at the Talend Studio User
Interface, please see the Talend Studio User Guide.
For more details on specific components mentioned in this demo, please see the Talend Components Reference Guide.
1. A simple REST service provider querying the data of your employees. See Creating a service provider.
2. A second REST mapping to query only one specific employee via their id. See Adding a new mapping to the
service.
1. To create the service, right-click Job Designs in the left hand menu and select Create Job.
2. Enter the name (EmployeeService), the purpose (demo) and a description of the service, and click Finish to
return to the main screen.
Now, the main screen has a Job EmployeeService 0.1 tab displayed.
3. In this new Job Design, you will build the REST service, so search for tRESTRequest and tRESTResponse
components in the palette, and drag and drop them onto the grid.
Similarly, drag and drop tFlowToIterate, tFixedFlowInput, and tXMLMap components as shown below.
1. Double-click the tFixedFlowInput component to display its corresponding Component view at the bottom
of the window. Click the [...] button next to the Edit schema option.
In the [Schema of tFixedFlowInput] wizard that pops up, click three times the [+] button at the bottom of
the wizard to add three columns and configure them as above.
2. In the Mode area, select the Use Inline Content (delimited file) option and paste the following info in the
Content field:
1;Lyndon;Monroe
2;John;Johnson
3;Calvin;McKinley
4;Andrew;Truman
5;Richard;Taft
6;Andrew;Adams
7;Herbert;Buchanan
8;Bill;Carter
9;Ulysses;Jackson
10;Warren;McKinley
3. Double-click tRESTRequest to display its corresponding Component view and set its properties.
4. In the REST Endpoint field, you can type in the URI of the endpoint from which the service will be
available. The URI is generally made of a Host name or IP address and a port number, separated by a
colon. Here, put the relative path "/services". This way, the URI will always look as follows: http://
<IP_address>:<port_number>/services.
5. Click once the [+] button at the bottom of the REST API Mapping table to add a new mapping.
7. In the URI Pattern field, type in the XPath to the root of the XML tree: "/employees".
8. Click in the Output Flow field to display the [...] button and click it.
The [Give the name for the schema] wizard pops up.
A new wizard pops up in which you can define the columns of the schema you are about to create.
10. As you do not want to define any schema for this REST API Mapping for the time being, simply click OK.
The new getEmployees mapping displays in the REST API Mapping table.
1. Right-click tRESTRequest, select Row > getEmployees in the menu and click the tFlowToIterate
component.
2. Right-click tFlowToIterate, select Row > Iterate in the menu and click the tFixedFlowInput component.
4. Right-click tXMLMap, hold and drag to tRESTResponse and name the output link all when asked by the
[tXMLMap Output] pop-up.
2. In the editor, the input flow from the database table displays to the left, in the input area of the editor. And in the
output area to the right of the editor, configure the output XML flow that will be sent to the tRESTResponse
component.
3. In the all output table, right-click the root element and select Rename in the menu to rename it employees.
4. Right-click employees and select Create Sub-Element in the menu to create a sub-element called employee
that will hold each employee's information.
5. Right-click this new employee sub-element and select As loop element in the menu.
This way, a loop will be executed at each new employee encountered, to retrieve their individual information.
6. Click the Wrench button at the top of the table to display the output options and select true in the All in
one list.
When set to true, the All in one option enables to create one single XML document from all the input rows of
the tXMLMap component. This allows to send only one complete response when the Web Service is called.
7. Map the input with the output flow, select the id column from the row1 table and drop it onto the employee
sub-element of the all table, a [Selection] wizard pops up.
8. In the wizard, select Create as attribute of target node and click OK to validate.
A mapping has been created between the id column of the employees database table and the id attribute of
the employee XML tree.
9. Select the firstname and lastname columns of the row1 table and drop them onto the employee sub-element
of the all output table.
10. In the [Selection] wizard, select Create as sub-element of target node and click OK to validate.
11. Click Apply and OK to close the editor and validate the configuration.
1. Press F6 to run the Job. The Job is automatically saved before being executed. The Run view displays at the
bottom of the Studio and the console follows the execution.
The REST Service has been published to the following endpoint: http://127.0.0.1:8090/services, and
the provider continuously listens for request, so if you want to stop it, you will have to click the Kill button
of the Run view.
2. To check the service, simply go to the endpoint address on which it has been published:
http://127.0.0.1:8090/services/employees.
1. In the EmployeeService Job, double-click the tRESTRequest component to display its corresponding
Component view and change its properties.
2. Click once on the [+] button at the bottom of the REST API Mapping table to add a new mapping.
5. Click in the Output Flow field to display the [...] button and click it.
The [Give the name for the schema] dialog box pops up.
7. In the schema wizard, click the [+] button once to add a new line to the table.
The new getEmployee mapping displays in the REST API Mapping table.
8. In the URI Pattern field, type in the XPath to the root of the XML tree followed by the id variable to each
employee: "/employees/{id}".
9. Duplicate the tFixedFlowInput and tRESTResponse component, simply by coping and pasting them.
10. Click on the workspace, and start typing the name of the tXMLMap component, where you want to add it,
in the text field that appears automatically, and double-click its name to add it on the workspace.
1. Right-click tRESTRequest, select Row > getEmployee in the menu and click the second tXMLMap
component.
2. Right-click the second tFixedFlowInput component, hold and drag to the second tXMLMap.
3. Right-click the second tXMLMap component, hold and drag to the second tRESTResponse component and
name the output link single when asked by the [tXMLMap Output] pop-up.
2. Select the id column of the getEmployee input table and drag it to the id column of the row2 table.
A purple arrow is created between the columns of the tables to represent the join.
3. Define the XML schema that will be sent to the tRESTResponse component. To do so, right-click the root
element node in the single table and select Rename in the menu to rename it employee.
4. Map the input with the output flow. To do so, select the id column from the row2 table and drop it onto the
employee element of the single table, a [Selection] wizard pops up.
5. In the wizard, select Create as attribute of target node and click OK to validate.
6. Now, select the firstname and lastname columns of the row2 table and drop them onto the employee element
of the single output table.
7. In the [Selection] wizard, select Create as sub-element of target node and click OK to validate.
8. Click Apply and OK to close the editor and validate the configuration.
1. Press F6 to run the Job. The Job is automatically saved before being executed. The Run view displays at the
bottom of the Studio and the console follows the execution.
The REST Service has been published to the following endpoint: http://127.0.0.1:8090/services, and
the provider continuously listens for request, so if you want to stop it, you will have to click the Kill button
of the Run view.
2. To check the service, simply go to the endpoint address on which it has been published:
http://127.0.0.1:8090/services/employees.
You can see that it looks just like in the previous scenario.
3. Now, if you add the id of one of the employees at the end of the URL: http://127.0.0.1:8090/services/
employees/1
1. Make sure your Talend Runtime is up and running. To do so, follow the installation and starting instructions
described in Getting started with Talend ESB.
2. For Enterprise and Platform users who want to see the Service Activity Monitoring and Service Locator events
generated when executing the Employee use case in the Talend Administration Center ESB Dashboards,
make sure to start them as described in Starting the ESB dashboards.
3. Additionally, for Enterprise and Platform users who want to use the ESB Dasboards, you need to configure
some settings before deploying the service. In the EmployeeService Job, double-click the tRESTRequest
component to display its corresponding Component view and change its properties.
Select the Use Service Locator and Use Service Activity Monitor check boxes.
4. Several deployment processes are possible depending on the product you are using and the goal of your
deployment:
• With the Talend Open Studio for ESB, you will be able to deploy your Services and Routes locally in your
Runtime. For more infomation, see Local deployment (Talend Open Studio for ESB).
This local deployment can also be done via the Enterprise and Platform Studio, however if you do so, you
will not be able to easily share your Service and Route artifacts (as it can be done when publishing them
in the Artifact Repository) or schedule their deployment and running (as it can be done with the Talend
Administration Center).
• With the Enterprise and Platform products, all the development of Services and Routes is done in the
Studio by developers, and all the publishing into a centralized Artifact Repository and deployment into
the Talend Runtime container is done from the Talend Administration Center by operation managers. For
more information, see Publishing and deployment from the Talend Administration Center.
• With the Enterprise and Platform products, you can also publish your Services and Routes to the Artifact
Repository directly from the Studio. This should only be done for snapshots, for quick test purposes only.
A dedicated repository already exists in the Artifact Repository for this: the Snapshots repository. For
more information, see Publishing from the Enterprise and Platform Studio (for test purpose only).
2. In the [Build Job] wizard, make sure the Build type is set to OSGI Bundle For ESB.
5. Copy the EmployeeService.jar file and paste it into the deploy directory of the Talend Runtime container.
Since the Talend Runtime container is a dynamic loading environment, the service starts running
automatically.
7. To check the service, simply go to the endpoint address on which it has been published:
http://127.0.0.1:8040/services/services/employees.
So, in addition to the Talend Runtime, make sure the Talend Administration Center, and the other modules like
the CommandLine, and Talend Nexus Artifact Repository are running, as described in Getting started with Talend
ESB.
1. From the Talend Administration Center, click ESB Publisher in the menu to the left to display the
corresponding page that will help you find the Services and Routes you developed and published from the
Studio.
2. Click the Add button on the top and fill in the [Publish Task] form that displays to right:
3. Click Save. The new artifact displays in the list, as Ready to publish.
4. Select it and click the Publish button. The service will be published in the Artifact Repository right away.
You can also trigger the publishing of your artifact via the Trigger tab at the bottom of the ESB Publisher
page.
To do so, select the task you just created and click Add trigger... > Add CRON trigger in the Trigger tab at
the botton of the page, and fill in the Add Cron trigger form that displays to the right. If you are not familiar
with the CRON syntax, you can use a wizard that will help you fill in all the related fields. So to open the
[Cron UI Trigger configuration] wizard, click the Open UI configurer button.
However for the demo, simply use the Publish button to publish your REST service Job.
Once published, the Service displays in the Artifact Repository, under the org/example node. You can click
the Open Artifact repository button at the top of the ESB Publisher page. This will open the Nexus Web
application. And in Repositories > Snapshots, you can find your Service artifact:
Once your Service published in the Artifact Repository, you will be able to deploy it into the Talend Runtime
container.
1. From the Talend Administration Center, click ESB Conductor in the menu to the left to display the
corresponding page that will help you find the Services and Routes you published in the Artifact Repository.
2. Click the Add button on the top and fill in the Edition form that displays to the right:
3. In the Label field of the Metadata area, name your service deployment task.
4. In the Feature area, click the Select Feature button to open the [Select Feature from Nexus repository]
wizard that will help you fill in the following fields of this area.
5. In the Repository list, select snapshots, browse to the Employee Service feature and select it. Click OK and
all the Service feature information will be filled in in the form.
6. In the Runtime Config area, select the container on which to deploy the Service in the Server list.
7. Click Save and the Service deployment task will display in the list.
8. Click the Deploy button and the Service will be deployed into the Talend Runtime container specified in
the Server list.
The Last Action column value changes from CREATED to DEPLOYED, and if you type in list in the
Talend Runtime container prompt, a new bundle is listed, the Employee Service one:
In addition to the Talend Runtime, make sure the Talend Administration Center, and the other modules like the
CommandLine, and Talend Nexus Artifact Repository are running, as described in Getting started with Talend
ESB.
1. Make sure the Artifact Repository connection preferences are correctly set in the Studio; go to the Menu
Window > Preferences > Talend > Artifact Repository.
2. From the Talend Studio Repository view, under Job Designs, right-click EmployeeService 0.1 and select
Publish.
3. In the [Publish Job into Artifact Repository] wizard, make sure to publish your Job in the Snapshots
repository (select the Publish as SNAPSHOT check box).
4. Click Finish.
The Service is now available as an artifact in the Snapshots repository of the Talend Nexus Artifact
Repository. You can click the Open Artifact repository button at the top of the ESB Publisher page. This
will open the Nexus Web application, and in Repositories > Snapshots, you can find your Service artifact:
Now, you can acces it from your Talend Administration Center application and deploy it into your Talend Runtime
container, as described in Deploying via the Talend Administration Center.
2. Enter the name (EmployeeServiceConsumer), purpose (demo) and a description of the Service, and click
Finish to return to the main screen.
3. Now, the main screen has a Job EmployeeServiceConsumer 0.1 tab displayed.
4. In this new Job Design, you will build the REST Service consumer, so search for a tRESTClient component
in the palette, and drag and drop it onto the grid.
5. Similarly, drag and drop tFixedFlowInput, tXMLMap, and tLogRow components as shown below.
1. First, connect the tFixedFlowInput component to tRESTClient so that it automatically gets the schema of
the target component.
2. Then, double-click the tFixedFlowInput component to display its corresponding Component view at the
bottom of the window.
3. Click the [...] button next to the Edit schema option. The [Schema of tFixedFlowInput] wizard pops up.
4. Click once the [+] button at the bottom of the wizard to add a new line named id with Type as Integer and
the Length of 2, as below.
5. In the Mode area, select the Use Inline Table option and click three time the [+] button to add three lines,
and configure them as below:
6. Double-click tRESTClient to display its corresponding Component view and set its properties.
2. Right-click tXMLMap, hold and drag to tLogRow and name the output link all when asked by the
[tXMLMap Output] pop-up.
In the editor, the input flow from the database table displays to the left, in the input area of the editor. And
in the output area to the right of the editor, configure the output XML flow that will be sent to the tLogRow
component.
2. In the row2 input XML tree, right-click the root element and select Rename in the menu to rename it
employee, and define the XML tree of the employee root element, that will hold each employee's information.
3. Right-click employee and select Create Attribute in the menu to create an attribute called id in the [Create
New Attribute] wizard that pops up.
4. Right-click employee again and select Create Sub-Element in the menu to create a new sub-element called
firstname in the [Create New Element] wizard that pops up.
5. Map the input with the output flow, select the statusCode column, id attribute, and firstname and lastname
elements from the row2 XML tree and drop them onto the all output table.
6. Click Apply and OK to close the editor and validate the configuration.
7. Double-click tLogRow to display its corresponding Component view and set its properties.
8. Click the Sync columns button to get the schema from the tXMLMap component.
• Press F6 to run the Job. The Job is automatically saved before being executed. The Run view displays at the
bottom of the Studio and the console follows the execution.
In the Talend Administration Center Web application, click Monitoring > Logging in the menu tree view:
To access the event logs about the service endpoints, click the ESB Locator Endpoints dashboard:
To access the event logs about the service activity, click the ESB SAM dashboard:
For more displays of the ESB Dashboards, see Accessing all ESB event logs in Talend Administration Center.
In the course of working through this example you will learn how to:
• Deploy the services using commands at the Talend Runtime container console.
The Rent-a-Car demo code can be built with different options (Maven profiles) in order to use additional functionalities,
and these are discussed in the next chapter - this section uses the default, basic build.
The Rental Client provides the basic functionality to search for the cars available within a given time period. To
implement its business logic, the Rental Client calls operations from both the CRM Service and the Reservation
Service as shown in the diagram below.
1. The search takes into account the status (silver, gold, platinum) of the customer you select. This customer
profile information is passed to the reservation service and is used to determine the outcome of the search.
2. From the list of results, you can select the car that best fulfills the customer requirements and then make a
reservation simply by clicking on the Book button.
3. At the end of the submission process, the booking confirmation is displayed along with a Reservation ID.
1. The crmservice:
2. The reservationservice has the same structure, except that the parts relate to the ReservationService
3. The app-reservation has code to build the commands and simple UI client:
Directory or file name Description
src/ This directory contains the source code.
target/ This directory is the target directory for the build.
pom.xml This file is used by the Maven build process.
1. Create an alternate container - see Creating an alternate container for the Demos.
5. Deploy the demo client application - see Deploying the demo client application.
1. From a command line console, change the directory to the root directory of the Rent-a-Car example:
cd <TalendRuntimePath>/examples/talend/tesb/rent-a-car/
2. Run the following Maven command: (Maven is invoked identically from a Linux terminal or the Windows
command line.)
mvn clean install
Now, the demo is built, and OSGi bundles are created for deployment into the Talend Runtime container.
The demo services feature must be installed in the primary container, and not in the alternate one, because it relies
on the primary's port 8040 to be opened for incoming HTTP calls.
1. Add the Rent-a-Car feature location into the primary container of the Talend Runtime
(<TalendRuntimePath>/container/).
This command allows you to use the relevant bundles directly from the Maven repository where they have
been installed by the Maven build.
2. Install the Rent-a-Car services feature into the Talend Runtime container.
features:install tesb-rac-services
list
You will see the demo bundles in the list of installed bundles. As you can see below, both CRMService and
ReservationService bundles are installed:
1. If the alternate container is used for deployment of the demo application, add the Rent-a-Car feature location
into this container. The feature location needs to be added only once in each container, even if the container is
shut down afterwards and re-started, as state is preserved between runs. However, if you are unsure whether
you installed a feature already, adding the feature location again will not cause any problems.
features:addurl mvn:org.talend.esb.examples.rent-a-car/features/5.6.2/xml
If you have already run a previous example, you may need to run the following command in order to ensure
that internal bundle caches are updated:
features:refreshurl
features:install tesb-rac-app
list
You will see the demo bundles in the list of installed bundles:
1. A customer enters prerequisite data into a form such as their name, the pick-up and return dates, the preferred
range of rental rates, and submits their query.
2. The application calls the CRMService to retrieve the customer data and customer status information.
3. The customer is presented a list of available cars and selects one car from the list.
4. The application calls the ReservationService to submit the reservation request and then displays a reservation
confirmation notice to the customer.
In fact, there are two versions of the Rental Client application: the GUI one and the command line one. Thus, on
the console of the container with the demo application you will see:
The following sections will deal with the user interface, and running the commands of the Rental Client application.
2.
Select aebert from the User list and click Find to see the results. You will see the list of available cars.
3.
Click the highlighted line or select any other option and click Reserve.
1. To look for a car for a specific user (aebert), in the console, type:
car:search aebert 2014/07/17 2014/07/20
Car details
1 VW Golf Standard 50.00 75.00 40.00
2 BMW 320i Sport 60.00 90.00 45.00
3 Mazda MX5 Sport 65.00 95.00 50.00
4 Lexus LX400 SUV 85.00 120.00 100.00
Reservation ID SGA-295484
Customer details
----------------
Name: Andrea Ebert
eMail: [email protected]
City: Munich
Status: PLATINUM
Car details
-----------
Brand: BMW
Model: 320i
Reservation details
-------------------
Pick up date: 2011/07/17
Return date: 2011/07/20
Daily rate: 60.00
Weekend rate: 90.00
Credits: 210
Thank you for renting a car with Talend ESB :-)
• If you want to uninstall only the demo services, execute this command at the container console:
features:uninstall tesb-rac-services
Then, you can install them again as described in Deploying the demo services.
• If you want to uninstall only the demo application, execute this command at the container console:
features:uninstall tesb-rac-app
• If you want to uninstall all the demo features, execute the following commands at the containers' console:
features:uninstall tesb-rac-services
features:uninstall tesb-rac-app
features:uninstall tesb-rac-common
Then enter features:list | grep tesb-rac to ensure that all features have actually been uninstalled. You
should see this in the console:
You can also remove the Rent-a-Car feature location from the container(s).
3. Then run:
mvn eclipse:eclipse
1. From the main menu bar, select File > Import.... The [Import] wizard opens.
2. Select General > Existing Projects into Workspace and click Next.
3. Choose Select root directory and click the associated Browse to locate the examples/talend/tesb/rent-
a-car directory.
4. Back in the [Import Projects] window, under Projects, select the project or projects that you would like to
import, and then click Finish.
The Talend ESB example projects you selected will be imported into your Eclipse workspace. At this stage, you
can now see the source code, modify it, and take advantage of all other Eclipse features.
For more information on developing with Talend ESB and Eclipse, please see Talend ESB Development Guide.
The examples showed in this chapter are based on the Rent-a-Car Java demo introduced in the Basic deployment
and runtime use cases.
• the Service Activity Monitoring (SAM) to monitor service calls, typically for collecting usage statistics and
fault monitoring.
If you have one of the Enterprise or Platform editions of Talend, there is a GUI functionality provided by the Talend
Administration Center, for viewing the Service Locator and Service Activity Monitoring information. For a preview of
the Service Activity Monitoring User Interface in the Talend Administration Center, see Viewing the events in the Service
Activity Monitoring interface of the Talend Administration Center.
Please see the Talend Installation and Upgrade Guide and the Talend Administration Center User Guide for more details.
In this section, you will see how to deploy the Rent-a-Car demo in the Talend Runtime container. This involves
a number of steps, similar to those described in the basic Rent-a-Car demo.
1. Create an alternate container - see Creating an alternate container for the Demos.
3. Build the demo - see Building the demo with Service Activity Monitoring and Service Locator enabled.
4. Check that the features from the previous demo runs have been uninstalled - see Uninstalling previous
features.
5. Deploy the Talend ESB services - see Installing and starting the Service Locator and Service Activity
Monitoring .
It is important for the Rent-a-Car demo that these are installed in the default container (using port 8040), as
the demo files are configured for that.
6. Deploy the demo services and client application in one container - see Running the demo in one container
to generate Service Activity Monitoring data. This step focuses more on the Service Activity Monitoring
functionality, as the Service Locator is largely unused in this scenario.
7. Then re-run the demo using two containers, while stopping one of the example services. This will show the
role of the Service Locator in service failover (see Running the demo in two containers - simulating server
failover with Service Locator), and show how the client re-connect to another service, using this functionality.
If you started the Talend Runtime container and all the Infrastructure Services as described in Starting Talend
Runtime, those features should have already been deployed and started through the tesb:start-all command.
If you want to start them individually or customize their configuration parameters, see Service Locator and Service
Activity Monitoring.
tesb:start-locator
locator.strategy=defaultSelectionStrategy
locator.reloadAdressesCount=10
connection.timeout=5000
session.timeout=5000
For further information about the Service Locator properties configuration, please read the Talend ESB
Infrastructure Services Configuration Guide.
tesb:start-sam
Then, the Service Activity Monitoring Server will be started. you can check with this URL in a browser: http://
localhost:8040/services/MonitoringServiceSOAP?wsdl, which should list its <wsdl:definitions>.
The tesb:start-sam command will start the Derby database on localhost with default 1527 port, and install
the tesb-datasource-derby feature and tesb-sam-server feature. If you are using another Database (for example
MySQL, H2, Oracle), please follow the instructions of DataSource and Service Activity Monitoring Server
installation/configuration in the Talend ESB Infrastructure Services Configuration Guide.
When a Service Activity Monitoring Server is installed in the Talend Runtime, by default, the database recreation
is activated - see the org.talend.esb.sam.server.cfg configuration file. This shows errors in the console log
for each subsequent restart of the container ("can’t create table …"). To avoid this startup logging error, please
change the db.recreate property in org.talend.esb.sam.server.cfg to false (db.recreate=false) after
you installed the Service Activity Monitoring Server.
In a Talend Runtime container, if you want to configure some properties for Service Activity Monitoring access
(for example service.url), please edit:
<TalendRuntimePath>/container/etc/org.talend.esb.sam.agent.cfg
2. If you have already used the container to run previous examples, you should ensure that all the features from
those previous examples have been uninstalled, including the feature tesb-rac-common which is implicitly
loaded as a dependency. Otherwise, the installation of the features for the locator example will fail. If in doubt
about whether previous features are still installed, enter the following commands in both containers:
features:uninstall tesb-rac-services
features:uninstall tesb-rac-common
If you installed Rent-a-Car Rental Client applicaton in this container, you should uninstall it too:
features:uninstall tesb-rac-app
These commands uninstall the remaining bundles from the basic example.
3. You can also remove the uninstalled features of the previous example from the container:
features:removeurl mvn:org.talend.esb.examples.rent-a-car/features/5.6.2/xml
This command removes the features of the basic scenario from the container.
Running this command will build the demo with the required functionalities and create OSGi bundles to be
deployed to the container.
These changes occur when you build the examples with the Service Activity Monitoring Agent and the
Service Locator enabled:
• The jaxws:features of the Service Activity Monitoring Agent and also the Service Locator will be added
into the Spring beans.xml file of the related client and service-endpoint, for example:
• The MANIFEST.MF file of the related client and service-endpoint will be updated by adding the following
bundles in the Require-Bundle list: sam-common,sam-agent,locator.
features:addurl mvn:org.talend.esb.examples.rent-a-car/features-sl-sam/5.6.2/xml
2. If previous examples have already been installed, run the following command:
features:refreshurl
features:install tesb-rac-services-sl-sam
features:install tesb-rac-app-sl-sam
4. Then, you can use the list command to check if everything installed properly.
For example:
features:addurl mvn:org.talend.esb.examples.rent-a-car/features-sl-sam/5.6.2/xml
features:refreshurl
4. Then enter:
features:install tesb-rac-services-sl-sam
5. Then, you can use the list command to check if everything installed properly. For example:
1. Before really running the demo, stop the alternate-container if it is running, you will start it again for the
next run of the demo.
2. Run the client application as in the basic Rent-a-Car demo (see Running the demo for full details):
car:gui
3. In the Rental Client application user interface that displays, simply click Find.
This step is sufficent for the demo. You will then see output like this in the default container console:
###############################################
getCRMInformation() invoked ... request data:
org.talend.services.crm.types.LoginUserType@fc0795
###############################################
###############################################
getCRMInformation() invoked ... response data:
org.talend.services.crm.types.CustomerDetailsType@560854
###############################################
###############################################
getAvailableCars() invoked ... request data:
org.talend.services.reservation.types.RESProfileType@a14297
###############################################
###############################################
getAvailableCars() invoked ... response data:
org.talend.services.reservation.types.RESCarListType@11ad529
###############################################
It shows the requests and responses for the CRMService and ReservationService.
To connect to the Service Activity Monitoring database, use the following settings:
DB password: test
The database connection must correspond to the settings defined in the <TalendRuntimePath>/etc/
org.talend.esb.sam.server.cfg file, and the referenced data source configuration, which is Derby (ds-derby)
by default, can be found in the <TalendRuntimePath>/etc/org.talend.esb.datasource.derby.cfg file.
Then, the data of the EVENTS and EVENTS_CUSTOMINFO tables can be browsed/monitored in DbVisualizer.
For example, the data of the EVENTS table after running the Rent-a-Car demo with the Service Activity Monitoring
functionality enabled looks like the following:
For more information about the schema definition of the tables, please look at the EVENTS Structure and the
EVENTS_CUSTOMINFO Structure sections in the Talend ESB Infrastructure Services Configuration Guide.
4. The app-reservation automatically looks up the CRMService endpoint again in the Service Locator.
2. Do not close the GUI application, just click Back to get back to the previous booking step.
2. In the default container, get the details of the CRMService bundle by typing the command list and note the
number of the CRMService Service Endpoint bundle:
3. Stop it with the command stop 222 (using the bundle number you have found).
4. Then, click the Find button in the application GUI to activate the call to the CRMService.
Now, the ReservationService is working in the first container, and the CRMService in the second container.
###############################################
getAvailableCars() invoked ... request data:
org.talend.services.reservation.types.RESProfileType@1d510be
###############################################
###############################################
getAvailableCars() invoked ... response data:
org.talend.services.reservation.types.RESCarListType@13e49a8
###############################################
Afterwards, the Locator will switch to the CRMService in the second container; and in the alternate container
console, you will see the following:
###############################################
getCRMInformation() invoked ... request data:
org.talend.services.crm.types.LoginUserType@1142653
###############################################
###############################################
getCRMInformation() invoked ... response data:
org.talend.services.crm.types.CustomerDetailsType@1e03fce
###############################################
In the Talend Administration Center Web application, click Monitoring > Logging in the menu tree view:
To access the event logs about the service endpoints, click the ESB Locator Endpoints dashboard:
To access the event logs about the service activity, click the ESB SAM dashboard:
For more displays of the ESB Dashboards, see Accessing all ESB event logs in Talend Administration Center.
features:uninstall tesb-rac-services-sl-sam
features:uninstall tesb-rac-common-sl-sam
features:uninstall tesb-rac-app-sl-sam
features:uninstall tesb-rac-services-sl-sam
features:uninstall tesb-rac-common-sl-sam
3. Enter features:list | grep tesb-rac to ensure that all features have actually been uninstalled.
In order to enable WS-security for the Rent-a-Car example, the Security Token Service server has to be installed
and deployed.
1. If needed, create an alternate container as described in Creating an alternate container for the Demos.
2. If needed, configure the logging to override the default logging configuration as described in Configuring
logging.
3. Start the primary container (and the alternate container, if necessary) with Infrastructure Services - see
Starting Talend Runtime.
4. Build the demo - see Building the demo with Security enabled.
For the Rent-a-Car Security Token Service sample, automatic logging is enabled by default in the client and service
configuration files.
To disable automatic logging in the sample, remove the following XML node from the beans.xml files in both
services and clients of the Rent-a-Car Security Token Service sample:
<cxf:bus>
<cxf:features>
<cxf:logging />
</cxf:features>
</cxf:bus>
Log messages from clients and Security Token Service are stored in the alternate container:
./alternate-container/log/tesb.log
Log messages from services are stored in the same directory in the primary container.
1. To make sure the Security Token Service service is started, start the default Talend Runtime container, if you
stopped it, and execute the following command in the console:
list
The following bundles should display on the list: Apache CXF STS Core and Talend :: ESB :: STS ::
CONFIG which enable the STS functionality.
If you did not start the Security Token Service service yet, run it now via the tesb:start-all command,
or if you want to only install the Security Token Service feature without all of the others (Security Token
Service, Service Locator), run the tesb:start-sts command.
2. Enterprise and Platform users should make sure the security management system has been changed from the
TIDM to JAAS (tesb:switch-sts-jaas). For more information, see Starting Talend Runtime.
3. Now to build the demo examples, from a command line console, run the following command from the
directory <TalendRuntimePath>/examples/talend/tesb/rent-a-car/:
4. Now, install the examples themselves. So, to add the Rent-a-Car feature location in the default container
console, type in:
features:addurl mvn:org.talend.esb.examples.rent-a-car/features-sts/5.6.2/xml
5. When the STS example has finished being installed, and the cursor returns, type in:
features:refreshurl
features:install tesb-rac-services-sts
features:addurl mvn:org.talend.esb.examples.rent-a-car/features-sts/5.6.2/xml
7. When the examples have been installed, and the cursor returns, type:
features:refreshurl
features:install tesb-rac-app-sts
8. Run the Rent-a-Car Rental Client application, for example, by running car:gui in the alternate container.
For more information, see Building and deploying Data Services and Routes using Java.
features:uninstall tesb-rac-app-sts
features:uninstall tesb-rac-common-sts
features:uninstall tesb-rac-services-sts
features:uninstall tesb-rac-common-sts
In a Talend ESB context, the Nexus Artifact Repository is used as a provisioning repositories management
software. The Provisioning is used as a catalog in which all ESB artifacts (Routes, Services and Generic OSGi
features) to be deployed and executed are stored. These ESB artifacts are designed by the developers in the Studio
or any other Java IDE. By default, two repositories are embedded within this repository: one for development
(Snapshots) and one for production (Releases). These repositories make artifacts available for deployment in the
Talend Runtime.
In this section, you will see how to manually publish the Rent-a-Car demo in an Artifact Repository, and how
to deploy its services from that Artifact Repository to the Talend Runtime container. Here are the major steps
of the use case:
• Download and install an Artifact Repository - see Downloading and installing Nexus Artifact Repository).
• Publish the Rent-a-Car demo features in the Artifact Repository - see Publishing the demo to the Artifact
Repository).
• Deploy the Rent-a-Car demo features from the Artifact Repository to the Talend Runtime, manually for
community products like Talend ESB Standard Edition or Talend Open Studio for ESB - see Deploying the
demo to Talend ESB Standard Edition with Nexus Artifact Repository
• Deploy the Rent-a-Car demo features from the Artifact Repository to the Talend Runtime via the Talend
Administration Center for Talend Enterprise or Platform products - see Deploying the demo from Artifact
Repository to Talend Runtime with Talend Administration Center.
If you are using Talend ESB Standard Edition or Talend Open Studio for ESB, download the Nexus Open
Source or Nexus Pro distributions available on the Nexus Website: http://www.sonatype.org/nexus and follow the
installation instructions in Nexus's Website.
If you are using the Talend Enterprise or Platform products, you have already installed the Talend Artifact
Repository when installing the Talend Administration Center, as described in Starting the Talend Administration
Center.
1. Make sure Sonatype Nexus or Talend Nexus Artifact Repository (for Enterprise or Platform users) is installed
and running - as described in Downloading and installing Nexus Artifact Repository.
In case you installed it via the Talend Installer (for Enterprise or Platform users), you will find it as the Talend
Artifact Service in your environment.
<server>
<id>nexus</id>
<username>admin</username>
<password>admin123</password>
</server>
<!-- use the following if you're not using a snapshot version. -->
<repository>
<id>nexus</id>
<name>RepositoryProxy</name>
<url>http://localhost:8081/nexus/content/repositories/releases</url>
</repository>
<!-- use the following if you ARE using a snapshot version. -->
<snapshotRepository>
<id>nexus</id>
<name>RepositoryProxy</name>
<url>http://localhost:8081/nexus/content/repositories/snapshots</url>
</snapshotRepository>
</distributionManagement>
Now that the Rent-a-Car demo features have been published to the Artifact Repository, you can deploy them in
your Talend Runtime container. For more information on how to do this:
• For Talend ESB Standard Edition and Talend Open Studio for ESB users, see Deploying the demo to Talend
ESB Standard Edition with Nexus Artifact Repository.
• For Talend Enterprise or Platform users, see Deploying the demo from Artifact Repository to Talend Runtime
with Talend Administration Center.
1. Make sure that the Rent-a-Car demo features have been published to the Artifact Repository - as described
in Publishing the demo to the Artifact Repository.
3. Install the Rent-a-Car features in the Talend Runtime container with these commands:
features:addurl mvn:org.talend.esb.examples.rent-a-car/features/5.6.2/xml
features:refreshurl
features:install tesb-rac-services
features:install tesb-rac-app
car:gui
1. Make sure the Talend Runtime, Talend Administration Center, and Nexus Artifact Repository are running
- as described in Starting the software.
2. Make sure that the Rent-a-Car demo features have been published to the Artifact Repository - as described
in Publishing the demo to the Artifact Repository.
3. From the Talend Administration Center, under Conductor, click ESB Conductor to create a new deployment
task.
4. Click the Add button on the top and fill in the Edition form that displays to the right:
5. In the Label field of the Metadata area, name the service rent-a-car, and in Description, put demo, for
example.
6. In the Feature area, click Select Feature to open the [Select Feature from Nexus repository] wizard that
will help you fill in the following fields of this area:
7. In the Repository list, select releases, and browse through org > talend > esb > examples > rent-a-car >
features > 5.6.2, select the features-5.6.2.xml feature, and click OK. The fields of the Features area will
be filled in automatically.
In the Name list, select the tesb-rac-services option, and in the Type list, select Service.
8. In the Server list of the Runtime Config area, select the Talend Runtime Container.
Click Deploy and the tesb-rac-services feature will be deployed into the Talend Runtime Container and
will be started automatically.
The Rent-a-Car services are now deployed and automatically started in the Talend Runtime container and can
now be used. If you type list at the console prompt of the container, you will see that the services are active:
[ 349] [Active ] [ ] [ ] [ 80] CRMService Common (5.6.2)
[ 350] [Active ] [ ] [ ] [ 80] ReservationService Common
(5.6.2)
[ 351] [Active ] [ ] [ ] [ 80] CRMService Service (5.6.2)
[ 352] [Active ] [ ] [Started] [ 80] CRMService Service Endpoint
JMX (5.6.2)
[ 353] [Active ] [ ] [ ] [ 80] ReservationService Service
(5.6.2)
[ 354] [Active ] [ ] [Started] [ 80] ReservationService Service
Endpoint JMX (5.6.2)
To use those services via the Rent-a-Car Rental Client application, you should deploy its corresponding service
into the Talend Runtime container as well. To do so, follow the same procedure described above, but select the
tesb-rac-app feature in the Name list of the Features area.
Once the Rental Client application service deployed in the Talend Runtime container, run its interface via the
car:gui command and use the Rent-a-Car services with it.
For another use case of deployment via the Talend Administration Center, see Publishing and deployment from
the Talend Administration Center. In this use case, both publishing to the Artifact Repository and deployment to
Talend Runtime container are handled with the Talend Administration Center, as the development of the service
was made in the Talend Studio.
For more details on the ESB Conductor, see the Talend Administration Center User Guide.
The XKMS feature is only available with Talend's Enterprise and Platform products. So, if you are a user of Talend
ESB Standard Edition and Talend Open Studio for ESB, you will not be able to execute this demo.
1. Start the container with Infrastructure Services - see Starting Talend Runtime.
2. Configure the XKMS service - see Configuring the XKMS service for the demo.
3. Build and run the demo - see Building the Rent-a-Car demo example.
1. To make sure the XKMS service is started, start the default Talend Runtime container, if you stopped it, and
execute the following command in the console:
list
The following bundles which enable the XKMS functionality should display on the list:
[ 233] [Active ] [ ] [ ] [ 80] Apache CXF XKMS Common
(2.7.11)
[ 234] [Active ] [Created ] [ ] [ 80] Apache CXF XKMS Client
(2.7.11)
[ 343] [Active ] [ ] [ ] [ 80] Apache CXF XKMS Service
(2.7.11)
[ 344] [Active ] [ ] [ ] [ 80] Apache CXF XKMS X509 Handlers
(2.7.11)
[ 345] [Active ] [Created ] [ ] [ 80] Apache CXF XKMS OSGi
deployment (2.7.11)
If you did not start the XKMS service yet, run it now via the tesb:start-all command, or if you want
to only install the XKMS feature without all of the others (Security Token Service, Security Token Service,
Service Locator), run the tesb:start-xkms command.
2. The XKMS service supports both LDAP and File as backend repository. In a testing or demo environment,
configure the XKMS service to use File repository (more simple to use).
The public certificates (*.cer) used in this example have been preinstalled into the default ${karaf.home}/
esbrepo/xkms/certificates/trusted_cas XKMS repository of the Talend Runtime container.
1. Now to build the demo examples, from a command line console, change the directory to:
<TalendRuntimePath>/examples/talend/xkms/rent-a-car
2. Now, install the examples themselves. In the Talend Runtime container console, execute the following
commands:
features:addurl mvn:org.talend.esb.ee.examples.rent-a-car/features/5.6.2/xml
features:install tesb-rac-services-xkms
features:install tesb-rac-app-xkms
3. Then, you can use the list command to check if everything installed properly:
[ 373] [Active ] [ ] [ ] [ 80] CRMService Common (5.6.2)
[ 374] [Active ] [ ] [ ] [ 80] ReservationService Common
(5.6.2)
4. To use the demo, you can use the Rental Client interface. To open it, execute the following command at the
Talend Runtime container console prompt:
car:gui
This section describes how to use the Talend Administration Center ESB Dashboards.
In the Talend Administration Center Web application, click Monitoring > Logging in the menu tree view:
The dashboard above is the default one, it displays graphically the events and classify them according to the
log threshold that you have defined in the TAC Configuration page. For more information, see the Talend
Administration Center User Guide.
To access the event logs about the service endpoints, click the ESB Locator Endpoints dashboard:
The above dashboard displays all the endpoints of the services deployed in the Talend ESB
Container and their availability. For example here, four endpoints are listed: one for the Employee
REST service use case ({http://www.talend.org/rest/}EmployeeService), one for the SayHello
service use case ({http://www.talend.org/service/}SayHelloService), and two for the Rent-
a-Car use case ({http://services.talend.org/CRMService}CRMServiceProvider and {http://
services.talend.org/ReservationService}ReservationServiceProvider). The four of them are
available and active.
To access the event logs about the service activity, click the ESB SAM dashboard:
The above dashboard displays all the service activity. The four services used in the use cases are used.
As you can see, the services created in the use cases of this guide have been requested, and to most
of these requests corresponds a response. In addition, the most requested services are listed. Here, the
two Rent-a-Car services ({http://services.talend.org/CRMService}CRMServiceProvider and {http://
services.talend.org/ReservationService}ReservationServiceProvider) are the top requested ones.