3

I have installed the Google-Eclipse plugin to create a GWT/GAE app. I added the joda-time-2.1.jar for handling dates and times on the server-side. I did this by adding the JAR to a lib/ directory in my project, and then adding the JAR to the project buildpath.

As soon as I did this I see a Warning spring up inside the Eclipse Problems view:

The following classpath entry '/home/myuser/workbench/eclipse/workspace/myapp/lib/joda-time-2.1.jar' will not be available on the server's classpath.

I haven't gotten this far yet but was planning on packaging this JAR under the WEB-INF/lib directory inside the app WAR, which should make it available to the server classpath.

Have I configured something incorrectly here? If so, what? And if not, how do I silence/get rid of this warning? Thanks in advance!

1 Answers1

5

Have I configured something incorrectly here?

No.

If so, what? And if not, how do I silence/get rid of this warning?

Move the JAR to WEB-INF/lib.

Thomas Broyer
  • 64,353
  • 7
  • 91
  • 164
  • Thanks @Thomas Broyer (+1) - so do I need to manually ad JARs to my project buildpath **AND** place them in `WEB-INF/lib`, or just place them in `WEB-INF/lib`? –  Nov 23 '12 at 19:49
  • 3
    And what about test dependencies?!? I shouldn't have to place `junit` into the `WEB-INF/lib` directory in order to *not* have a compiler warning... –  Nov 23 '12 at 21:06