Important Notice: Our web hosting provider recently started charging us for additional visits, which was unexpected. In response, we're seeking donations. Depending on the situation, we may explore different monetization options for our Community and Expert Contributors. It's crucial to provide more returns for their expertise and offer more Expert Validated Answers or AI Validated Answers. Learn more about our hosting issue here.

Why do the TopicSession.createDurableSubscriber and TopicSession.unubscribe calls raise JMSException with the message “ORA – 4020 – deadlock detected while trying to lock object”?

0
Posted

Why do the TopicSession.createDurableSubscriber and TopicSession.unubscribe calls raise JMSException with the message “ORA – 4020 – deadlock detected while trying to lock object”?

0

CreateDurableSubscriber and unsubscribe calls require exclusive access to the Topics. If there are pending JMS operations (send/publish/receive) on the same Topic before these calls are issued, the ORA – 4020 exception is raised. There are two solutions to the problem: Try to isolate the calls to createDurableSubscriber and unsubscribe at the setup or cleanup phase when there are no other JMS operations happening on the Topic. That will make sure that the required resources are not held by other JMS operational calls. Hence the error ORA – 4020 will not be raised. Issue a TopicSession.commit call before calling createDurableSubscriber and unsubscribe call.

Related Questions

What is your question?

*Sadly, we had to bring back ads too. Hopefully more targeted.

Experts123