Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.

Bug 108264

Summary: [Debug] Thread names are not updated
Product: [Eclipse Project] JDT Reporter: Peter Larsen <peblpebl>
Component: DebugAssignee: JDT-Debug-Inbox <jdt-debug-inbox>
Status: RESOLVED DUPLICATE QA Contact:
Severity: minor    
Priority: P3    
Version: 3.2   
Target Milestone: ---   
Hardware: PC   
OS: Windows XP   
Whiteboard:

Description Peter Larsen CLA 2005-08-29 09:11:05 EDT
When a thread changes its name, while showing the debug view,
the debug view is not updated. The only way to get the debug view
to show the new names is to select another view and go back.

This a big problem in a multithreaded program where threads are reused.

The following simple program shows it. Start in debug mode and show the debug
view. After 10 seconds the thread name should change but doesnt. 

Build id: I20050811-1530

public class ThreadnameBug extends Thread{
	
	public static void main(String[] artgs) {
		new ThreadnameBug().start();
	}

	public void run() {
		try {
			System.out.println("Sets name to 1");
			setName("Name1");
			sleep(10000);
			System.out.println("Sets name to 2");
			setName("Name2");
			join();
		} catch (InterruptedException e) {}
	}	
}
Comment 1 Darin Wright CLA 2005-08-29 09:44:01 EDT

*** This bug has been marked as a duplicate of 54494 ***