Uploaded image for project: 'Struts 1'
  1. Struts 1
  2. STR-2610

ActionServlet locks jars in web-inf/lib after reading config files

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Critical
    • Resolution: Fixed
    • 1.3.0
    • 1.3.0
    • Core
    • None
    • Operating System: All
      Platform: Other
    • 37041

    Description

      Using Tomcat Manager we have fallen in a known problem:

      http://jakarta.apache.org/tomcat/faq/windows.html#lock
      http://issues.apache.org/bugzilla/show_bug.cgi?id=29526
      http://www.mail-archive.com/ojb-dev@db.apache.org/msg00474.html

      The solution is to use URLConnection instead of URL to read the inputStream and
      set to false the UseCache boolean.

      Here is the patch for method parseModuleConfigFile(Digester digester, URL url)

      26a27
      > import java.net.URLConnection;
      741c742,745
      < input = url.openStream();

      > URLConnection conn = url.openConnection();
      > conn.setUseCaches(false);
      > conn.connect();
      > input = conn.getInputStream();

      Thanks for a quick submit,
      Filippo

      Attachments

        Activity

          People

            Unassigned Unassigned
            fmunafo Filippo Munafò
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: