ActiveMQ send and receive folder of XML file
I have a java application that makes I/O of files:
Module 1 : output txt file (HardDisk).开发者_StackOverflow社区 Module 2: input txt file (HD) output: folder of XML files (HD)
I want to benefit from ActiveMQ
Module 1 -> output(send) txt file (stored as a message in ActiveMQ) Module 2: input (receive) : txt file (message), output (send) : folder of XML files (ActiveMQ message)
I want store my files in ActiveMQ and NOT in my HD.
its possible to do that with activeMQ?
ActiveMQ is not a storage facility, it is a message-passing facility.
That being said you should look at Camel, Mule or Spring Integration, all of which can use ActiveMQ for messaging. They all have support for polling folders for files to send as messages and depositing messages into folders.
I just use a text type message and convert the xml
docs into strings and then write out to the body of the text message.
Example:
textMsg.setText("<my_xml><whatever></whatever></my_xml>");
精彩评论