Re: Camel HTTP: I/O exception (java.net.SocketException) caught when processing request: Too many open files

2017-04-28 Thread urwithsumit
Thanks Tomo for sharing your thoughts. I got the problem solved by switching from Camel-Http to Camel-Http4 component. With Http4 i was able to set the headers for closing the connections and also a timeout period. In case of Http, the connections were not closing and that was accounting towards

Camel HTTP: I/O exception (java.net.SocketException) caught when processing request: Too many open files

2017-04-25 Thread urwithsumit
Hi, I have a rest API exposed using camel Jetty. The api makes call to another API to fetch some data. Intermittently, we are getting exception "I/O exception (java.net.SocketException) caught when processing request: Too many open files". The number of connections is well below the default Unix uL

Re: Camel SSH - dynamic values

2017-04-12 Thread urwithsumit
@Claus, toD() did worked for user id and password. @Zoran, the approach gives a null pointer exception for user id, RSA token combination. I did not tried though with the password. For dynamic value i thus will go with toD() Still struggling to get it work with RSA token code. -- View this

Re: Camel SSH - dynamic values

2017-04-12 Thread urwithsumit
Thanks Claus for this pointer. I will try this approach today. Any advice on how i can make a SSH login with username and a RSA Token ex: 87632345? Regards, Sumit -- View this message in context: http://camel.465427.n5.nabble.com/Camel-SSH-dynamic-values-tp5797435p5797512.html Sent from the

Re: Camel SSH - dynamic values

