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

Bug 353573

Summary: creating 2 Runtimes of one and the same type messes with the suffix number
Product: [WebTools] WTP ServerTools Reporter: Dimitar Giormov <dimitar.giormov>
Component: wst.serverAssignee: wst.server <wst.server-inbox>
Status: RESOLVED DUPLICATE QA Contact: Elson Yuen <eyuen7>
Severity: normal    
Priority: P3 CC: cbridgha
Version: 3.3   
Target Milestone: 3.2.5   
Hardware: PC   
OS: Windows 7   
Whiteboard:
Attachments:
Description Flags
suffix index is incremented after it is added to the name. none

Description Dimitar Giormov CLA 2011-08-02 09:03:27 EDT
Steps to reproduce.

1. Create Type A Runtime
2. Create another Type A Runtime

the second will have suffix index 3 instead of 2
Comment 1 Dimitar Giormov CLA 2011-08-02 09:05:02 EDT
Created attachment 200709 [details]
suffix index is incremented after it is added to the name.
Comment 2 Dimitar Giormov CLA 2011-08-02 09:16:03 EDT
To clarify a bit the fix will increment the suffix after the suffix is added to the name not before.

Behavior till now:
e.g. Tomcat Runtime exists
suffix initial value was 2 
check if Tomcat Runtime returns true
and the suffix is incremented and then added to the Tomcat Runtime (3)

The fix will add the suffix to the name before incrementing - Tomcat Runtime(2)
Comment 3 Elson Yuen CLA 2011-08-16 17:11:51 EDT
This problem is the same the reported problem as bug 334705

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