I can't seem to find apache common logging when using eclipse w/maven2 plugin.
I need it for spring3 mvc apparently.
Eclipse -> Preferences: Java - Build path - User Libraries push the "New..." button, and in the "User library name:" enter 'appache-commons-lang'. Click to select "appache-commons-lang" in the "Defined user libraries" list and then click on the "Add JARs..." button and browse for commons-lang-2.5.
Via the Maven index, you can search for dependencies, select them and add them to your pom file. To download the index, select Windows > Preferences > Maven and enable the Download repository index updates on startup option. After changing this setting, restart Eclipse. This triggers the download of the Maven index.
Using Maven with the Eclipse IDEThe Eclipse IDE provides support for the Maven build. This support is developed in the M2Eclipse project. It provides an editor for modifying the pom file and downloads dependencies if required. It also manages the classpath of the projects in the IDE.
We need to have the commons-logging. properties in our src folder. The above property tells the Commons Library as to which Logger Class, the application intends to use. Then, we need to set up the corresponding library, Log4J in this case.
Do you know that the m2eclipse plugin can search some indexed repositories, like central? For example, if you right-click on your project and go to Maven > Add Dependency, you can use it like this:
And this will add this to your pom:
<dependency>
<groupId>commons-logging</groupId>
<artifactId>commons-logging</artifactId>
<version>1.1.1</version>
</dependency>
Another option is to use one of the numerous repository search engine, for example:
http://search.maven.org/#artifactdetails|commons-logging|commons-logging|1.1.1|jar
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With