質問

I have an ActiveMQ Queue "SMS.Send" I successfully push (persistent) messages to this Queue.

Second, I have a working Camel-Context and Camel-Route using Camel-SMPP & Karaf.

<route>
   <description>Example Camel Route</description>
   <from uri="activemq:SMS.Send"/>
   <to uri="smpp://smppclient1@localhost:2775?password=password&amp;enquireLinkTimer=3000&amp;transactionTimer=5000&amp;systemType=producer"/>
</route>

Camel seems to fetch the messages from the queue and tries to push them to my SMPPSim (SMSC Simulation Tool), but it's apparently not successful.

I'm at a complete loss, as to

  1. how the message in the queue must be set up (TextMessage? MapMessage? ...?) for successful delivery
  2. how to tell Camel to use SubmitSM

and I couldn't find any existing info on that...

役に立ちましたか?

解決

So, I found out some details for myself.

Camel did NOT successfully connect to SMPPSim (I detected it using log:tail in the karaf console)

Once the connection was successfully established, it worked out of the box: Just use TextMessage for the ActiveMQ-Queue and the body of the TextMessage will be the body/message-text of the SMS. Set headers for the Queue and camel will forward it as headers for the SMSC-Server. Then there are the camel-special-headers that it uses for the configuration, as documented. For example:

request.Properties["CamelSmppDestAddr"] = number.ToString();

Plus: I found out how to install camel:smpp without using karaf and just using ApacheMQ with the camel plugin: Download the camel-smpp-**.jar file (in my case camel-smpp-2.12.1.jar) and put it in the [activemq-root-folder]/lib/camel/ folder. The Jsmpp-dependency was missing; Search for it (as of now: jsmpp-2.1.0) and put it directly in the lib folder!

ライセンス: CC-BY-SA帰属
所属していません StackOverflow
scroll top