• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

Undeploy not working

 
Greenhorn
Posts: 14
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • 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.
 
Sheriff
Posts: 13411
Firefox Browser VI Editor Redhat
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Did you check the permissions on that file?
 
Nirmala Rayudu
Greenhorn
Posts: 14
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • 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
 
Ranch Hand
Posts: 1033
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • 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.
reply
    Bookmark Topic Watch Topic
  • New Topic