You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@qpid.apache.org by akabhishek1 <ma...@gmail.com> on 2020/07/02 15:37:55 UTC

Feature request - increase visibility of JmsSession.checkClosed() method

Hi Team,

We are using qpid library to publish/receive messages from ServiceBus.
Microsoft ServiceBus forcefully detach the connected session if session is
idle, same behavior for JMS connection as well.

Microsoft ServiceBus also has limitation that we can not create too much JMS
sessions and producers as well.

Due to this limitation, we have to use some sessions and producer to perform
all activities.

I looked on QPid class org.apache.qpid.jms.JmsSession, checkClosed()
internally used to check session status but this method is protected, so it
will be used in internal classes only.

I would like to request you - Can you please increase visibility(protected
to public) of checkClosed() method, so we can check session status as well
before performing any action.

This will be a great facility for ServiceBus use case. Please suggest your
opinion.

Regards,
Abhishek Kumar



--
Sent from: http://qpid.2158936.n2.nabble.com/Apache-Qpid-users-f2158936.html

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@qpid.apache.org
For additional commands, e-mail: users-help@qpid.apache.org


Re: Feature request - increase visibility of JmsSession.checkClosed() method

Posted by Timothy Bish <ta...@gmail.com>.
On 7/2/20 11:37 AM, akabhishek1 wrote:
> Hi Team,
>
> We are using qpid library to publish/receive messages from ServiceBus.
> Microsoft ServiceBus forcefully detach the connected session if session is
> idle, same behavior for JMS connection as well.
>
> Microsoft ServiceBus also has limitation that we can not create too much JMS
> sessions and producers as well.
>
> Due to this limitation, we have to use some sessions and producer to perform
> all activities.
>
> I looked on QPid class org.apache.qpid.jms.JmsSession, checkClosed()
> internally used to check session status but this method is protected, so it
> will be used in internal classes only.
>
> I would like to request you - Can you please increase visibility(protected
> to public) of checkClosed() method, so we can check session status as well
> before performing any action.

The JMS resources all throw exceptions from the API methods if the 
resource is closed or the underlying connection is closed, your code 
should always be ready to handle such errors and react accordingly.  As 
well the JMS Connection provides the ExceptionListener to inform you of 
connection drops should the remote close the connection or the 
underlying connection be dropped for some reason so you can react to 
that as well.

There isn't any reason you need to be able to poll the session directly 
as you still need to react to errors thrown from the JMS API methods 
either at the Session level or at the MessageProducer or MessageConsumer 
level since they could fail at any time due to interruption.


> This will be a great facility for ServiceBus use case. Please suggest your
> opinion.
>
> Regards,
> Abhishek Kumar
>
>
>
> --
> Sent from: http://qpid.2158936.n2.nabble.com/Apache-Qpid-users-f2158936.html
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: users-unsubscribe@qpid.apache.org
> For additional commands, e-mail: users-help@qpid.apache.org
>

-- 
Tim Bish


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@qpid.apache.org
For additional commands, e-mail: users-help@qpid.apache.org