This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.
Bug exists in FFJ CE Build 020207. When one renames package, containing servlets, IDE proposes to make appropriate changes in the servlets code, but it doesn't propose to make any changes in the web.xml file. However when one renames servlet file, IDE changes web.xml file correctly. How to reproduce: 1. Mount some web module 2. Create new servlet in WEB-INF/Classes in some packages, e.g. servlets.Servlet 3. Try to rename servlets package in IDE - Information dialog appears, proposing to change Java code of the classes in the package. However no changes in web.xml are propsed. 4. Try to rename Servlet class - IDE makes correct changes in the web.xml file
commited to trunk (requires IDE spec version newer than 1.28) http://web.netbeans.org/source/browse/web/advanced/src/org/netbeans/modules/web/ie/servlets/ServletIEDataObject.java.diff?r1=1.20&r2=1.21
Changing target milestone to FFJ 4.0
Attempted to verify this in FFJ 4.0 Build 020423_ee. However, the servlet code was changed and no changes were propogated to the web.xml file.
This one is fixed in NB trunk code base.I'm not going to fix it in orion.
Verified in NB 3.4 dev build 200206070835.
Still reproduced in Sierra (S1S 4.1 20812 build)
I tried it on the Netbeans 3.4 and the behavior is confusing. If you rename a package which contains servlets, than Confirm Changes dialog has text "Changes recommended in deployment descriptor of ..." and contains all servlets which are in or under renaming package. But some servlets doesn't have to have servlet elements in the deployment descriptor. There are three confusing things: 1) In the Confirm Changes dialog are servlet-class, which doesn't have servlet element in the deployment descriptor. 2) Servlet-class is updated correctly, but the servlet-mapping is not. So the result after the renaming is for example: <servlet> <servlet-name>test</servlet-name> <servlet-class>org10.test</servlet-class> </servlet> <servlet-mapping> <servlet-name>test</servlet-name> <url-pattern>/servlet/org.test</url-pattern> </servlet-mapping> I suspect that the url-pattern will be /servlet/org10.test 3) When the user press button "Close" in the Confirm Changes dialog and then try rename the package again, then this dialog shows all servlet under renaming package, but there isn't any servlet, which can be changed. It is connected with the 1.
1) and 3) is odd. ad 2) - there can be any string that may or may not have relationship to servlet class name. I am not sure if it would be transparent if the IDE changed the mapping path. Also there are consequences like URI mapping of servlet DO and so on.
Created attachment 8041 [details] There is easy fix for 1 and 3.
Fixed and integrated in the sierra fixies
Denis, please test in on Nevada and current trunk
not reproduced in Nevada and current trunk
Can not reproduce on current trunk