[jbossseam-issues] [JBoss JIRA] Created: (JBSEAM-1327) hot deployment directory should not be tied to name and location of debug jar

Dan Allen (JIRA) jira-events at lists.jboss.org
Tue May 15 23:43:52 EDT 2007


hot deployment directory should not be tied to name and location of debug jar
-----------------------------------------------------------------------------

                 Key: JBSEAM-1327
                 URL: http://jira.jboss.com/jira/browse/JBSEAM-1327
             Project: JBoss Seam
          Issue Type: Feature Request
          Components: Core
    Affects Versions: 1.2.1.GA
         Environment: JDK 1.5, Ubuntu Linux 7.04, Jetty running under Maven 2
            Reporter: Dan Allen
            Priority: Critical
             Fix For: 1.3.0.BETA1


The logic for determining the location of the hot deployable directory for Java classes currently relies on the location and name of the jboss-seam-debug jar file.  While this may work when the jar file is placed in WEB-INF/lib, relative to the WEB-INF/dev directory, and named jboss-seam-debug.jar, it breaks down when it is loaded by the application server by a different means or has a different name.  

For instance, when running a Seam application using Jetty from within Maven 2, the location of the jar file is in the local repository.

What I find particularly scary is the hard-coded string offsets:

String hotDeployDirectory = path.substring( 9, path.length()-46 ) + "dev";

To get a better understanding of the problem, I added some logging messages to capture the path resolver logic when jetty builds its classpath from the maven repository.

META-INF/debug.xhtml detected at jar:file:/home/dallen/.m2/repository-public/jboss/seam/jboss-seam-debug/1.2.1.GA/jboss-seam-debug-1.2.1.GA.jar!/META-INF/debug.xhtml
Hot deploy directory is /home/dallen/.m2/repository-public/jboss/seam/jboss-seam-debug/1.2.1.GA/jbossdev

If I place the jboss-seam-debug-1.2.1.ga.jar file in the src/main/webapp/WEB-INF/lib directory, then things get a little bit better, but still not quite right.

META-INF/debug.xhtml detected at jar:file:/home/dallen/projects/connoisseur/src/main/webapp/WEB-INF/lib/jboss-seam-debug-1.2.1.GA.jar!/META-INF/debug.xhtml
Hot deploy directory is /home/dallen/projects/connoisseur/src/main/webapp/WEB-INF/lib/jbossdev

What I propose is for the WEB-INF/dev directory to be loaded using the servlet context.  That way, it will always be the directory that is most likely located in the project of the developer.  Since this feature is intended strictly for development, this seams to make the most sense. 

I will provided a patch for both Seam 1.2.1.ga and the trunk.

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://jira.jboss.com/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        



More information about the seam-issues mailing list