Tag Archives: eclipse

Eclipse Web Application and Maven Dependency Issues

When development web application in eclipse and use maven to manage dependency we usually face with some problem as missing library at runtime cause maven dependency issues. In this post i show you how to dianostic that issue.
Step 1. Enable/disable Maven feature
On Eclipse IDE, right click on the project, choose maven->Disable Maven Nature
After that right click on project choose Configure-> Convert to maven project

If you already do this step but no luck, move to step 2
Step 2. Clean and update project
Some time you get exception cause library download by maven get corrupt cause network issue. Check log on console tab carefully to find what library have issue and go to maven local repository to delete that library(you can also delete all). Normal maven local repository lay on %USERPROFILE%/.m2
Next, In Eclipse IDE right click choose maven->update project


If your project still not work when run, go to next step.

Step 3. Checking Deployment Assembly
Right click on project in Eclipse IDE, choose properties and choose Deployment Assembly. Please make sure your project have minimal as below if you don’t using any other library in WEB-INF/lib. If you using more you can manuall add to Deployment Assembly by click Add button.


Cannot change version of project facet Dynamic Web Module to x.x

1. Problem

When you create maven web project it default using version servlet 2.3. Now you want change servlet 2.5 or 3.0. You come and manual change on web.xml as below

<web-app xmlns="http://java.sun.com/xml/ns/javaee" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"

And now your project on eclipse alway has red mark and with problem show error:

Cannot change version of project facet Dynamic Web Module to 3.0.

2. Solution

Right click on project in eclipse project explorer, choose properties-> Project facets-> uncheck on Dynamic Web Module and click  Apply. Right click on project and choose maven-> update project the project will automatic update and resolve above issue.