Update dependency in pom.xml, new JAR appears in External Libraries, but no longer included in WEB-INF/lib

Why does this work:

<dependency>
    <groupId>org.primefaces</groupId>
    <artifactId>primefaces</artifactId>
    <version>5.0</version>
</dependency>


but this does not:

<dependency>
    <groupId>org.primefaces</groupId>
    <artifactId>primefaces</artifactId>
    <version>5.1</version>
</dependency>

and this does not either:

<dependency>
    <groupId>org.primefaces</groupId>
    <artifactId>primefaces</artifactId>
    <version>5.2</version>
</dependency>

All I did was update the version number.  I can see the new JAR in External Libraries e.g.

Maven: org.primfaces:primfaces:5.2
|
|---primfaces-5.2.jar


However, Intellij does not copy the new JAR into WEB-INF/lib when I deploy.  All I did was change one thing: the version number.  Same problem happens when I upgrade Primefaces Extensions and atmosphere dependencies in the same POM -- the new JAR files do not appear in WEB-INF/lib.
7 comments
Comment actions Permalink

Try to reimport Maven project in the Maven Projects tool window.

0
Comment actions Permalink

Clicking on the refresh button "Reimport All Maven Projects" does not fix the problem.

0
Comment actions Permalink

Please check the artifact: http://www.jetbrains.com/idea/webhelp/configuring-artifacts.html .

Was it generated from Maven or created manually? If the latter, you have to update it with the new jar version.

0
Comment actions Permalink

It looks wrong.  Primefaces 5.0, Primefaces Extensions 2.1.0 and Atmosphere 2.1.4 libraries are all highlighted in red and the new libraries are listed as available elements.  Why is this so?  AFAIR I've always simply changed version numbers for dependencies and IDEA automatically updated the artifacts.  In my past experience with IDEA it always has used pom.xml to update the project structure.

0
Comment actions Permalink

It was generated from Maven, not manually.


0
Comment actions Permalink

Same problem in intellij 2016 on Fedora. Any solution except update manually?

0

Please sign in to leave a comment.