Re: Problem with Dynamic Recipient list and XPath

2009-01-16 Thread ychawla
>> hard. So I am working on improving this. >>> >>> At the same time the wiki needs a little update as well. Thanks. >>> >>> >>> On Mon, Jan 12, 2009 at 11:37 PM, ychawla >>> wrote: >>>> >>>> Hel

CXF Guidance

2009-03-26 Thread ychawla
Hello Fellow Camel Riders, I have an application that is using camel for routing and it working quite nicely. There are two allowed input paths for a message, one is a web service and the other is direct file system access. When a user drops a file onto the file system, it is processed by the

Re: CXF Guidance

2009-03-26 Thread ychawla
rg/CAMEL/loan-broker-example.html > > > Willem > > ychawla wrote: >> Hello Fellow Camel Riders, >> I have an application that is using camel for routing and it working >> quite >> nicely. There are two allowed input paths for a message, one is a web >> service

Camel CXF Component with ActiveMQ

2009-04-03 Thread ychawla
Hello All, I have a question. I have a Camel route configured to work with the CXF component using Camel 1.6.0. I am trying to invoke a service, send the message to a queue and send a response. However, the message seem to hang in the JMS queue. Here is the route: http://wijiscommons.

Re: Camel CXF Component with ActiveMQ

2009-04-04 Thread ychawla
will do a little experimenting. However, for now the pipeline going from the JMS queue and then to the response should work out. Thanks for the help! -Yogesh Claus Ibsen-2 wrote: > > On Sat, Apr 4, 2009 at 5:27 AM, ychawla > wrote: >> >> Hello All, >> I have a ques

Camel Content Filter

2009-04-22 Thread ychawla
Hello All, I have a question about the usage of the content filter. I have a route where I want to validate the message, but I only want to validate a certain part of the message. I looked at the content filter pattern and it didn't seem like Camel had much built in functionality there: http://

Camel JUEL expression weirdness in 1.6.0

2009-04-22 Thread ychawla
Hello All, I am trying to evaluate a header in Camel 1.6.0 using EL expressions. Here is my expression: ${in.headers['MyHeader'].startsWith('fooBar')} false When I run this, I get an exception: javax.el.MethodNotFoundException: Cannot resolve method 'startsWith' in '

Re: Camel JUEL expression weirdness in 1.6.0

2009-04-22 Thread ychawla
Uh, nevermind. Looks like Camel 1.6.0 uses JUEL 2.1.0. I was using JUEL 2.1.1. This might be an issue if Camel upgrades to the next minor version release of JUEL. Cheers, Yogesh ychawla wrote: > > Hello All, > I am trying to evaluate a header in Camel 1.6.0 using EL expressions.

Re: Camel JUEL expression weirdness in 1.6.0

2009-04-23 Thread ychawla
. I will send him an email to report the issue and see if they have a bug report I can file. Thanks, yogesh Claus Ibsen-2 wrote: > > On Wed, Apr 22, 2009 at 11:58 PM, ychawla > wrote: >> >> Uh, nevermind. Looks like Camel 1.6.0 uses JUEL 2.1.0. I was using JUEL >&g

Re: Camel JUEL expression weirdness in 1.6.0

2009-04-23 Thread ychawla
Here is the link to the bug tracker on source forge for JUEL: https://sourceforge.net/tracker/?func=detail&aid=2779833&group_id=165179&atid=834616 Cheers, Yc ychawla wrote: > > Hello All, > I am trying to evaluate a header in Camel 1.6.0 using EL expressions. &g

Re: Camel JUEL expression weirdness in 1.6.0

2009-04-24 Thread ychawla
but use property.toString() as a candidate method name: the MethodInvocation's toString() will answer the method name. ychawla wrote: > > Here is the link to the bug tracker on source forge for JUEL: > > https://sourceforge.net/tracker/?func=detail&aid=2779833&group_id=1

No operation found in the CXF client

2009-06-11 Thread ychawla
Hello All, I am trying to consume a web service as the origin of a camel route and later on down the line invoke a web service. I have this working by just consuming an xml message from a folder and invoking a web service, but when I try to connect the two web services I get an error: org.apache

Re: No operation found in the CXF client

