tags:

views:

89

answers:

1

I get the following error when running mvn jetty:run-war:

2009-11-14 15:19:28.459:/:INFO:  Initializing Spring root WebApplicationContext
* ERROR 15:19:28,491 Context initialization failed (ContextLoader.java [main])
java.lang.NoSuchMethodError: org.springframework.util.ReflectionUtils.makeAccessible(Ljava/lang/reflect/Constructor;)V
...

(Not including the whole stacktrace)

I know that there is nothing wrong with the code as it works perfectly fine both in Windows and OSX. Right now Im using Ubuntu karmic koala and installed maven through apt-get, could there be something that I have forgotten to configure in linux to make it work? I dont get any errors when doing mvn clean install.

Anyone?

A: 

There must be a compatibility mismatch somewhere. Maybe your local repository contains a "stale" version of some jar. I'd suggest to retry with a fresh and clean local repository.

First, make a backup copy:

mv ~/.m2/repository ~/.m2/repository.save

Then, try again.

Pascal Thivent