vendredi 25 décembre 2015

Web project doesn't apply the changes

I'm developing a web project in Eclipse. But every time I apply a change an error appears so the changes aren't applied. If I delete the "target" folder and go to project -> Clean, the changes are applied, but as soon I perform any changes again I receive the same error.

The error is on pom.xml as follows:

C:\Users\Tiago\Desktop\B2BWeb\target\classes\main\resources\web\html\partials\manageProducts.html (The requested operation cannot be performed on a file with a user-mapped section open) (org.apache.maven.plugins:maven-resources-plugin:2.6:resources:default-resources:process-resources)

org.apache.maven.plugin.MojoExecutionException: C:\Users\Tiago\Desktop\B2BWeb\target\classes\main\resources\web\html\partials\manageProducts.html (The requested operation cannot be performed on a file with a user-mapped section open)
    at org.apache.maven.plugin.resources.ResourcesMojo.execute(ResourcesMojo.java:307)
    at org.apache.maven.plugin.DefaultBuildPluginManager.executeMojo(DefaultBuildPluginManager.java:134)
    at org.eclipse.m2e.core.internal.embedder.MavenImpl.execute(MavenImpl.java:331)
    at org.eclipse.m2e.core.internal.embedder.MavenImpl$11.call(MavenImpl.java:1362)
    at org.eclipse.m2e.core.internal.embedder.MavenImpl$11.call(MavenImpl.java:1)
    at org.eclipse.m2e.core.internal.embedder.MavenExecutionContext.executeBare(MavenExecutionContext.java:176)
    at org.eclipse.m2e.core.internal.embedder.MavenExecutionContext.execute(MavenExecutionContext.java:112)
    at org.eclipse.m2e.core.internal.embedder.MavenImpl.execute(MavenImpl.java:1360)
    at org.eclipse.m2e.core.project.configurator.MojoExecutionBuildParticipant.build(MojoExecutionBuildParticipant.java:52)
    at org.eclipse.m2e.core.internal.builder.MavenBuilderImpl.build(MavenBuilderImpl.java:137)
    at org.eclipse.m2e.core.internal.builder.MavenBuilder$1.method(MavenBuilder.java:172)
    at org.eclipse.m2e.core.internal.builder.MavenBuilder$1.method(MavenBuilder.java:1)
    at org.eclipse.m2e.core.internal.builder.MavenBuilder$BuildMethod$1$1.call(MavenBuilder.java:115)
    at org.eclipse.m2e.core.internal.embedder.MavenExecutionContext.executeBare(MavenExecutionContext.java:176)
    at org.eclipse.m2e.core.internal.embedder.MavenExecutionContext.execute(MavenExecutionContext.java:112)
    at org.eclipse.m2e.core.internal.builder.MavenBuilder$BuildMethod$1.call(MavenBuilder.java:105)
    at org.eclipse.m2e.core.internal.embedder.MavenExecutionContext.executeBare(MavenExecutionContext.java:176)
    at org.eclipse.m2e.core.internal.embedder.MavenExecutionContext.execute(MavenExecutionContext.java:151)
    at org.eclipse.m2e.core.internal.embedder.MavenExecutionContext.execute(MavenExecutionContext.java:99)
    at org.eclipse.m2e.core.internal.builder.MavenBuilder$BuildMethod.execute(MavenBuilder.java:86)
    at org.eclipse.m2e.core.internal.builder.MavenBuilder.build(MavenBuilder.java:200)
    at org.eclipse.core.internal.events.BuildManager$2.run(BuildManager.java:734)
    at org.eclipse.core.runtime.SafeRunner.run(SafeRunner.java:42)
    at org.eclipse.core.internal.events.BuildManager.basicBuild(BuildManager.java:205)
    at org.eclipse.core.internal.events.BuildManager.basicBuild(BuildManager.java:245)
    at org.eclipse.core.internal.events.BuildManager$1.run(BuildManager.java:300)
    at org.eclipse.core.runtime.SafeRunner.run(SafeRunner.java:42)
    at org.eclipse.core.internal.events.BuildManager.basicBuild(BuildManager.java:303)
    at org.eclipse.core.internal.events.BuildManager.basicBuildLoop(BuildManager.java:359)
    at org.eclipse.core.internal.events.BuildManager.build(BuildManager.java:382)
    at org.eclipse.core.internal.resources.Workspace.buildInternal(Workspace.java:486)
    at org.eclipse.core.internal.resources.Workspace.build(Workspace.java:398)
    at org.eclipse.ui.actions.GlobalBuildAction$1.run(GlobalBuildAction.java:182)
    at org.eclipse.core.internal.jobs.Worker.run(Worker.java:55)
Caused by: org.apache.maven.shared.filtering.MavenFilteringException: C:\Users\Tiago\Desktop\B2BWeb\target\classes\main\resources\web\html\partials\manageProducts.html (The requested operation cannot be performed on a file with a user-mapped section open)
    at org.apache.maven.shared.filtering.DefaultMavenFileFilter.copyFile(DefaultMavenFileFilter.java:129)
    at org.apache.maven.shared.filtering.DefaultMavenResourcesFiltering.filterResources(DefaultMavenResourcesFiltering.java:261)
    at org.apache.maven.plugin.resources.ResourcesMojo.execute(ResourcesMojo.java:301)
    ... 33 more
Caused by: java.io.FileNotFoundException: C:\Users\Tiago\Desktop\B2BWeb\target\classes\main\resources\web\html\partials\manageProducts.html (The requested operation cannot be performed on a file with a user-mapped section open)
    at java.io.FileOutputStream.open0(Native Method)
    at java.io.FileOutputStream.open(Unknown Source)
    at java.io.FileOutputStream.<init>(Unknown Source)
    at java.io.FileOutputStream.<init>(Unknown Source)
    at org.codehaus.plexus.util.FileUtils.copyStreamToFile(FileUtils.java:1107)
    at org.codehaus.plexus.util.FileUtils.copyFile(FileUtils.java:1013)
    at org.codehaus.plexus.util.FileUtils.copyFile(FileUtils.java:2234)
    at org.apache.maven.shared.filtering.DefaultMavenFileFilter.copyFile(DefaultMavenFileFilter.java:122)
    ... 35 more




Aucun commentaire:

Enregistrer un commentaire