Details

    • Type: New Feature New Feature
    • Status: Resolved
    • Priority: Minor Minor
    • Resolution: Fixed
    • Affects Version/s: Trunk
    • Fix Version/s: 3.0-M1
    • Component/s: Deployment Modules
    • Labels:
      None

      Description

      Allow james to automatically add jars from /conf/libs to classloader.
      This way, user mailets and their dependencies are taken into account without configuring the classpath.

      1. commons-dbcp.patch
        0.4 kB
        Eric Charles
      2. jamesclassloader.patch
        6 kB
        Eric Charles
      3. jamesclassloader-via-property.patch
        9 kB
        Eric Charles

        Activity

        Hide
        Eric Charles added a comment -

        Patch proposal is attached.

        Show
        Eric Charles added a comment - Patch proposal is attached.
        Hide
        Eric Charles added a comment -

        Forget the first one jamesclassloader.patch that only worked with classes loaded via spring.

        Attached a second patch jamesclassloader-via-property.patch.
        Now works for all classes via -Djava.system.class.loader=org.apache.james.container.spring.JamesClassLoader

        Tested on linux and windows (no mac available)
        Works via startup script and wrapper.

        Show
        Eric Charles added a comment - Forget the first one jamesclassloader.patch that only worked with classes loaded via spring. Attached a second patch jamesclassloader-via-property.patch. Now works for all classes via -Djava.system.class.loader=org.apache.james.container.spring.JamesClassLoader Tested on linux and windows (no mac available) Works via startup script and wrapper.
        Hide
        Norman Maurer added a comment -

        committed. Thx for the patch mate..

        Show
        Norman Maurer added a comment - committed. Thx for the patch mate..
        Hide
        Eric Charles added a comment -

        When setting classlader via java.system.class.loader property, we still have ClassNotFoundException for Class.forName(name).
        Class.forName(name, initialize, loader) should give no problem if providing the current classloader.

        commons-dbcp.patch sets commons-dbcp dependency to 1.4. (instead of 1.2.1)
        The 1.4 does not use Class.forName(name) to load the jdbc driver class.

        Show
        Eric Charles added a comment - When setting classlader via java.system.class.loader property, we still have ClassNotFoundException for Class.forName(name). Class.forName(name, initialize, loader) should give no problem if providing the current classloader. commons-dbcp.patch sets commons-dbcp dependency to 1.4. (instead of 1.2.1) The 1.4 does not use Class.forName(name) to load the jdbc driver class.

          People

          • Assignee:
            Norman Maurer
            Reporter:
            Eric Charles
          • Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Development