2009-06-12 Thread ychawla
is is okay with Camel folks out there. Cheers, Yogesh ychawla wrote: > > Hello All, > I am trying to consume a web service as the origin of a camel route and > later on down the line invoke a web service. I have this working by just > consuming an xml message from a folder and in

Re: HTTPS authentication setup using camel-http

2009-12-14 Thread ychawla
Is it possible to do this same 'hookup' using the Spring DSL. I am not sure if it is possible to specify this in Spring: HttpComponent httpComponent = (HttpComponent) getContext().getComponent("http"); httpComponent.setHttpClientConfigurer(new MyHttpClientConfigurer()); bwhite wrote: > > Tha

Re: HTTPS authentication setup using camel-http

2009-12-14 Thread ychawla
example: https://myhostname.com:443/myURL?httpClientConfigurerRef=myHttpClientConfigurer"/> As long as you implement the HttpClientConfigurer and configure your keystore and truststore as described above, it will work fine. ychawla wrote: > > Is it possible to do this same 

Recipient List / Multiple Exceptions

2009-12-15 Thread ychawla
Hello All, I am trying to use Camel to write a simple monitoring application. I want to check to try to connect to multiple URLs and then if any of them fail, send an email altering an admin. My strategy was to use timer to run the application at a given interval and then create a dynamic Recipi

Re: Saxon for XSLT 2.0?

2010-01-29 Thread ychawla
Hello, I need to use saxon as well as the XSLT transformer. I just threw the saxon jars in the classpath and the camel XSLT component used saxon. I am using Camel 2.1.0. Cheers, Yogesh raulvk.soa wrote: > > Hi, > > Is there a possibility to use Saxon instead of Xalan when using the xslt: >

Re: Using HTTPS in camel-http when remote side has self-signed cert

2010-02-18 Thread ychawla
Hello, I would like to monitor an HTTPS endpoint and connect to it in two different ways. I would like to connect to it in one route using HTTPS w/ client certificates and in another route using HTTPS using server certificate only. The reason for doing this is because all the endpoints I am moni

Re: Using HTTPS in camel-http when remote side has self-signed cert

2010-02-22 Thread ychawla
One way to solve this issue is to run two seperate instances of Camel and have the two different connection methods isolated in their own JVMs or webapps. Any other ideas? ychawla wrote: > > Hello, > I would like to monitor an HTTPS endpoint and connect to it in two > differ

Environment Variables using Simple language

2010-02-24 Thread ychawla
Hello All, I was unable to get the simple language to read from my environment variables in Windows. I did find a workaround for this that might be helpful. I use the Spring property place holder configurer which I believe has more functionality in Camel 2.3. Here is my workaround. I wanted to

Adding Mail Attachments Using Spring

2010-02-24 Thread ychawla
Hello All, I see on the mail page that it is possible to add mail attachments by attaching to the exchange prior to sending: http://camel.apache.org/mail.html in.addAttachment("logo.jpeg", new DataHandler(new FileDataSource("src/test/data/logo.jpeg"))); Is is possible to do this in Spring? If

Re: camel-http: basic authentication and query parameter "username"

2010-02-24 Thread ychawla
Hi Matteo, Did you check out this link: http://camel.apache.org/http.html It has info on connecting using basic auth. This example show a poll from google that you can adapt to meet your needs. Below is polls your URL and then write the result to a file: from("timer://foo?fixedRate=true&delay

Re: Not able to invoke webservice using http component

2010-03-23 Thread ychawla
Hi Habeer, Do you need to do the DOM conversions that you are doing: Document input = xmlConverter.toDOMDocument(soapMessage); exchange.getIn().setBody(input); Can't you just set the body to be a string? Same with the return message. That might be tripping something up. Also, are you able to

Wildcard Namespaces in XPath Injection

2010-03-26 Thread ychawla
Hello, I have been doing XPath injection and it is pretty cool. Using the instructions here, I created my own copy of the XPath annotation: http://camel.apache.org/xpath.html My question, how can I use wildcard namespaces? If you do something like this it fails due to the asterick: @Path("//*

Update Camel Content Filter Page?

2010-04-02 Thread ychawla
Hi Gang, Currently the WIKI has a content filter example like this: For the work we are doing, we want to select an xpath and set that as the body. We are doing something like this: //foo:bar I think this example would be helpful to include. End users don't have to bother

