How set JMS message string properties? |
I need to send JMS text messages with several string properties. Is there a way to do this using com.atomikos.jms.extra.AbstractJmsSenderTemplate subclasses?
Jane Eisenstein
Monday, May 23, 2011
Hi,
Sure, you need to implement the interface JmsSenderTemplateCallback and set the properties yourself; have a look at how the default SendTextMessageCallback class does this...
HTH
Guy Pardon
Monday, May 23, 2011
Won't I also need to override AbstractSendMessageCallback.sendTextMessage to use my call back?
Jane Eisenstein
Tuesday, May 24, 2011
I went through the exercise of implementing an extension of the ConcurrentJmsSenderTemplate that uses an implementation of AbstractSendMessageCallback to add message properties to text messages.
Times for running 1000 transactions using these classes versus running 1000 transactions using org.springframework.jms.core.JmsTemplate were not significantly different.
Both sets of tests used com.atomikos.jms.AtomikosConnectionFactoryBean and used a db and JMS poolsize of 20.
Jane Eisenstein
Tuesday, May 24, 2011
OK thanks for the update...
Guy Pardon
Saturday, June 04, 2011
|