JCSMP solace library [ConditionalBoundedMessageQueue:|Queue is suspended]

sysem
sysem Member Posts: 15

I have a Java application which would send message out continuously.

However, at one occasion, this application cannot send out any message out until i restart it which is some hours later.

From the application log, seems "ConditionalBoundedMessageQueue" is suspended, and block the "JCSMPXMLMessageProducer" 's send function without any exception throwing out.

It only happen once and i don't know how can i replicate it and avoid that condition further.


I would like to know:

  1. In what condition, the solace library internal class "ConditionalBoundedMessageQueue" would be suspended ??
  2. What is the suggested error handling approach for this condition ?? Is it possible to throw an exception out.


Application Log

2023-03-06 18:41:37,305364|DEBUG|TID 257| - sendThread|PubADManager:|Client-4:Flow-13589: Starting pub ad timer: already scheduled in 1733, do nothing

2023-03-06 18:41:37,305374|DEBUG|TID 257| - sendThread|HeartbeatService:|Update last sent time to 2023-03-06T18:41:37.305365 and last seqNum to 1002194540000000000 for publish topic xxxa

2023-03-06 18:41:37,305376|DEBUG|TID 257| - sendThread|:||finish publish msg, seqnum: 125694, commsID PublishComms

2023-03-06 18:41:37,305391|DEBUG|TID 257| - sendThread|:||Start to publish msg to destination: xxxb, seqnum: 125695, commsID PublishComms

2023-03-06 18:41:37,305396|DEBUG|TID 257| - sendThread|JCSMPXMLMessageProducer:|Client-4:Flow-13589: About to send message

2023-03-06 18:41:43,633213|DEBUG|TID 255|Context_4_ReactorThread|PubADManager:|Client-4:Flow-13589: State Change: Sending->Retransmitting with input: AckTimeout

2023-03-06 18:42:04,851097|DEBUG|TID 257| - sendThread|ConditionalBoundedMessageQueue:|Update message ID before enqueue it: com.solacesystems.jcsmp.impl.JCSMPGenericXMLMessage[messageId=203753,ackMessageId=0,prevId=203752,CID_count=0,userData=,type=PERSISTENT,priority=4,redelivered=false,timeToLive=150000,expiration=0,dmqEligible=false,topicSeqNum=null,metadataLen=0,contentLen=0,attLen=274,sendAttemptedOnce=false,ackImmediately=false,safeToRelease=false,retransmitting=false,sendCount=0@32ed82e]

2023-03-06 18:42:04,851137|DEBUG|TID 255|Context_4_ReactorThread|JCSMPXMLMessageProducer:|Client-4:Flow-13589: scheduleRetransmitTask: lastIdSend 138956 window=1

2023-03-06 18:42:04,851259|DEBUG|TID 255|Context_4_ReactorThread|JCSMPXMLMessageProducer:|Client-4:Flow-13589: Got response for AD msg=203752, retransmitRequired=false, isRollbackOnly=false

2023-03-06 18:42:04,851262|DEBUG|TID 255|Context_4_ReactorThread|ADManager:|Client-4:Flow-13589: Clear AD timer

2023-03-06 18:42:04,851270|DEBUG|TID 255|Context_4_ReactorThread|PubADManager:|Client-4:Flow-13589: Processing windowed ack ackid=203752, ackEventCode=SUPPORTED_ACK_EVENT_MODE_PER_MSG

2023-03-06 18:42:05,047433|DEBUG|TID 1106|Context_4_Thread_retransmit_service|JCSMPXMLMessageProducer:|Client-4:Flow-13589: handleRetransmitAdMsgsRequest

2023-03-06 18:42:15,525855|DEBUG|TID 255|Context_4_ReactorThread|PubADManager:|Client-4:Flow-13589: Windowed ack for: msg=203752

2023-03-06 18:42:15,525913|DEBUG|TID 255|Context_4_ReactorThread|PubADManager:|Client-4:Flow-13589: Starting pub ad timer: scheduled new timer in 2000

2023-03-06 18:42:15,525937|DEBUG|TID 255|Context_4_ReactorThread|PubADManager:|Client-4:Flow-13589: State Change: Retransmitting->Sending with input: RetransmitDone

2023-03-06 18:42:15,526235|DEBUG|TID 257| - sendThread|ConditionalBoundedMessageQueue:|Suspend message queue

2023-03-06 18:42:15,526252|DEBUG|TID 257| - sendThread|JCSMPXMLMessageProducer:|Client-4:Flow-13589: add AD message to the queue: com.solacesystems.jcsmp.impl.JCSMPGenericXMLMessage[messageId=203753,ackMessageId=0,prevId=203752,CID_count=0,userData=,type=PERSISTENT,priority=4,redelivered=false,timeToLive=150000,expiration=0,dmqEligible=false,topicSeqNum=null,metadataLen=0,contentLen=0,attLen=274,sendAttemptedOnce=false,ackImmediately=false,safeToRelease=false,retransmitting=false,sendCount=0@32ed82e]

2023-03-06 18:42:15,526313|DEBUG|TID 257| - sendThread|PubADManager:|Client-4:Flow-13589: Starting pub ad timer: already scheduled in 1999, do nothing

2023-03-06 18:42:15,526357|DEBUG|TID 257| - sendThread|HeartbeatService:|Update last sent time to 2023-03-06T18:42:15.526319 and last seqNum to 1002194540000000000 for publish topic xxxb

2023-03-06 18:42:15,526362|DEBUG|TID 257| - sendThread|:||finish publish msg, seqnum: 125695, commsID PublishComms

2023-03-06 18:42:15,526391|DEBUG|TID 257| - sendThread|:||Start to publish msg to destination: xxxc, seqnum: 125696, commsID PublishComms

2023-03-06 18:42:15,526405|DEBUG|TID 257| - sendThread|JCSMPXMLMessageProducer:|Client-4:Flow-13589: About to send message

2023-03-06 18:42:15,526415|DEBUG|TID 257| - sendThread|ConditionalBoundedMessageQueue:|Queue is suspended, wait....

Answers

  • sysem
    sysem Member Posts: 15
    edited March 2023 #2

    In C#, there is a session property called "BlockingWriteTimeoutInMsecs"

    which would return in case timeout reach.


    But In java, in case we implement send timeout by ourselves, how can we tell solace library to stop retransmit that message?? Otherwise, it would block any further message to be sent out through that JCSMPXMLMessageProducer object instance ??


    Or we need to re-init the whole JCSMPXMLMessageProducer object instance ??


    For the Java JCSMP Library version, we are using 10.13.1, seems this issue is similar to SOL-59955, which has already resolved in 10.13.0 ??

    (Solace_Messaging_API_Jcsmp_Release_Notes_R10180_Iss01.html)