2017-04-11 Thread urwithsumit
Well, I was immediately able to figure out the alternate approach for it. Map map = exchange.getIn().getBody(HashMap.class); exchange.getIn().setHeader("USERNAME", map.get(HeaderConstant.USER_NAME)); exchange.getIn().setHeader("PASSWORD", map.get(HeaderCons

Camel SSH - dynamic values

2017-04-11 Thread urwithsumit
I am trying to use Camel ssh component as a producer. I am passing username and password as a dynamic parameter. With camel Version 2.18.2, my uri looks like below: .to("ssh://localhost?username=${header.USERNAME}&password=${header.PASSWORD}&pollCommand=features:hostname%0A") With this uri, I ke

Camel Jetty & Cors not working

2017-04-03 Thread urwithsumit
Hi, I am using Camel 2.18.2 and exposing REST api using camel Jetty component. The enableCORS options is set to true. Still the call to the API from angular 2 application is getting exception for CORS. Definition for the REST URI: from("jetty:{{server.api.endpoint}}/file_monitor/report/all_file_

Camel JPA Name Query with Parameters

2017-03-10 Thread urwithsumit
Hi, I have been going through different post to see how i can use JPA component to invole named query with parameter. I know from documentation that we need to add it to the registry. Right now i am stuck and not able tot find a way to get the parameter to the registry. Below is the route i have.

Re: Camel EhCache 2.18.1 - Exception during initialization

2017-01-09 Thread urwithsumit
Luca, I reverted back to the camel-cache component as i was not getting ahead with ehcache. As per your request, I have logged it as a minor bug: https://issues.apache.org/jira/browse/CAMEL-10681 Regards Sumit -- View this message in context: http://camel.465427.n5.nabble.com/Camel-EhCach

Re: Camel EhCache 2.18.1 - Exception during initialization

2017-01-05 Thread urwithsumit
So now i tired another way, in the Camel test cases for ehcache used jndi registry to bind the configuration. I am starting the camel context through Main class, and below is the change i have to do: > I am loading Spring context with Main.main(args). > I am binding the cacheConfiguration to the p

Re: Camel EhCache 2.18.1 - Exception during initialization

2017-01-05 Thread urwithsumit
@lburgazzoli - I have tried your way earlier. It gives the same errror. Caused by: java.lang.IllegalArgumentException: CacheConfiguration must be specified at org.apache.camel.util.ObjectHelper.notNull(ObjectHelper.java:310) at org.apache.camel.component.ehcache.EhcacheConfigurat

Re: Camel EhCache 2.18.1 - Exception during initialization

2017-01-05 Thread urwithsumit
As per the EhcacheTestsupport.java, I made the change to read the xml configuration. final URI url = this.getClass().getResource("/ehcache/ehcache-config.xml").toURI(); //final Configuration xmlConfig = new XmlConfiguration(url); from("ehcache://appCache?configUri=" + url) .log("*

Camel EhCache 2.18.1 - Exception during initialization

2017-01-05 Thread urwithsumit
Hi, I am using Camel 2.18.1, and as per the documentation camel-cache is getting depricated from 2.18.x version. I want to stay with the latest and wan tto use the new camel-ehcache component. I did the configuration looking at the documentation and taking some sample from the camel ehcache comp

Camel-json Dataformat query

2016-12-19 Thread urwithsumit
Hi, I need help to understand the unmarshalTypeName property with Camel Json dataformat. Sometimes when I pass on the package name where my pojo files (custom & auto generated) are present to this property than I get a success during marshalling/unmarshalling. But than I also face the issue when

File Processing - Aggregating data across multiple rows

2016-04-01 Thread urwithsumit
Hi, During file processing i am getting multiple records for a Customer ID for multiple items purchased by him. Each row has a Bill Amount which is actual value of items purchased by him. It also has an Customer_item_cost which is the cost of the particular Item which customer paid. It also has a

Customize the Http Response Code for REST Service

2016-03-24 Thread urwithsumit
Hi, I am developing a REST service using apache Camel REST DSL. In the service if the request validation fail or any excepted failure happens than I send back a response message with the Custom Error Code. In this scenario the HTTP Response Code that gets returned is 200Ok. I want to Change the

Re: Camle-Swagger-Java- documenting optional param for REST Service

2016-02-03 Thread urwithsumit
Thanks Matt. It fixed the issue. -- View this message in context: http://camel.465427.n5.nabble.com/Camle-Swagger-Java-documenting-optional-param-for-REST-Service-tp5777172p5777194.html Sent from the Camel - Users mailing list archive at Nabble.com.

Camle-Swagger-Java- documenting optional param for REST Service

2016-02-02 Thread urwithsumit
Hi, Currently while documenting the REST Service we are giving param name as below: This marks the param as mandatory and when we are testing it with swagger-ui we are forced to give value for this param. I want to document this param as an optional param. How can this be achieved? Note: We

Re: Camel-Swagger-Java - Unable to generate the API Swagger definition

2016-01-22 Thread urwithsumit
I got the problem resolved: I was giving the below type & outType in the REST definition. On removing it i can get the swagger definition as was shown in your video demo!!! type="java.util.HashMap" outType="java.util.LinkedHashMap" Thanks for your time and patience. -- View this message in co

Re: Camel-Swagger-Java - Unable to generate the API Swagger definition

2016-01-22 Thread urwithsumit
@Matt: I already have the restConfiguration defined in the context. -- View this message in context: http://camel.465427.n5.nabble.com/Camel-Swagger-Java-Unable-to-generate-the-API-Swagger-definition-tp5776570p5776577.html Sent from the Camel - Use

Re: Camel-Swagger-Java - Unable to generate the API Swagger definition

2016-01-22 Thread urwithsumit
Still no luck after removing the camel: inside the -- View this message in context: http://camel.465427.n5.nabble.com/Camel-Swagger-Java-Unable-to-generate-the-API-Swagger-definition-tp5776570p5776576.html Sent from the Camel - Users mailing list archive at Nabble.com.

Camel-Swagger-Java - Unable to generate the API Swagger definition

2016-01-22 Thread urwithsumit
Hi, I am developing 2 REST api using camel REST DSL with Servlet. I am using SPring DSL and have followed the example camel-example-swagger-java which comes as part of 2.16 release. I am not able to get the Swagger definition for the REST API that are defined in Spring xml. I am only able to see