Re: routing mail with camel on fuse esb

2012-08-03 Thread ychawla
Hi Mathieu, Not sure why you are getting an unknownhostexception. Can you telnet to the URL: telnet smtp.gmail.com 587 Also, I think port 587 on gmail is running on TLS. Maybe you need to use smtps? Thanks, Yogesh -- View this message in context: http://camel.465427.n5.nabble.com/routing-m

Re: way to convert multiple csv files to single xml file

2012-08-09 Thread ychawla
Hi Matheen, Can you explain your problem a little more? Are all the files going to be available at the same time? Do you know how many files you need to aggregate? For example, in pseudo code: do all your bindy processing here but send to aggregator rather than 'fi

Re: way to convert multiple csv files to single xml file

2012-08-09 Thread ychawla
Here is an example method to aggregate: @SuppressWarnings("unchecked") public void aggregateGroupMessages(Exchange groupedExchange) { List grouped = groupedExchange.getProperty(Exchange.GROUPED_EXCHANGE, List.class); for (Exchange ex

JSON - Jackson return list rather than POJO

2012-08-14 Thread ychawla
Hello All, I am unmarshalling data using Jackson. My dataFormats bean is set up as such: However, my return value isn't a simple POJO, it is a list of POJO's. For example this is a sample stripped down JSON response: [{"last_name":"xxx",,"first_name":"Heather

Re: Using Simple header notation to define where to send a message

2012-08-14 Thread ychawla
Hello, You can also try using a recipient list and only have a single recipient on it. It can function as a dynamic router when you dynamically set a header. Thanks, Yogesh -- View this message in context: http://camel.465427.n5.nabble.com/Using-Simple-header-notation-to-define-where-to-send-

Re: exposing different operations under same service in camel + cxf routing.

2012-08-14 Thread ychawla
Hi, Have you tried turning on the tracer to see what headers are on your exchange? A simple filter such as this should work: ${in.headers.operationName} == 'SearchRequest' Try looki

Re: JSON - Jackson return list rather than POJO

2012-08-14 Thread ychawla
A simple workaround for this is a custom bean processor like so: public void processPersonSearchResponseJSON(Exchange exchange) throws JsonParseException, JsonMappingException, IOException { ObjectMapper mapper = new ObjectMapper();

Re: problem in aggregation

2012-08-14 Thread ychawla
Hi, Can you add some debug statements to your aggregator: newIn.setBody(oldBody + newBody); For example, what is oldBody and what is newBody? Based on the error you are receiving, you might be concatenating two XML documents like this: This will not create a valid XML document bec

Re: JsonEndpoint and Router

2012-08-23 Thread ychawla
Hi Marco, I have had a similar situation. I grab the JSON input, unmarshall to a POJO, inspect the payload for a parameter, and then set a camel header for routing. I have also had cases where I could route directly based of information in the HTTP Headers. Handling this by setting a header ba

RE: Debugging Live Camel Routes

2012-08-28 Thread ychawla
Hi Guys, The ServiceMix wiki also has a page on this. It says basically what Graham said : http://servicemix.apache.org/remote-debugging-servicemix-in-eclipse.html Thanks, Yogesh -- View this message in context: http://camel.465427.n5.nabble.com/Debugging-Live-Camel-Routes-tp5718181p5718216.

Re: XMLSecurity key recovery fails when keystore and key use different passwords

2012-08-28 Thread ychawla
Hi Dominik, I think this is the default behavior in Java. Whenever I work with keystores, the keystore password must match the key password. This could be due to the KeyManagerFactory implementation: http://docs.oracle.com/javase/6/docs/api/javax/net/ssl/KeyManagerFactory.html#init%28java.secu

Inject camel resources into Spring bean

2012-12-21 Thread ychawla
Hello All, I am working on a WS-Policy implementation that requires a SAML token to be passed in the security header. CXF provides a SAML callback handler to support adding the token. I am using an STS so I call a web service to obtain the token. I obtain the token and set it in a header:

Re: Inject camel resources into Spring bean

2012-12-23 Thread ychawla
Hello, To solve this issue, you can access the CXF message like this: Message message = PhaseInterceptorChain.getCurrentMessage(); Camel will copy Camel headers to CXF headers. You can set your 'key' to your map as a Camel Header and then grab it off the CXF message. Thanks, Yogesh -- View

Aggregator Pattern - GroupExchanges

2011-05-02 Thread ychawla
Hello All, Does the GroupExchanges attribute look at the correlation expression and completion size? Or does it only look at the batch options. I have a route like this: header.requestGUID numberOfEndpointsRequested

CXF component with WS-Addressing and one way messages

2011-05-04 Thread ychawla
Hello All, I added WS Addressing to a CXF endpoint. I did it up by updating the CXF endpoint like this: Initially I was fooling around with the CXF bus and referencing that on an endpoint but the above method worked well. Can I update the WIK

Re: CXF component with WS-Addressing and one way messages

2011-05-04 Thread ychawla
An upgrade to version 2.2.12 corrected the exception, but brought up another one... I am calling a one-way service but a response is being sent back. For example: http://www.w3.org/2003/05/soap-envelope";> http://www.w3.org/2005/08/addressing";>urn:uuid:b8d0a8ca-ada1-4840-8722-a4859144

Re: CXF component with WS-Addressing and one way messages

2011-05-05 Thread ychawla
Well, this might not be an issues for the Camel mailing list. I downloaded cxf 2.4.0 and 2.2.12 and ran the WS Addressing samples distributed with them and saw the same behavior. I bumped this message over to the CXF mailing list. Thanks, yogesh -- View this message in context: http://camel.4

Re: Camel, Spring, routeContextRef and namespaces?

2011-05-09 Thread ychawla
Hello All, This definetly seems like a bug. Does anyone know if a JIRA has been filed? I am running across the same issue and working around it by setting up a bean and doing xpath injection. Thanks, yogesh -- View this message in context: http://camel.465427.n5.nabble.com/Camel-Spring-routeCon

Read file from within bundle?

2011-05-15 Thread ychawla
Hello All, I have some data file that reside inside a camel 2.6.0 bundle deployed inside of ServiceMix 4.3. I included some resources in my bundle: {maven-resources}, src/test/resources/xml/test=src/test/resources/xml/test However, I am not sure how I can read t

Re: Camel, Spring, routeContextRef and namespaces?

2011-05-15 Thread ychawla
Hi Guys, This works fine if you are referencing the XPath from your main context file, but if you are importing routes, it causes issues. Let me try to put together a test case that illustrates this bug. For now, I am doing XPath parameter injection on a bean and resolving my XPath that way. Che

Camel 2.7.2 in ServiceMix 4.3.0

2011-06-09 Thread ychawla
Hello All, I am trying to get Camel 2.7.2 running in ServiceMix 4.3.0. I ran a series of OSGi installs: osgi:install -s mvn:org.slf4j/log4j-over-slf4j/1.6.1 osgi:install -s mvn:org.slf4j/slf4j-api/1.6.1 osgi:install -s mvn:org.apache.camel/camel-core/2.7.2 osgi:install -s mvn:org.apache.camel/cam

Re: Camel 2.7.2 in ServiceMix 4.3.0

2011-06-10 Thread ychawla
Hi Jean Baptiste, Thanks for the advise. I made some progress. I updated org.apache.karaf.features.cfg with: mvn:org.apache.karaf/apache-karaf/2.1.5/xml/features mvn:org.apache.camel.karaf/apache-camel/2.7.2/xml/features Then I tried this: features:install camel-core 2.7.2 and got this error:

Re: Read file from within bundle?

2011-06-21 Thread ychawla
Hello All, This thread on the ServiceMix list shows you how to solve this problem: http://servicemix.396122.n5.nabble.com/Classpath-protocol-in-servicemix-td4490171.html#a4492467 Cheers, Yogesh -- View this message in context: http://camel.465427.n5.nabble.com/Read-file-from-within-bundle-tp439

Re: Disable CertificateValidation when Routing to HTTPS endpoint

2011-06-21 Thread ychawla
Does the server require a client certificate? If so, you need to get the Certificate Authority to provide you one. If the server just has an SSL Server certificate that is not in your truststore, you can use HTTP conduit to configure your truststore to accept the certificate or add the certificat

Re: Is there any way to 'park' values for later use

2011-06-28 Thread ychawla
Can you store the values in message Headers? -- View this message in context: http://camel.465427.n5.nabble.com/Is-there-any-way-to-park-values-for-later-use-tp4534068p4534096.html Sent from the Camel - Users mailing list archive at Nabble.com.

Synchronous route for an asynchronous web service pair

2011-07-07 Thread ychawla
Hello All, I have two one-way asynchronous web services. The first receives a request asynchronously. It processes it and then turns around sends a response to the second service. Both of these services will respond to any successful invocation with an HTTP 200 or 202 status and I am using a WS

Re: Synchronous route for an asynchronous web service pair

2011-07-08 Thread ychawla
Hi Freeman, I found this article written a while back that addresses this architecture: http://www.catify.com/2010/11/02/handling-http-requests-with-an-asynchronous-system-in-the-back/ It seems a little complicated though and I was hoping there was an EIP that would address this out of the box.

Exception when configuring data source in imported file

2011-07-28 Thread ychawla
Hello All, I am using Camel 2.6.0 and have my routes set up using the Spring DSL in a camel-context.xml file. I am looking to connect to a database using Hibernate with a pretty standard configuration: com.mysql.jdbc.Driver jdbc:mysql://xxx.x

Re: Exception when configuring data source in imported file

2011-07-29 Thread ychawla
Hi Claus, I tried with Spring 2.5.x and 3.0.x. I did read the Spring documentation here: http://static.springsource.org/spring/docs/2.5.x/reference/beans.html and they had some alternate syntax as well: ... (more properties below, omitted for brevity) This di

Re: CXF component with WS-Addressing and one way messages

2011-10-20 Thread ychawla
Hi Anton, Here is how you set the message ID: String requestID = "MY_MESSAGE_ID" if (StringUtils.isNotEmpty(requestID)) { // get Message Addressing Properties instance AddressingBuilder

Persisting a variable over different exchanges

2011-10-28 Thread ychawla
Hello All, I frequently set headers on an exchange so I can access them at different points on a route. Is there a way to persist a variable between different exchanges? I have a timer that will query a database every minute. I want to store the last record I queried so I only get new records.

TypeConverter GenericFile to InputStream

2011-12-02 Thread ychawla
Hello All, It looks like in Camel 2.6.0 there is no TypeConverter from GenericFile to InputStream. It is easy enough to get an InputStream from a GenericFile: Object body = exchange.getIn().getBody(); InputStream inputStream = null; if (body instanceof GenericFile) { GenericFile file = (GenericFi

Propogate CXF Exception to Camel

2012-02-16 Thread ychawla
Hello All, Consider a simple camel route like this that invokes a one way service: opName opNamespace If the endpoint you are invoking is down, CXF will throw an exception: Caused by: java.net.ConnectException: Conn

Re: Using Camel to as WS Broker

2012-02-16 Thread ychawla
Hi Guys, It looks like you want to use a single service as a facade to the multiple services behind the scenes. Camel can do that. Does the service that you want to use as the facade have a WSDL/Service Spec? If yes, you can set up a CXF endpoint in either Payload or POJO mode for that service.

Re: Propogate CXF Exception to Camel

2012-02-16 Thread ychawla
Hello All, I got Camel to see the exception by throwing a fault in my interceptor. This is probably not the preferred way to do this, but it seemed to work: public class CamelExceptionInterceptor extends AbstractPhaseInterceptor { public CamelExceptionInterceptor() { supe

Re: Propogate CXF Exception to Camel

2012-02-16 Thread ychawla
Hi Willem, Thanks for posting the unit test. I am wondering if I am getting the error because I am using a one-way exchange. For example, I also tried this with a producer template: senderExchange = new DefaultExchange(context, ExchangePattern.InOnly); enderExchange.getIn().setBo

Re: Propogate CXF Exception to Camel

2012-02-16 Thread ychawla
Well Willem, You have solved the problem... It is a bug with Camel 2.6.0 that is corrected in Camel 2.8.4. I am on ServiceMix 4.3.0 and that ships with Camel 2.6.0. I changed my POM to use the newer version of Camel and CXF and ran it in Eclipse just fine. Thanks for helping with this. -Yogesh

Camel log - part of body

2012-02-21 Thread ychawla
Hello All, In my camel routes, I use the log component quite a bit. For example: Is there a way with the simple language to only print out the first 100 characters or so of the body? I have some large XML file coming through that are really clogging up my logs. Thanks, Yogesh -- View this me

Re: Propogate CXF Exception to Camel

2012-03-02 Thread ychawla
Hi Willem, I upgraded to Camel 2.8.4 and CXF 2.4.6 and I still see this behavior. Here is my route. It basically reads from a folder and calls a web service:

Re: Does Camel supports dynamic routing by getting the routing info from database

2012-03-05 Thread ychawla
The other way you can do this is by using the Recipient List pattern: http://camel.apache.org/recipient-list.html You can query your database, have a bean where you setup a recipient list Header, and then call the recipient list. -- View this message in context: http://camel.465427.n5.nabble.co

RE: CXF endpoint's address dynamically modified?

2012-03-05 Thread ychawla
Hello All, I think this would be a great feature to have available with a cxf bean URI configuration. Consider the use case where Camel is acting as an intermediary broker/facade for other services. The broker and the services it fronts all share the same WSDL and service definition. The only di

Camel Properties Component Cache

2012-03-05 Thread ychawla
Hello All, The Camel Properties component is very cool, however there are a few enhancements which would make it even better. First off the 'Cache' property is very nice. If Cache is set to false, then you can change your properties file and Camel will pick up the changes. The default on this i

Re: Need help in Camel to send emails

2012-03-06 Thread ychawla
Hi, The body of the email will be whatever you have as the current body of the Camel exchange. You can explicitly set the body as well: This is my email body To control when the email is sent, you can split up your route: Then you can use quartz to set up a timer to poll your folde

Re: Need help in Camel to send emails

2012-03-06 Thread ychawla
Hi, Are you trying to set the 'to' field in your email. You can either set that on the smtp URI or in a header. For example: recipi...@domain.com The body of your email is whatever is on your message body. If you want to set it as part of your route, try using a bean: public String createEm

Re: http client cert verification

2012-03-06 Thread ychawla
On your client, you can add a HTTP conduit:

Re: Propogate CXF Exception to Camel

2012-03-07 Thread ychawla
Hi Aki, I do have a one-way service. I added the 'synchronous=true' to the endpoint and now it is throwing the error without using my custom interceptor. Will setting this attribute affect other behavior of the one-way service? Thanks, Yogesh -- View this message in context: http://camel.46542

Re: SMTP: sending file binary as attachment corrupted

2012-03-07 Thread ychawla
Hello, I remember I had some issues attaching files so I added a processor that read them directly from the file system. For example: public void addEmailAttachment(Exchange ex) { String fileNameWritten = (String)ex.getIn().getHeader("CamelFileNameProduced");

Dynamically set WSS4J interceptor properties

2012-03-09 Thread ychawla
Hello All, I am using Camel/CXF to implement WS-Security Requirements, specifically in this case Signature Encrypt and Timestamp. I used an example that Camel distributed as a starting point and manually configured the WSS4J interceptors. My issue is that my service will call maybe 10 or 20 ser

Re: Dynamically set WSS4J interceptor properties

2012-03-09 Thread ychawla
Another idea here is to set the scope to 'request' on the WSS4J interceptor and override a method to set the encryption user. Has anyone done that before similar to this: http://forum.springsource.org/showthread.php?81311-Configuring-WSS4J-Encrypt-for-multiple-clients-how Thanks, Yogesh -- View

Recipient List Error Handler

2012-03-30 Thread ychawla
Hello All, I have a simple recipient list in Camel 2.8.4: cxf:bean:someEndpoint?dataFormat=PAYLOAD&&synchronous=true routingSlipHeader I have my dead letter error handler set up with a redelivery policy. However, the recipie

Re: Recipient List Error Handler

2012-03-30 Thread ychawla
Please ignore this question. The error was with the bindingOperationInfo so it was fatal to the point where it wasn't a delivery issue. Once I fixed that, the redelivery policy works fine. Thanks! Yogesh -- View this message in context: http://camel.465427.n5.nabble.com/Recipient-List-Error-H

Retrieve Endpoint in Recipient List OnPrepareRef

2012-04-18 Thread ychawla
Hello All, Consider a simple recipient list: RecipientListHeader The Recipient List header has the contents: endpoint1, endpoint2 The endpoints are defined as: In my 'prepareMessage' processor, I want to access the endpoint that I am calling. This is becaus

Re: Problem with Camel,osgi-compendium and mvn camel:run

2012-05-02 Thread ychawla
Hi Dinesh, You will see a similar error if you try to run Camel JUnit tests and are using OSGi for your properties file. To make this slightly less painful, you can put your PropertyPlaceHolder in its own file. For example, this file can be called properties-context.xml http://www.springframewor

Producer Template to Invoke HTTP Endpoint Request/Reply

2012-05-03 Thread ychawla
Hello All, I have set up a simple HTTP service using Jetty that acts similar to a REST endpoint and servers up XML responses. The service works just fine and I am trying to add some unit tests to it. I have set up a simple producer template test and tried this: File inputFile = new File("someFil

Re: Producer Template to Invoke HTTP Endpoint Request/Reply

2012-05-03 Thread ychawla
So I also tried with an exchange/processor and no luck: Exchange result = template.request("http://localhost:8081/REST";, new Processor() { public void process(Exchange exchange) { Message in = exchange.getIn(); in.setBody(inputFile);

Re: Producer Template to Invoke HTTP Endpoint Request/Reply

2012-05-03 Thread ychawla
Hello All, Sorry for the bother. Please ignore this issue. I was setting the body of my response on my rest service as a buffered reader. This worked fined in the SMX container but was causing an issue in my unit test. I read a string from the buffered reader and set that as my service response

Re: If camel-jetty/camel-http can dynamically load keystore/trustsore changes

2012-05-04 Thread ychawla
Hi Leng, The keystore/truststore updates should be infrequent, right? Do you have a production environment with load balancing/failover? If so, you can take one server out of commission and perform maintenance and then update the other server. Otherwise, you probably have to do it in a maintenan

Re: camel-jaxb namespace prefix

2012-05-04 Thread ychawla
Hi Thomas, You can use JaxB NameSpacePrefixMapper to customize what the namespaces look like. Basically it would take ns2 and set it to something more intuitive of your choosing. See here for details: http://stackoverflow.com/questions/1982977/is-it-possible-to-customize-the-namespace-prefix-tha

Re: Dynamic source endpoint

2012-05-04 Thread ychawla
Hi, I would look into using a routing slip here as well. Depending on how dynamic your endpoints are you can poll the database using a timer, retrieve your endpoints, havw a bean processor that creates a routing slip header, and then send the exchange to the routing slip. This could work if you k

Re: multicast and setting header

2012-05-07 Thread ychawla
Hi Tyler, Are some of the headers in there but not all of them? If you want, you can use an aggregator with the multicast and set a custom aggregation strategy: http://camel.apache.org/maven/current/camel-core/apidocs/org/apache/camel/processor/aggregate/AggregationStrategy.html This way you can

Re: Integration Testing Best Practices...

2012-05-07 Thread ychawla
Hi James, I am working through the exact same issue as you are now. One thing that has been really worthwhile to look into is 'adviceWith': http://camel.apache.org/advicewith.html You can weave around particular endpoints and either replace the endpoint or intercept the messages in and out of th

Re: How to set the CRL path for Camel HTTP component?

2012-05-08 Thread ychawla
Hi Yoleng, I believe Camel uses not-yet-commons SSL under the covers. This page details how to set the CRL checking: http://juliusdavies.ca/commons-ssl/ssl.html It says that by default it will check the CRL: client.setCheckCRL( true ); // default setting is "true" for SSLClient Thanks, Y

Re: Waiting for Routes to Finish

2012-05-08 Thread ychawla
Hi, Camel offers some graceful shutdown functionality out of the box: http://camel.apache.org/graceful-shutdown.html Take a look and see if this fits your needs. Thanks, Yogesh -- View this message in context: http://camel.465427.n5.nabble.com/Waiting-for-Routes-to-Finish-tp5695837p5696383.htm

Re: dynamically creating directory with current date in yyyyMMdd format

2012-05-08 Thread ychawla
Hi Mahesh, You can try setting your file name with the dynamic format: ${date:now:MMdd}/someFileName.xml This will create a folder with the dynamic date and then put 'someFileName.xml' inside of it. This should work in the Java DSL as well. Thanks, Yogesh -- View this message in conte

Re: CXF webservice asyn

2012-05-08 Thread ychawla
Hi Deepthi, Claus has a blog post about concurrency that might point you in the right direction. Do you want a thread pool for your 'from' file endpoint? http://davsclaus.blogspot.com/2009/05/on-road-to-camel-20-concurrency-with.html Thanks, Yogesh -- View this message in context: http://camel

Re: how to specify remote file name when using FTP endpoint

2012-05-09 Thread ychawla
Hi, Did you try setting the camel file name header: someNewFileName.txt Thanks, Yogesh -- View this message in context: http://camel.465427.n5.nabble.com/how-to-specify-remote-file-name-when-using-FTP-endpoint-tp5697227p5698676.html Sent from the Camel - Users mailing list archive at Nabbl

Re: Converting CSV to XML

2012-05-17 Thread ychawla
Hi Amby, What about using a simple XSLT to go from the outputted format to your desired format? It should be a pretty straight forward transformation. Thanks, Yogesh -- View this message in context: http://camel.465427.n5.nabble.com/Converting-CSV-to-XML-tp5711086p5711598.html Sent from the Cam

Re: Converting CSV to XML

2012-05-17 Thread ychawla
Hi Christian, You are correct that you can use XSLT on CSV, but he can get the data into this format: Name Age Sex Zip Edward 22 M 33639 .. He can use an XSLT to go from that to this: Edward 22 M 33639 Th

Re: Best Practice for splitting on header?

2012-05-25 Thread ychawla
Hi, Do you need to use a bean/producer template to do this? Some of this might be built right in to the Recipient List EIP. For example, in Spring: endpointsToCall In the above snippet, you set a header with your endpoints, a delimiter of '|' and a strategy to aggregate all your responses

Re: xslt error with document('')

2012-05-25 Thread ychawla
Hi Marco, Are you using the same XSLT processors in eclipse and in Camel? I like using Saxon and you can customize your XSLT processor like this: Thanks, Yogesh -- View this message in context: http://camel.465427.n5.nabble.com/xslt-error-with-document-tp5713535p5713572.html Sent from the C

Re: camel-cxf and HTTP BASIC authentication

2012-07-17 Thread ychawla
Hi Christian, What about adding an HTTP Conduit to your CXF bean? http://cxf.apache.org/docs/client-http-transport-including-ssl-support.html Is your requirement for inbound or outbound HTTP basic auth? Depending on your container, you might be able to do this at the Apache HTTPD or Tomcat layer

Re: camel-cxf and HTTP BASIC authentication

2012-07-17 Thread ychawla
Just re-read your message and you have a ServiceMix requirement so Tomcat and Apache HTTPD wouldn't work. I saw some blog entries that talks about an interceptor based approach that might help: http://chrisdail.com/2008/03/31/apache-cxf-with-http-basic-authentication/ http://chrisdail.com/2008/08

Re: Camel CXF synchronous=true setting causes CXF bean invocation last for 60 seconds or more

2012-07-17 Thread ychawla
Hi Igor, I am not sure what version of Camel and CXF that FUSE version uses. When using the 'synchronous=true' URI option in Camel 2.6.0, I wrote an interceptor to rethrow the exception so it would propogate back to my route. Something simple like: public class CamelExceptionInterceptor extends

Re: Dynamic generation of Camel routes

2012-07-18 Thread ychawla
Would a routing slip work for you? You can dynamically configure where your message is going, not necessarily what your input is. However, depending on your requirements, this could suffice: http://camel.apache.org/routing-slip.html -- View this message in context: http://camel.465427.n5.nabbl

Camel keeps dropping ActiveMQ connections

2012-07-19 Thread ychawla
Hello All, I have an application running that has frequent lulls in activity. What I find is that the activemq consumers lose their connections. I have a read few posts about this and taken the suggestions to set keepAlive to true and use a connection pool: [1] keep alives http://camel.465427.n5

  1   2   >