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 242040 - [Package Rename] Should not reformat web.xml
Summary: [Package Rename] Should not reformat web.xml
Status: RESOLVED WONTFIX
Alias: None
Product: javaee
Classification: Unclassified
Component: Refactoring (show other bugs)
Version: 8.0
Hardware: PC Windows 7
: P3 normal (vote)
Assignee: issues@javaee
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2014-02-18 09:27 UTC by ssazonov
Modified: 2016-07-07 08:53 UTC (History)
0 users

See Also:
Issue Type: DEFECT
Exception Reporter:


Attachments
project (6.98 KB, image/png)
2014-02-18 09:27 UTC, ssazonov
Details

Note You need to log in before you can comment on or make changes to this bug.
Description ssazonov 2014-02-18 09:27:36 UTC
Created attachment 145341 [details]
project

1. Create new Maven Web Application

2. Add web.xml file:

<?xml version="1.0" encoding="UTF-8"?>
<web-app xmlns="http://xmlns.jcp.org/xml/ns/javaee"
         xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
         xsi:schemaLocation="http://xmlns.jcp.org/xml/ns/javaee
            http://xmlns.jcp.org/xml/ns/javaee/web-app_3_1.xsd"
         version="3.1">
    
    <servlet>
        <servlet-name>SimpleServlet</servlet-name>
        <servlet-class>test.Test</servlet-class>
    </servlet>
</web-app>


3. Add any servlet "test.Test" (so the structure of project now looks like on attached image)

4. Right click the package "test" and from pop-up menu select Refactor > Rename..., type new name and press Refactor

>> web.xml has been completely reformated although only line "<servlet-class>test.Test</servlet-class>" should be modified

Product Version: NetBeans IDE Dev (Build 201402180001)
Java: 1.8.0; Java HotSpot(TM) 64-Bit Server VM 25.0-b67
Runtime: Java(TM) SE Runtime Environment 1.8.0-b126
System: Windows 7 version 6.1 running on amd64; Cp1252; en_US (nb)
Comment 1 Martin Balin 2016-07-07 08:53:41 UTC
This old bug may not be relevant anymore. If you can still reproduce it in 8.2 development builds please reopen this issue.

Thanks for your cooperation,
NetBeans IDE 8.2 Release Boss