Gert Vanthienen, Thanks for your help. I have made the change you have suggested. However, I'm still having problems getting smpp to output to the screen. I don't know if it is because of the smpp configuration or camel configuration.
Thanks, Joel Gert Vanthienen wrote: > > Joel, > > I think there's a problem with the from(...) end of your camel route. > The correct uri for service 'tut:smpp_service' and endpoint 'endpoint' > is > jbi:endpoint:urn:org:apache:servicemix:tutorial:testsmpp:smpp_service:endpoint > (jbi:endpoint:<namespace>:<service name>:<endpoint name>) > > Regards, > > Gert Vanthienen > ------------------------ > Open Source SOA: http://fusesource.com > Blog: http://gertvanthienen.blogspot.com/ > > > > 2009/10/6 gardion1 <[email protected]>: >> >> Hello, >> >> I am trying to get use servicemix to receive messages via smpp and output >> them to the terminal. I am using servicemix-smpp and servicemix-camel >> compenents. >> >> Here is the xbeans.xml file that I used for servicemix-smpp >> >> <?xml version="1.0"?> >> <beans xmlns:smpp="http://servicemix.apache.org/smpp/1.0" >> xmlns:tut="urn:org:apache:servicemix:tutorial:testsmpp"> >> >> <smpp:consumer service="tut:smpp_service" >> endpoint="endpoint" >> host="agsbd02" >> port="2775" >> systemId="test" >> password="test" >> targetService="tut:smpp_service" >> targetEndpoint="endpoint"/> >> </beans> >> >> With this configuration I can receive sms's from an smsc simulator. The >> smpp component seems to give the appropriate responses to the smsc >> simulator >> >> However, if I want to forward messages from smpp component in servicemix >> to >> the console with camel routing I have problems. Here is my camel >> configuration. >> >> Under my camel su configuration I have the following java file >> (MyRouteBuilder.java) >> >> package org.apache.servicemix.aegis.smpp; >> import javax.xml.transform.dom.DOMSource; >> import org.apache.camel.Exchange; >> import org.apache.camel.Processor; >> import org.apache.camel.builder.RouteBuilder; >> >> /** >> * A Camel Router >> * >> * @version $Revision: 1.1 $ >> */ >> public class MyRouteBuilder extends RouteBuilder { >> >> public void configure() { >> >> from("jbi:endpoint:urn:org:apache:servicemix:tutorial:testsmpp:smpp:consumer") >> // 1 >> .to("log:tutorial-jbi") >> // 2 >> .convertBodyTo(DOMSource.class) >> // 3 >> .to("log:tutorial-domsource") >> // 2 >> .convertBodyTo(String.class) >> // 3 >> .to("log:tutorial-string"); >> /* >> from("timer://tutorial?fixedRate=true&delay=3000&period=10000") >> // 1 >> .setBody(constant("Hello world!")) >> // >> 2 >> .to("log:tutorial"); >> */ >> } >> } >> >> The problems is I don't see anything from smpp on the console. If I >> comment >> the first from statement and uncomment the second from timer section I >> see >> hello world on the terminal. Can you see why I am not getting any >> messages >> from smpp to the terminal? >> >> In case it matters my camel-context.xml file looks like this >> >> <beans xmlns="http://www.springframework.org/schema/beans" >> xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" >> xsi:schemaLocation=" >> http://www.springframework.org/schema/beans >> http://www.springframework.org/schema/beans/spring-beans-2.0.xsd >> http://activemq.apache.org/camel/schema/spring >> http://activemq.apache.org/camel/schema/spring/camel-spring.xsd >> "> >> >> <!-- >> from("seda:a").to("seda:b"); >> --> >> <camelContext id="camel" >> xmlns="http://activemq.apache.org/camel/schema/spring"> >> <package>org.apache.servicemix.aegis.smpp</package> >> >> </camelContext> >> >> </beans> >> <!-- END SNIPPET: camel --> >> >> Thank you for any help you can offer. >> >> Joel. >> -- >> View this message in context: >> http://www.nabble.com/using-smpp-to-output-to-the-screen-tp25758143p25758143.html >> Sent from the ServiceMix - User mailing list archive at Nabble.com. >> >> > > > ----- > --- > Gert Vanthienen > http://gertvanthienen.blogspot.com > -- View this message in context: http://www.nabble.com/using-smpp-to-output-to-the-screen-tp25758143p25777455.html Sent from the ServiceMix - User mailing list archive at Nabble.com.
