• Bug
  • Status: Closed
  • 2 Major
  • Resolution: Fixed
  • kkannaiy
  • Reporter: tgautier
  • December 11, 2007
  • 0
  • Watchers: 1
  • February 12, 2013
  • February 07, 2008


046 public class Main extends JFrame implements ActionListener, ChatterDisplay, 047 WindowListener { 048 049 private final ChatManager chatManager = new ChatManager(); 050 051 private final JTextPane display = new JTextPane(); 052 053 private User user; 054 055 private final JList buddyList = new JList(); 056 057 private boolean isServerDown = false; 058 private static final String CHATTER_SYSTEM = “SYSTEM”; 059 060 public Main() { 061 try { 062 final String nodeId = registerForNotifications(); 063 user = new User(nodeId, this); 064 populateCurrentUsers(); 065 login(); 066 }

between lines 49 and 65, there is a race - since the login method sets up a local listener for all chat events, it’s easy to lose the other client login if execution of 1 node is between 49 and 65, and the other completes 65 (the login process)


Fiona OShea 2008-01-23

Kalai this may be related to the issue you saw in chatter this week?

Kalai Kannaiyan 2008-01-24

Tested with 2.5.1 rev6793, it is working as expected.

  1. Install the kit
  2. Start the demo server
  3. Launch the chatter demo

Actual: username and client node Id are displayed in the chatter demo and in th admin console

demo.chatter.Main.chatManager(dem.chater.chatManager) demo.chatter.Main.chatManager.users(java.util.TreeMap value(demo.chatter.User) demo.chatter.User.name(String): user name is displayed demo.chatter.User.nodeId(String):clientID[0]

Fiona OShea 2008-01-29

Closing based on Kalai’s tests

Taylor Gautier 2008-02-07

You have to start the two clients at the same time. Human time will not show this race. Maven usually starts them close enough.

Fiona OShea 2008-02-07

See Glassfish changes.

To verify the fix on this the only way to see the issue is to start multiple instances, really really quickly/really at the same time.
The best way to do this is to automate it.

Hung Huynh 2008-02-07

Tim has fixed this in the tc-2.5 branch of this project. Juris/Jason just needs to make a new release.

Juris Galang 2008-02-08

I already ported this fix in the tc-2.5 branch of chatter in the Forge. This issue should be fixed in release-1.0.2 - Jason has to release the Forge core artifacts before we could create a new release.

Juris Galang 2008-02-08

Also, Kalai should be able to verify this by checking out: https://svn.terracotta.org/repo/forge/projects/chatter/branches/tc-2.5

Kalai Kannaiyan 2008-03-07

Retested this issue with chatter-1.0.3-SNAPSHOT.jar from tc-2.5 branch. It is working as expected.

Steps to reproduce:

  1. svn co https://svn.terracotta.org/repo/forge/projects/chatter/branches/tc-2.5
  2. Verify that the tc-2.5 is created
  3. cd tc-2.5
  4. mvn clean install
  5. mvn clean tc:run

Actual: DSO Server started successfully and chatter window1 and chatter window2 are displayed in the same time with list of names.