Details

    • Type: Improvement
    • Status: Closed
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 2.3.0
    • Component/s: None
    • Labels:
      None
    • Environment:
      Windows/FreeBSD, JDK 1.4.2

      Description

      The developers of James have done a wonderful job with the concept of James up to this point although have been a little slow in the development process.

      However, I could not wait for the fixes to come in and so decided to tackle a few of the more critical problems myself... in trying to fix the large number of bugs in James I've found, and trying to test the IMAP implementation, I checked out the HEAD revision and attempted to build. Once I'd solved the dependency mess, I found that the code was actually broken in relation to the com.apache.james.util.connection.* classes and their super classes.

      I also found very little or no unit tests, so I could not determine what part of the code exactly was broken (or what it should do).

      The code base is pretty much a mess as far as I can tell but I can suggest a few things that would help keep this project on track: Use Agile, TDD processes in your development. Use Maven for a build system.

      I am willing to port the project to a Maven build if requested to do so.
      I would also like to see some unit test for this code.

      Yes, this ticket is pretty harsh, but as experienced developers, I expect better.

        Activity

        Hide
        noel Noel J. Bergman added a comment -

        JIRA is not a conversation medium. It is for reporting and tracking specific issues.

        The build in MAIN should be working. I don't see a specific problem reported by you, although you seem to be alluding to something in the experimental IMAP code.

        Also, MAIN is not the current mainstream development branch. Almost all of the work for the past two years has gone into the v2 branch.

        Maven does not address any current problem, as far as I know.

        Show
        noel Noel J. Bergman added a comment - JIRA is not a conversation medium. It is for reporting and tracking specific issues. The build in MAIN should be working. I don't see a specific problem reported by you, although you seem to be alluding to something in the experimental IMAP code. Also, MAIN is not the current mainstream development branch. Almost all of the work for the past two years has gone into the v2 branch. Maven does not address any current problem, as far as I know.
        Hide
        brill Brill Pappin added a comment -

        I was not attempting to start conversation, but to indicate my disappointment in the state of the source tree, which is why this ticket was entered with a "type" of "Improvement". I would have posted to the mailing list, but my mail server runs on a dynamic IP specifically for the purpose of doing my own spam control, however your mailing lists do not allow posts from dynamic IP's.

        Though the broken code is not the first thing that prompted me to open this ticket, I will add to the ticket and document what I have found with regards to the broken build/code specifically. This will take me a short while as I've got to check out a new HEAD revision and clean my environment for it so I can run though it step by step.

        Show
        brill Brill Pappin added a comment - I was not attempting to start conversation, but to indicate my disappointment in the state of the source tree, which is why this ticket was entered with a "type" of "Improvement". I would have posted to the mailing list, but my mail server runs on a dynamic IP specifically for the purpose of doing my own spam control, however your mailing lists do not allow posts from dynamic IP's. Though the broken code is not the first thing that prompted me to open this ticket, I will add to the ticket and document what I have found with regards to the broken build/code specifically. This will take me a short while as I've got to check out a new HEAD revision and clean my environment for it so I can run though it step by step.
        Hide
        brill Brill Pappin added a comment -

        As promised:

        bash-2.05b# java -version
        java version "1.4.2-p6"
        Java(TM) 2 Runtime Environment, Standard Edition (build 1.4.2-p6-brill_26_oct_2004_22_58)
        Java HotSpot(TM) Client VM (build 1.4.2-p6-brill_26_oct_2004_22_58, mixed mode)

        -bash-2.05b$ env
        SHELL=/usr/local/bin/bash
        ANT_HOME=/usr/local/ant
        USER=brill
        MAVEN_HOME=/usr/local/maven
        PATH=/sbin:/bin:/usr/sbin:/usr/bin:/usr/local/sbin:/usr/local/bin:/usr/X11R6/bin:/home/brill/bin:/usr/local/java/bin:/usr/local/ant/bin:/usr/local/maven/bin
        PWD=/home/brill/workspace
        JAVA_HOME=/usr/local/java
        HOME=/home/brill

        • Notice not "CLASSPATH" elements in the env.
          bash-2.05b# java -version
          java version "1.4.2-p6"
          Java(TM) 2 Runtime Environment, Standard Edition (build 1.4.2-p6-brill_26_oct_2004_22_58)
          Java HotSpot(TM) Client VM (build 1.4.2-p6-brill_26_oct_2004_22_58, mixed mode)

        cvs -d :pserver:anoncvs@cvs.apache.org:/home/cvspublic login
        cvs -d :pserver:anoncvs@cvs.apache.org:/home/cvspublic co james-server
        cd james-server/
        ant

        • Fix build errors regarding mail api.
          • Add activation.jar to lib directory
          • Add mail-1.3.1.jar to lib directory
            ant
        • Note: [echo] JDBC v3 in classpath - making code JDBC 3.0 compliant
          > [...]
          > compile-main:
          > [...]
          > [javac] 24 errors
          > [javac] 9 warnings
        • Ok, so now we've got a failed build right off the batt. Let's investigate.
        • Looks like most of them are related to bouncycastle libs, so let's make sure we have them.
        • They exist in the lib dir, but are not included in the build? WTF? Let's look at the build.xml
        • They are not listed in include.properties with all the rest of the libs.
          • Add to include.properties
          • bcmail.jar=$ {lib.dir}/bcmail-jdk13-124.jar
            – bcprov.jar=${lib.dir}

            /bcprov-jdk13-124.jar

          • jce.jar=$ {lib.dir}

            /jce-jdk13-124.jar

        • Add to build.xml
          • <pathelement location="$ {bcmail.jar}

            "/>

          • <pathelement location="$ {bcprov.jar}

            "/>

          • <pathelement location="$ {jce.jar}

            "/>

        ant
        > [...]
        > [javac] 2 errors
        > [javac] 9 warnings

        • Ok, ignore the warnings, lets check the errors
          • [javac] /usr/home/brill/workspace/james-server/src/java/org/apache/james/core/AbstractJamesService.java:429: cannot resolve symbol
          • [javac] symbol : method connect (java.lang.String,java.net.ServerSocket,org.apache.james.core.AbstractJamesService,org.apache.excalibur.thread.ThreadPool)
          • [javac] location: interface org.apache.james.services.JamesConnectionManager
          • [javac] connectionManager.connect(
          • [javac] /usr/home/brill/workspace/james-server/src/java/org/apache/james/util/connection/SimpleConnectionManager.java:40: org.apache.james.util.connection.SimpleConnectionManager is not abstract and does not override abstract method connect(java.lang.String,java.net.ServerSocket,org.apache.avalon.cornerstone.services.connection.ConnectionHandlerFactory,org.apache.avalon.excalibur.thread.ThreadPool) in org.apache.avalon.cornerstone.services.connection.ConnectionManager
          • [javac] public class SimpleConnectionManager
        • Ok, those two look related, the source is broken, lets check the source.
          • Hmm... problem originates in org.apache.james.services.JamesConnectionManager which doesn't include the named method.
          • it looks like the second error would be fixed by fixing the first. Someone refactored and committed to HEAD without running the tests...
          • Ok, lets fix this. The test will show us what should happen for this code.
            • Oh, oh... no test for org.apache.james.util.connection.SimpleConnectionManager!
        • Now there are several choices, among the most likely; attempt to add the missing method blindly with no idea if your going to break this runtime code.
        • Add a ticket for the project expressing your disappointment regarding the state of the source tree in the hopes that someone will take it as an opportunity for improving things.
        Show
        brill Brill Pappin added a comment - As promised: bash-2.05b# java -version java version "1.4.2-p6" Java(TM) 2 Runtime Environment, Standard Edition (build 1.4.2-p6-brill_26_oct_2004_22_58) Java HotSpot(TM) Client VM (build 1.4.2-p6-brill_26_oct_2004_22_58, mixed mode) -bash-2.05b$ env SHELL=/usr/local/bin/bash ANT_HOME=/usr/local/ant USER=brill MAVEN_HOME=/usr/local/maven PATH=/sbin:/bin:/usr/sbin:/usr/bin:/usr/local/sbin:/usr/local/bin:/usr/X11R6/bin:/home/brill/bin:/usr/local/java/bin:/usr/local/ant/bin:/usr/local/maven/bin PWD=/home/brill/workspace JAVA_HOME=/usr/local/java HOME=/home/brill Notice not "CLASSPATH" elements in the env. bash-2.05b# java -version java version "1.4.2-p6" Java(TM) 2 Runtime Environment, Standard Edition (build 1.4.2-p6-brill_26_oct_2004_22_58) Java HotSpot(TM) Client VM (build 1.4.2-p6-brill_26_oct_2004_22_58, mixed mode) cvs -d :pserver:anoncvs@cvs.apache.org:/home/cvspublic login cvs -d :pserver:anoncvs@cvs.apache.org:/home/cvspublic co james-server cd james-server/ ant Fix build errors regarding mail api. Add activation.jar to lib directory Add mail-1.3.1.jar to lib directory ant Note: [echo] JDBC v3 in classpath - making code JDBC 3.0 compliant > [...] > compile-main: > [...] > [javac] 24 errors > [javac] 9 warnings Ok, so now we've got a failed build right off the batt. Let's investigate. Looks like most of them are related to bouncycastle libs, so let's make sure we have them. They exist in the lib dir, but are not included in the build? WTF? Let's look at the build.xml They are not listed in include.properties with all the rest of the libs. Add to include.properties bcmail.jar=$ {lib.dir}/bcmail-jdk13-124.jar – bcprov.jar=${lib.dir} /bcprov-jdk13-124.jar jce.jar=$ {lib.dir} /jce-jdk13-124.jar Add to build.xml <pathelement location="$ {bcmail.jar} "/> <pathelement location="$ {bcprov.jar} "/> <pathelement location="$ {jce.jar} "/> ant > [...] > [javac] 2 errors > [javac] 9 warnings Ok, ignore the warnings, lets check the errors [javac] /usr/home/brill/workspace/james-server/src/java/org/apache/james/core/AbstractJamesService.java:429: cannot resolve symbol [javac] symbol : method connect (java.lang.String,java.net.ServerSocket,org.apache.james.core.AbstractJamesService,org.apache.excalibur.thread.ThreadPool) [javac] location: interface org.apache.james.services.JamesConnectionManager [javac] connectionManager.connect( – [javac] /usr/home/brill/workspace/james-server/src/java/org/apache/james/util/connection/SimpleConnectionManager.java:40: org.apache.james.util.connection.SimpleConnectionManager is not abstract and does not override abstract method connect(java.lang.String,java.net.ServerSocket,org.apache.avalon.cornerstone.services.connection.ConnectionHandlerFactory,org.apache.avalon.excalibur.thread.ThreadPool) in org.apache.avalon.cornerstone.services.connection.ConnectionManager [javac] public class SimpleConnectionManager Ok, those two look related, the source is broken, lets check the source. Hmm... problem originates in org.apache.james.services.JamesConnectionManager which doesn't include the named method. it looks like the second error would be fixed by fixing the first. Someone refactored and committed to HEAD without running the tests... Ok, lets fix this. The test will show us what should happen for this code. Oh, oh... no test for org.apache.james.util.connection.SimpleConnectionManager! Now there are several choices, among the most likely; attempt to add the missing method blindly with no idea if your going to break this runtime code. Add a ticket for the project expressing your disappointment regarding the state of the source tree in the hopes that someone will take it as an opportunity for improving things.
        Hide
        brill Brill Pappin added a comment -

        By the way: The Apache CVS repository does not list a "v2 branch" at all, not a branch or a tagged revision.

        If there is another branch somewhere, please let me know where it is, and close this ticket, as it no longer applies.

        Show
        brill Brill Pappin added a comment - By the way: The Apache CVS repository does not list a "v2 branch" at all, not a branch or a tagged revision. If there is another branch somewhere, please let me know where it is, and close this ticket, as it no longer applies.
        Hide
        bago Stefano Bagnara added a comment -

        We cannot change to tdd and add tests in one day.
        BTW I support the need for junit tests.

        Show
        bago Stefano Bagnara added a comment - We cannot change to tdd and add tests in one day. BTW I support the need for junit tests.
        Hide
        danny@apache.org Danny Angus added a comment -

        Closing issue fixed in released version.

        Show
        danny@apache.org Danny Angus added a comment - Closing issue fixed in released version.

          People

          • Assignee:
            Unassigned
            Reporter:
            brill Brill Pappin
          • Votes:
            1 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Development