Issue Details (XML | Word | Printable)

Key: GDS-802
Type: Bug Bug
Status: Resolved Resolved
Resolution: Fixed
Priority: Major Major
Assignee: Franck Wolff
Reporter: John Fletcher
Votes: 0
Watchers: 1
Operations

If you were logged in you would be able to see more operations.
GraniteDS

Gravity does not reconnect when the connection between app server and JMS breaks/reconnects

Created: 10/Nov/10 09:53 AM   Updated: 11/Oct/12 11:56 AM   Resolved: 11/Oct/12 11:56 AM
Component/s: Gravity
Affects Version/s: 2.2.0_RC2
Fix Version/s: 3.0.0.M1


 Description  « Hide
I'm running JMS messages from ActiveMQ (standalone, not VM) to Flex using Gravity.

When my application server loses the connection to ActiveMQ it automatically reconnects after a short time and continues to receive messages. However when this happens the Flex clients also lose their connection but never reconnect. The Flex app needs to be restarted to regain the connection.

Flex should reconnect automatically or otherwise nicely handle.

One way to reproduce:
Run ActiveMQ on localhost (or wherever)
Create a grails project
Install GDSFlex
Create Flex project and configure gravity with JMS to connect to ActiveMQ
Send messages to the relevant Topic. They will be handled by Flex.
Break the connection to ActiveMQ eg. by restarting ActiveMQ
Send messages to the relevant Topic. They will not be handled by Flex.
Reload Flex application
Send messages to the relevant Topic. They will be handled by Flex.

William Draï added a comment - 18/May/12 10:59 PM
Not absolutely sure, but it should be fixed since 2.3.x.
It looks like the same case than server failover when clustering ActiveMQ instances.

John Fletcher added a comment - 22/May/12 05:20 PM
Nah it doesn't work. What does work is to disconnect from the channel and then reconnect, like:

consumer.unsubscribe();
consumer.disconnect();
var channelSet:ChannelSet = new ChannelSet();
channelSet.addChannel(ServerConfig.getChannel(Globals.ID_GRAVITY_CHANNEL));
consumer.channelSet = channelSet;
consumer.destination = topic;
consumer.subscribe();

But it doesn't reconnect automatically.

John Fletcher added a comment - 22/May/12 05:20 PM
(tried with 2.3.1)