Chris' Tech Blog

March 20, 2010

mvn eclipse: “Request to merge when ‘filtering’ is not identical.”

Filed under: Eclipse, Maven — Chris Ey @ 11:16 pm

When filtering properties is turned on with maven and I regenerated the eclipse project with maven (mvn eclipse:eclipse), I got this problem after updating to a current mvn release:

org.apache.maven.lifecycle.LifecycleExecutionException: Request to merge when 'filtering' is not identical. Original=source src/main/java: output=null, include=[**/*.java], exclude=[], test=false, filtering=false, merging with=resource src/main/java: output=target/classes, include=[**], exclude=[**/*.java|config.properties|**/*.java], test=false, filtering=true

Well, looks like I’m not the only one with this problem! The best thread & solutions I found here:

http://forums.atlassian.com/thread.jspa?threadID=34952&tstart=30

In short, you want to use version 2.6 of the eclipse plugin, and a quick way to do that is execute mvn eclipse this way:

mvn org.apache.maven.plugins:maven-eclipse-plugin:2.6:eclipse -DdownloadSources=true -DdownloadJavadocs=true

February 26, 2010

Get going with Jetty: Run in Eclipse, Change Port in Maven

Filed under: Eclipse, Jetty — Chris Ey @ 2:35 pm

Jetty is a GREAT servlet engine, which I mainly used for development. Yet, you can use it for production as well.

Developing with Jetty is very easy already, but if you need to get going NOW, this may help:

RunJettyRun

If you work with Eclipse, and want an integrated Jetty for development, all you need id this:

http://code.google.com/p/run-jetty-run/wiki/GettingStarted

Change Port when using maven

Jetty runs on port 8080 by default. How you change that port in RunJettyRun is pretty easy (just change the run config).

If you start Jetty using Maven on the command line with this command:

mvn jetty:run

you can change the port by specifying the runtime variable jetty.port. For example, if you want to use port 8900 instead, use the following command:

mvn -Djetty.port=8900 jetty:run

I know this is not rocket science, but this kind of information may help you to get going with Jetty even faster.

February 25, 2010

Eclipse hangs on startup – swiss knife solution

Filed under: Eclipse — Chris Ey @ 11:57 am

I just experienced what probably many devs experience with Eclipse occasionally: It hangs on startup.

Looks like there is a pretty easy solution to delete a .snap file which helped me too:

  1. cd to <workspace>/.metadata/.plugins/org.eclipse.core.resources
  2. remove the file .snap

Found here:
http://stackoverflow.com/questions/207843/how-do-i-prevent-eclipse-from-hanging-on-startup

I am reposting it so I can find it easier in future :)

Powered by WordPress