1 2 Previous Next 15 Replies Latest reply on Dec 18, 2007 10:52 AM by Vikram Chhetry

    HTTP Status 404 - /registration/

    Vikram Chhetry Newbie

      Hi All,
      I tried installing seam on jboss but when i try to access registration example it says HTTP Status 404 - /registration/

      wild guesses:-
      http://localhost:8080/seam-registration/
      http://localhost:8080/jboss-seam-registration/

      as suggested i made two changes in build.xml which looks like

      <property name="deploy.dir" value="/opt/jboss-4.2.2.GA/server/default/deploy" />
       <property name="webroot.dir" value="${deploy.dir}/jboss-web.deployer/ROOT.war" />


      ant deploy says BUILD SUCCESSFUL

      I am using jboss4.2.0, seam2.0, suse linux 10.0, java 1.5

      Any help would be appreciated.

      -Vikram

        • 1. Re: HTTP Status 404 - /registration/
          Jay Balunas Master

          Could you include the output of the build?

          At the end of the build it should show a location for where it deployed the app to. Also if it deployed it to the write location, then did JBoss have any exceptions when deploying it?

          -Jay

          • 2. Re: HTTP Status 404 - /registration/
            Vikram Chhetry Newbie

            Hi jbalubas,
            could you please tell me the directory location where the application is deployed?
            this is the output when i type ant deploy:

            Buildfile: build.xml
            Overriding previous definition of reference to emma.classpath
            
            initcopy:
            
            initpoms:
             [echo] Setting up dependencies
             [copy] Copying 1 file to /home/vikramc/.eclipse/seam/classes/poms
            [artifact:install] [INFO] Installing /home/vikramc/.eclipse/seam/classes/poms/root.pom to /root/.m2/repository/org/jboss/seam/root/2.0.1.CR1/root-2.0.1.CR1.pom
             [copy] Copying 1 file to /home/vikramc/.eclipse/seam/classes/poms
            [artifact:install] [INFO] Installing /home/vikramc/.eclipse/seam/classes/poms/parent.pom to /root/.m2/repository/org/jboss/seam/parent/2.0.1.CR1/parent-2.0.1.CR1.pom
             [copy] Copying 1 file to /home/vikramc/.eclipse/seam/classes/poms
             [copy] Copying 1 file to /home/vikramc/.eclipse/seam/classes/poms
             [copy] Copying 1 file to /home/vikramc/.eclipse/seam/classes/poms
             [copy] Copying 1 file to /home/vikramc/.eclipse/seam/classes/poms
             [copy] Copying 1 file to /home/vikramc/.eclipse/seam/classes/poms
             [copy] Copying 1 file to /home/vikramc/.eclipse/seam/classes/poms
             [copy] Copying 1 file to /home/vikramc/.eclipse/seam/classes/poms
             [copy] Copying 1 file to /home/vikramc/.eclipse/seam/classes/poms
            
            copyseam:
            
            copyseamdependencies:
            
            copyextradependencies:
            
            init:
             [echo] Building Seam Registration Example 2.0
            
            select-compiler:
            
            compile:
             [echo] lib is /home/vikramc/.eclipse/seam/lib
            
            jar:
            
            init.war:
            
            war:
            
            jboss.war:
            
            ear:
            
            archive:
            
            datasource:
            
            meldware:
            
            deploy:
            
            BUILD SUCCESSFUL
            


            Thanks for your response

            • 3. Re: HTTP Status 404 - /registration/
              Jay Balunas Master

              Could you run

              ant clean deploy


              The build script output that sent really did not do anything because the build artifacts were up to date.

              Thanks,
              Jay

              • 4. Re: HTTP Status 404 - /registration/
                Vikram Chhetry Newbie

                ant clean deploy

                Buildfile: build.xml
                Overriding previous definition of reference to emma.classpath
                
                clean:
                 [delete] Deleting directory /home/vikramc/.eclipse/seam/examples/registration/dist
                 [delete] Deleting directory /home/vikramc/.eclipse/seam/examples/registration/exploded-archives
                
                initcopy:
                
                initpoms:
                 [echo] Setting up dependencies
                 [copy] Copying 1 file to /home/vikramc/.eclipse/seam/classes/poms
                [artifact:install] [INFO] Installing /home/vikramc/.eclipse/seam/classes/poms/root.pom to /root/.m2/repository/org/jboss/seam/root/2.0.1.CR1/root-2.0.1.CR1.pom
                 [copy] Copying 1 file to /home/vikramc/.eclipse/seam/classes/poms
                [artifact:install] [INFO] Installing /home/vikramc/.eclipse/seam/classes/poms/parent.pom to /root/.m2/repository/org/jboss/seam/parent/2.0.1.CR1/parent-2.0.1.CR1.pom
                 [copy] Copying 1 file to /home/vikramc/.eclipse/seam/classes/poms
                 [copy] Copying 1 file to /home/vikramc/.eclipse/seam/classes/poms
                 [copy] Copying 1 file to /home/vikramc/.eclipse/seam/classes/poms
                 [copy] Copying 1 file to /home/vikramc/.eclipse/seam/classes/poms
                 [copy] Copying 1 file to /home/vikramc/.eclipse/seam/classes/poms
                 [copy] Copying 1 file to /home/vikramc/.eclipse/seam/classes/poms
                 [copy] Copying 1 file to /home/vikramc/.eclipse/seam/classes/poms
                 [copy] Copying 1 file to /home/vikramc/.eclipse/seam/classes/poms
                
                copyseam:
                
                copyseamdependencies:
                
                copyextradependencies:
                
                init:
                 [echo] Building Seam Registration Example 2.0
                 [mkdir] Created dir: /home/vikramc/.eclipse/seam/examples/registration/exploded-archives/jboss-seam-registration.jar
                 [mkdir] Created dir: /home/vikramc/.eclipse/seam/examples/registration/exploded-archives/jboss-seam-registration.ear
                 [mkdir] Created dir: /home/vikramc/.eclipse/seam/examples/registration/exploded-archives/jboss-seam-registration.war
                 [mkdir] Created dir: /home/vikramc/.eclipse/seam/examples/registration/dist
                
                select-compiler:
                
                compile:
                 [echo] lib is /home/vikramc/.eclipse/seam/lib
                 [javac] Compiling 4 source files to /home/vikramc/.eclipse/seam/examples/registration/exploded-archives/jboss-seam-registration.jar
                
                jar:
                 [copy] Copying 3 files to /home/vikramc/.eclipse/seam/examples/registration/exploded-archives/jboss-seam-registration.jar
                
                init.war:
                
                war:
                 [copy] Copying 3 files to /home/vikramc/.eclipse/seam/examples/registration/exploded-archives/jboss-seam-registration.war
                 [copy] Copying 3 files to /home/vikramc/.eclipse/seam/examples/registration/exploded-archives/jboss-seam-registration.war/WEB-INF/lib
                
                jboss.war:
                 [copy] Copying 3 files to /home/vikramc/.eclipse/seam/examples/registration/exploded-archives/jboss-seam-registration.war
                
                ear:
                 [copy] Copying 3 files to /home/vikramc/.eclipse/seam/examples/registration/exploded-archives/jboss-seam-registration.ear
                 [mkdir] Created dir: /home/vikramc/.eclipse/seam/examples/registration/exploded-archives/jboss-seam-registration.ear/lib
                 [copy] Copying 1 file to /home/vikramc/.eclipse/seam/examples/registration/exploded-archives/jboss-seam-registration.ear/lib
                
                archive:
                 [jar] Building jar: /home/vikramc/.eclipse/seam/examples/registration/dist/jboss-seam-registration.jar
                 [jar] Building jar: /home/vikramc/.eclipse/seam/examples/registration/dist/jboss-seam-registration.war
                 [jar] Building jar: /home/vikramc/.eclipse/seam/examples/registration/dist/jboss-seam-registration.ear
                
                datasource:
                
                meldware:
                
                deploy:
                 [copy] Copying 1 file to /Applications/jboss-4.2.2.GA/server/default/deploy
                
                BUILD SUCCESSFUL
                


                • 5. Re: HTTP Status 404 - /registration/
                  Vikram Chhetry Newbie

                  I made some changes in build.xml
                  am i doing the right thing

                  <property name="jboss.home" value="/opt/jboss-4.2.2.GA" />
                  <property name="deploy.dir" value="${jboss.home}/server/default/deploy" />
                  <!--<property name="webroot.dir" value="${deploy.dir}/jbossweb-tomcat55.sar/ROOT.war" /> -->
                  <property name="webroot.dir" value="${deploy.dir}/jboss-web.deployer/ROOT.war" />


                  • 6. Re: HTTP Status 404 - /registration/
                    Jay Balunas Master

                    From the build output the app was deployed to the:

                    deploy:
                    [copy] Copying 1 file to /Applications/jboss-4.2.2.GA/server/default/deploy


                    From the properties that you listed it does not look like that is the correct location. I would check that the path is correct. Plus you can manually copy the file to the correct directory as well.

                    Once deployed the URL would be
                    /seam-registration


                    • 7. Re: HTTP Status 404 - /registration/
                      Vikram Chhetry Newbie

                      thanks jay

                      i manualy copied the ear to jboss deply directory and its working fine.
                      But why is it creating new folder Applications, and why isnt it deploying the application directly to the jboss deply folder. My build.xml looks like this

                      <property name="jboss.home" value="/opt/jboss-4.2.2.GA" />
                      <property name="deploy.dir" value="${jboss.home}/server/default/deploy" />
                      
                      <property name="webroot.dir" value="${deploy.dir}/jbossweb-tomcat55.sar/ROOT.war" />
                      
                      <!-- <property name="webroot.dir" value="${deploy.dir}/jboss-web.deployer/ROOT.war" /> -->


                      Thanks for ur reply

                      • 8. Re: HTTP Status 404 - /registration/
                        Jay Balunas Master

                        Ant properties are immutable so that once a property is set it can not be changes.

                        The jboss.home is set in the build.properties file in the root directory of the seam distrobution.

                        Try changing it there instead of overriding the value.

                        -Jay

                        • 9. Re: HTTP Status 404 - /registration/
                          Vikram Chhetry Newbie

                          Following line was added by in build.xml in root directory of seam

                          <property name="jboss.home" value="/opt/jboss-4.2.2.GA" />


                          • 10. Re: HTTP Status 404 - /registration/
                            Vikram Chhetry Newbie

                            I mean in build.xml of seam root directory i made some changes. Now it looks like this:-

                            <property name="jboss.home" value="/opt/jboss-4.2.2.GA" />
                            <property name="deploy.dir" value="${jboss.home}/server/default/deploy" />
                            
                            <property name="webroot.dir" value="${deploy.dir}/jbossweb-tomcat55.sar/ROOT.war" />


                            Even then its not deplying it in jboss deploy folder

                            • 11. Re: HTTP Status 404 - /registration/
                              Jay Balunas Master

                              Like I said the problem is most likely that the build.properties file is being read in and its values are used (configured) first - prior to the setting that you made. The first value set is used.

                              What does your build.properties file look like?

                              • 12. Re: HTTP Status 404 - /registration/
                                Vikram Chhetry Newbie

                                build.properties

                                #See build/sample.build.properties for properties you might want to set
                                #Wed Dec 12 11:30:23 CST 2007
                                qualifier=.CR1
                                mavenized=false



                                • 13. Re: HTTP Status 404 - /registration/
                                  Vikram Chhetry Newbie

                                  build/sample.build.properties

                                  # Use this properties file to set system specific properties
                                  # ----------------------------------------------------------
                                  #
                                  # Location of JBoss AS and Tomcat
                                  # -------------------------------
                                  #jboss.home /Applications/jboss-4.2.1.GA # Default
                                  #tomcat.home /Applications/apache-tomcat-6.0 # Default
                                  #jboss.home C:\\jboss-4.2.1.GA
                                  #tomcat.home C:\\Tomcat-6.0
                                  #
                                  # Misc Settings
                                  # -------------
                                  # Enabled validation of example XML descriptors
                                  #validate.xml true
                                  # Directory in which to put build distribution, defaults to ../jboss-seam-${version}.${patchlevel}
                                  #dist.dir ../jboss-seam-dist
                                  # alphanumeric qualifier for the version number
                                  #qualifier -SNAPSHOT
                                  


                                  • 14. Re: HTTP Status 404 - /registration/
                                    Jay Balunas Master

                                    Here's whats going on.

                                    In the readme.txt:

                                    2. Edit the "build.properties" file and change jboss.home to your
                                    JBoss AS installation directory


                                    The default jboss.home property is set to "/Applications/..." and needs to be overwritten using the build.properties file.

                                    Try setting it there as the readme.txt instructions and it should work.

                                    regards,
                                    Jay

                                    1 2 Previous Next