Use unique Thread names among connections

Description

PacketReader creates 2 threads in the constructor with a static name so the name will be the same if we have many readers for many connections.

PacketWriter creats 3 threads in the constructor. Two of them have a static name whilst the last thread has no name.

Notify this thread when done:
http://www.jivesoftware.org/forums/thread.jspa?threadID=14385&tstart=0

Environment

None

Activity

Show:

MattM 
February 5, 2007 at 4:51 AM

When creating the threads, we don't yet have the username of the user that's logging in. We also don't have the connection ID from the server. Therefore, I created a new connection counter in XMPPConnection. All threads that get created then use a unique ID for the connection. Nice things about this value:

  • You can easily tell which threads are older than others by looking at the number.

  • The number stays consistent between connects and disconnects to the server (this could be a good or bad thing).

Fixed

Details

Assignee

Reporter

Components

Fix versions

Affects versions

Priority

Created March 31, 2005 at 5:30 AM
Updated February 5, 2007 at 4:51 AM
Resolved February 5, 2007 at 4:51 AM

Flag notifications