Skip to Main Content

Database Software

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

NullPointerException in ActiveMQ due to Oracle AQ setting message headers to null

user12000104Nov 21 2019

Hi,

I am sending messages via Oracle AQ on an Oracle Database 18c Enterprise Edition Release 18.0.0.0.0. An application server (Wildfly 18) running ActiveMQ (Apache Artemis 2.10.1) is set up consuming all the messages from the Oracel AQ.

While processing the messages I hit a NullPointerException when the message header JMSXGroupSeq is handled. Further investigations show that Oracle AQ is setting some headers to null by default for new messages. Here is a list of JMS headers of one of the messages I received:

JMS_OracleHeaderOnly=null,

JMSXUserID=null,

JMSXGroupSeq=null,

JMS_OracleOriginalMessageID=null,

JMS_OracleDelay=0,

JMSXAppID=null,

JMSXRcvTimestamp=1574267857226,

JMSXGroupID=null,

JMS_OracleDeliveryMode=null,

JMSXState=0,

JMSXDeliveryCount=1,

JMS_OracleConnectionID=null,

JMS_OracleExcpQ=null,

JMS_OracleTimestamp=1574267858226

Is this a desired behaviour? I would prefer not having some headers set automatically.

Additionally: Section 3.5.9 of both the JMS 2.0 & 1.1 specifications indicate that the JMSXGroupSeq property is of type int. An int is a primitive type and therefore should not be null. Based on this, using null is not compliant with the JMS specification.

Thanks for the support and kind regards

Michael Szodorai

Comments

Post Details

Added on Nov 21 2019
0 comments
765 views