This week's book giveaways are in the Refactoring and Agile forums.
We're giving away four copies each of Re-engineering Legacy Software and Docker in Action and have the authors on-line!
See this thread and this one for details.
Win a copy of Re-engineering Legacy Software this week in the Refactoring forum
or Docker in Action in the Cloud/Virtualization forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

WSAD 4.0 project can not see jar file!

 
Ashok Mudgapalli
Greenhorn
Posts: 13
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I have created a web project in WSAD 4.0 and set it's build path with several needed jar files. When try to run a jsp using WTE server, I am getting an error "ClassNotFoundException". For example, my jsp is referencing Category class of Log4J.jar, the console gives me Category class not found exception. I have checked the jar for Category class and it exists in that jar. This jar is in build path of the project. I do not know why my project is not able to access jar(s) placed in project's build path. I would appreciate your help.
Thanks
 
David O'Meara
Rancher
Posts: 13459
Android Eclipse IDE Ubuntu
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
The build path allows you to build the application, but is not the runtime dependency.
You need to right click the web app, select edit jar dependencies, then select the jar you want. I think you need to do this on the package view. (This may not be the exact instructions since I'm on WSAD 5 now and it has changed slightly)
Dave
 
Nagendra Prasad
Ranch Hand
Posts: 219
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Following on David's mail..
If u are using WSAD 4,
- Go to team perspective
- Right click on the project
- Select 'Edit Module Dependencies'
- select the jar that you want to reference.
That should sort it out
 
Ashok Mudgapalli
Greenhorn
Posts: 13
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thanks for your input. I ended up adding the jar file in WEB-INF/lib directory and every thing works fine now.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic