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 247223 - Custom Maven War WebResources vs Copy static resources on save
Summary: Custom Maven War WebResources vs Copy static resources on save
Status: RESOLVED INCOMPLETE
Alias: None
Product: javaee
Classification: Unclassified
Component: Maven (show other bugs)
Version: 8.0.1
Hardware: PC Linux
: P2 normal with 1 vote (vote)
Assignee: Petr Hejl
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2014-09-17 14:32 UTC by roti
Modified: 2017-08-03 09:03 UTC (History)
0 users

See Also:
Issue Type: DEFECT
Exception Reporter:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description roti 2014-09-17 14:32:40 UTC
Hello!

 After happily using 8.0.1 which has this fix: Bug 243313 "Custom Maven War WebResources / Project structure pane bug", I realized that although the pane bug fixed, the "Copy static resources on save" wont work.

When I remove the other custom web resource, the Copy static resources on save will work.
When I add a custom web resource folder again, the Copy static resources on save will not work.
Comment 1 bentrm 2014-09-24 14:39:15 UTC
I can confirm this. Working with the same project on two different machines I noticed the following as well, though it may be a coincidence:

It seems like the first web resources folder listed in the "Projects" panel as "Web Pages" is considered on save events. The order is different for me with the same project (OSX,Win; both 8.0.1) and coincides with which folders static resources are copied on save.
Comment 2 Petr Hejl 2015-04-20 10:30:38 UTC
Is the problem here that the first web resource is randomly changing (this should be fixed in bug #248687) or that copy on save does not work on additional web resources?
Comment 3 Petr Hejl 2015-04-22 09:18:27 UTC
Awaiting user feedback.
Comment 4 roti 2015-04-30 12:53:19 UTC
ok, I have tested it over again with 8.0.2 and 201504290001.
Both versions fixes my original report.
But as you wrote, "copy on save does not work on additional web resources" is still an issue.
Comment 5 slavb18 2017-08-03 09:03:26 UTC
Still not working
Copy static resources on save not working with additional resources in war
E.g. application serves resources from src/main/resources
            <plugin>
                <groupId>org.apache.maven.plugins</groupId>
                <artifactId>maven-war-plugin</artifactId>
                <version>2.1.1</version>
                <configuration>
                    <failOnMissingWebXml>false</failOnMissingWebXml>
                    <webResources>
                        <resource>
                            <!-- this is relative to the pom.xml directory -->
                            <directory>src/main/resources</directory>
                        </resource>
                    </webResources>
                </configuration>
            </plugin>

Then changes of file in src/main/resources not automatically deployed