Do not input private or sensitive data. View Qlik Privacy & Cookie Policy.
Skip to main content

Announcements
Qlik Open Lakehouse is Now Generally Available! Discover the key highlights and partner resources here.
cancel
Showing results for 
Search instead for 
Did you mean: 
Anonymous
Not applicable

Deploying Talend REST Services using Karaf

Hi,
I have developped REST services jobs using Talend (ESB 5.4.1), and launched it has an Autonomous job and it worked well.
But I want to deploy it using the Talend Container service (which si based on Karaf).
I added the jar generated by Talend (Build > OSGI Bundle For ESB) to the deploy directory, and can see it as "Active" and "Created" in the bundle list in Karaf.
But I didn't find how to launch it...
Using the "start " command didn't give any feedback (nothing in the shell or in the tesb.log file)
Is there someone that could give me a little help to begin with it ? (never used that kind of services before) I could not find any tutorial applying to this case, if someone knows one that apply to this usage.
Thanks and sorry for asking such basic questions !

Labels (3)
12 Replies
Anonymous
Not applicable
Author

Hi
Welcome and thanks for the query,
You should see the INFO and higher level log statements in the log sub-directory. You can control the log level in etc/org.ops4j.pax.logging.cfg.
HTH, Sergey
Anonymous
Not applicable
Author

Hi,
"Active" and "Created" are good enough and then you should open your browser and check if your REST service is available in the list of http://localhost:8040/services
Regards.
Anonymous
Not applicable
Author

Hi, and thanks for the replies.
I can see my REST service at http://localhost:8040/services
Available RESTful services:
Endpoint address: http://localhost:8040/services/context.restUrl
WADL : http://localhost:8040/services/context.restUrl?_wadl
When I click on the WADL link it displays a XML file.
But if I can't reach my REST service (that should be on localhost:9002). How should I be supposed to access the REST service ?
For information, context.restUrl is the only variable of context that can be modified when the job is run with command lines (it allows the user to define the address of the REST service)
I'm sorry I don't get how this works
0683p000009MAR5.jpg 0683p000009MAHV.jpg
Anonymous
Not applicable
Author

Hi, if you need to run the services on a different port then you can update an "org.osgi.service.http.port" porperty in etc/org.ops4j.pax.web.cfg
Cheers, Sergey
Anonymous
Not applicable
Author

Thanks for the tip !
But here my problem is that I'm not able to reach my REST endpoint (use my REST service), I just can see that it seems to work. But I don't know how to reach my REST endpoint and use it...
Anonymous
Not applicable
Author

How do you invoke on your service ? Is it even not available on 8040 ?
Anonymous
Not applicable
Author

I'm on Ubuntu 13.04, I use the container from Talend ESB 5.4.1
To run the service I go in the following directory: $TALEND_HOME/Runtime_ESBSE/container/bin
And launch start (./start) to start the service, then client (./client) to connect to the shell.
I've put the OSGI (the jar file of my REST service) in the deploy directory.
All I get from localhost:8040 is in the uploaded screenshot. And if I click the link http://localhost:8040/services/context.restUrl?_wadl
It opens a XML file (that is shown on the 2nd screenshot)
0683p000009MAFb.jpg 0683p000009MANw.jpg
Anonymous
Not applicable
Author

Right, but how do you expect to interact with your service ? You mentioned you made it working in the studio. So how did you get this service consumed in the studio, for example, did you get some data from the service and how did you do it ?
Cheers, Sergey
Anonymous
Not applicable
Author

My service is used to consume data from the web. The user enters a specific URL (containing the request) and the service returns data.