Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
I am trying to get the data form rest API and my job looks below and giving error.
Error:-
Starting job Test_Animals at 16:55 17/12/2018.
Endpoint deployed at: https://th-apex-http-callout.herokuapp.com/animals
[statistics] connecting to socket on port 3481
[statistics] connected
org.apache.cxf.service.factory.ServiceConstructionException
at org.apache.cxf.jaxrs.JAXRSServerFactoryBean.create(JAXRSServerFactoryBean.java:225)
at local_project.test_animals_0_1.Test_Animals$Thread4RestServiceProviderEndpoint.run(Test_Animals.java:847)
Caused by: java.lang.RuntimeException: Protocol mismatch for port -1: engine's protocol is http, the url protocol is https
at org.apache.cxf.transport.http_jetty.JettyHTTPDestination.finalizeConfig(JettyHTTPDestination.java:168)
at org.apache.cxf.transport.http.HTTPTransportFactory.getDestination(HTTPTransportFactory.java:288)
at org.apache.cxf.endpoint.ServerImpl.initDestination(ServerImpl.java:84)
at org.apache.cxf.endpoint.ServerImpl.<init>(ServerImpl.java:63)
at org.apache.cxf.jaxrs.JAXRSServerFactoryBean.create(JAXRSServerFactoryBean.java:173)
... 1 more
Caused by: java.io.IOException: Protocol mismatch for port -1: engine's protocol is http, the url protocol is https
at org.apache.cxf.transport.http_jetty.JettyHTTPServerEngineFactory.createJettyHTTPServerEngine(JettyHTTPServerEngineFactory.java:277)
at org.apache.cxf.transport.http_jetty.JettyHTTPServerEngineFactory.createJettyHTTPServerEngine(JettyHTTPServerEngineFactory.java:307)
at org.apache.cxf.transport.http_jetty.JettyHTTPDestination.retrieveEngine(JettyHTTPDestination.java:134)
at org.apache.cxf.transport.http_jetty.JettyHTTPDestination.finalizeConfig(JettyHTTPDestination.java:166)
... 5 more
I am using TOS for ESB 7.1
You should be using the tRestClient. The tRestRequest is for building your own Rest service. This would be used with a tRestResponse. Take a look here: https://help.talend.com/reader/hCrOzogIwKfuR3mPf~LydA/~V42EBQClKxKQghNvzHF1g