0

My application, running in a JBOSS standalone env, relies on a HornetQ (v2.2.5.Final) middleware to exchange messages between parts of my application in a local environment - not over the network.

The default TTL (time-to-live) value for the connection is 60000ms, I am thinking of changing that to -1 since, from an operative point of view, I am looking forward to keep sending messages through such connection from time to time (not known in advance). Also, that would prevent issues like jms queue connection failure.

The question is: what are the issues with never timing out a connection on the server side, in such context? Is that a good choice? If not, is there a strategy that is suited for such situation?

LoreV
  • 575
  • 5
  • 25
  • 1
    What version of HornetQ are you using? The latest versions automatically disable connection checking for in-vm connections. – Justin Bertram Sep 21 '18 at 18:48
  • Hi Justin, I am using v2.2.5.Final which dates 2011 – LoreV Sep 24 '18 at 08:20
  • 1
    This is a pretty vague question. Are you trying to address a current issue or avoid an issue that you're worried about? – theMayer Sep 25 '18 at 20:38
  • I am trying to address a current issue related to https://stackoverflow.com/questions/26883982/jboss7-remote-mdb-connection-to-jms-queue-connection-failure-has-been-detected. What I am worried about is that something may break if I was to set ttl = -1 and rely on this connection to be open at all times. – LoreV Sep 26 '18 at 11:01

1 Answers1

1

The latest versions of HornetQ automatically disable connection checking for in-vm connections so there shouldn't be any issues if you configure this manually.

Justin Bertram
  • 29,372
  • 4
  • 21
  • 43
  • Agreed. Configuring it manually is an acceptable choice for in-vm connections. It prevents HQ from closing the connections for timeout and is not causing any issue with the application side. Tested on many hours monitored run. – LoreV Oct 01 '18 at 07:38