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

Bug 221685

Summary: "The servlet display name already exists. " used in the Filter wizard
Product: [WebTools] WTP Java EE Tools Reporter: Kaloyan Raev <kaloyan>
Component: jst.servletAssignee: Kaloyan Raev <kaloyan>
Status: CLOSED FIXED QA Contact: Chuck Bridgham <cbridgha>
Severity: normal    
Priority: P3 CC: ccc, thebravoman
Version: 3.0   
Target Milestone: 3.0 M6   
Hardware: PC   
OS: Windows XP   
Whiteboard:
Attachments:
Description Flags
patch none

Description Kaloyan Raev CLA 2008-03-06 11:42:38 EST
Steps to reproduce:
1. Create a Dynamic Web project. 
2. Create a Servet with name "A". 
3. Invoke the Filter wizard. 
4. Enter "B" for Class name (first page). 
5. Change Name (second page) from "B" to "A". 

An error message appears in the wizard page title: "The servlet display name already exists. ". The correct message should be: "The filter name already exists. "
Comment 1 Kaloyan Raev CLA 2008-03-07 10:47:36 EST
Created attachment 91888 [details]
patch
Comment 2 Kaloyan Raev CLA 2008-03-10 04:20:28 EDT
dropped to HEAD
Comment 3 Carl Anderson CLA 2008-03-24 19:28:31 EDT
This change caused a break in an adopter product that uses ERR_FILTER_DISPLAY_NAME_EXIST - why was that changed to ERR_FILTER_EXIST?  (It looks like the problem was caused by the code using ERR_SERVLET_DISPLAY_NAME_EXIST when it should have used ERR_FILTER_DISPLAY_NAME_EXIST.)

Can we get this changed back?
Comment 4 Kaloyan Raev CLA 2008-03-25 09:34:28 EDT
Yes, I will change it back. I will do this in the change list that I am going to commit today for bug 205330. So, I close this bug again. 

Why I have changed the message key? Hmm... probably just a mistake from my side. I think I have added ERR_FILTER_NAME_EXISTS, but have deleted ERR_FILTER_DISPLAY_NAME_EXIST by accidence. May be I have hit Ctrl+D instead of Ctrl+S. 

However, I wonder why ERR_FILTER_DISPLAY_NAME_EXIST exists in WTP code at all? It is not used anywhere in WTP code - only in adopter's code. According to our new WTP API Policy (http://wiki.eclipse.org/WTP_API_Policy) the "use of messages, icons, logging or tracing methods from another plugin" is considered as "illegitimate internal usage". In future, if we would like to expose messages, icons, etc. for adopter we should provide API for this. 
Comment 5 kiril mitov CLA 2008-04-02 12:46:28 EDT
Verified with wtp-sdk-I-I20080331115711-20080331115711.

The shown description is:
" The filter name already exists."
Comment 6 Kaloyan Raev CLA 2008-05-12 09:38:15 EDT
Closing