This week's book giveaway is in the Clojure forum.
We're giving away four copies of Clojure in Action and have Amit Rathore and Francis Avila on-line!
See this thread for details.
Win a copy of Clojure in Action this week in the Clojure forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

Undeploy not working

 
Nirmala Rayudu
Greenhorn
Posts: 14
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hello,
I am using JavaMail APIs in my web-application and some of the functions offerred by the web-app involve sending emails using the JavaMail APIs.
When I undeploy the Web-App, the web-app directory Tomcat5.0.28\webapps directory in not deleted completely, the only file left behind is Tomcat5.0.28\webapps\<myapp>\WEB-INF\lib\mail.jar(mail.jar is the Library for JavaMail).

Does anyone know why this might be happening? I greatly appreciate any response.

thanks.
 
Ben Souther
Sheriff
Posts: 13411
Firefox Browser Redhat VI Editor
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Did you check the permissions on that file?
 
Nirmala Rayudu
Greenhorn
Posts: 14
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Ben,
The file has read-only permission in the web-application's lib directory when it is deployed, but so do all other library files I have in the lib directory, and all of them are deleted by Tomcat.

thanks
 
peter wooster
Ranch Hand
Posts: 1033
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Originally posted by Nimala Rayudu:
Ben,
The file has read-only permission in the web-application's lib directory when it is deployed, but so do all other library files I have in the lib directory, and all of them are deleted by Tomcat.

thanks


This is a known problem with Tomcat under WinWows, but not when running under Solaris or Linux. I've been fighting with it all day and have found some documentation in
the Tomcat Windows FAQ. The faq suggests using the antiJARLocking attribute in the context.xml file to prevent this. I haven't tried this yet, but conversations on the Sun forums indicate that it isn't fully fixed as of Tomcat-5.5.7.

I use WinXP as my development environment and Solaris as my run environment and have different Ant targets for producing the war files. For Windows I put most of the jars in commons/lib which may cause classloader problems if multiple apps use the jars, but I only run one app under windows. For Solaris I put the jars in WEB-INF/lib where they belong. I know its a nasty kludge, but it works.

One package that really doesn't belong in common/lib is Velocity, its jars MUST be in WEB-INF/lib since it uses the Singleton Pattern, luckily it doesn't have the locked jars problem. The Hibernate documentation warns against putting anything in common/lib.
 
I agree. Here's the link: http://aspose.com/file-tools
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic