3 Replies Latest reply on Jun 5, 2013 1:03 PM by wdfink

    What is jboss 7's behavior when two users deploy war files two different ways

    demisheep

      I wanted to find out if anyone knows the implications of deploying a single war file in jboss 7 using both methods: admin console and dropping the war in the /deployments/ directory.

       

      We have multiple users deploying the same war file and one of them uses the admin console where the others drop the file manually in the /deployments/ directory.

       

      This question arrised when the user who deploys using admin console said they deployed a new file and when I looked in the /deployments/ directory the date showed as a week ago.

       

      So, my quesiton is: How does jboss 7 handle this? Does it just use the last deployed file whichever it received last or does the admin console take precedence over the /deployments/ directory deploying method?

        • 1. Re: What is jboss 7's behavior when two users deploy war files two different ways
          wdfink

          It makes no difference (from what I know) if you use deployment-scanner or CLI.

           

          The problem is more the naming conflict.

          If you have the same ear/war binary and deploy it with different names you can reach the application with different names.

          If you have the same context-root for your webapp it will fail.

           

          If you deploy a app with CLI and the same app is droped to deployment directory earlier you need to use --force to overwrite. In that case the CLI deployed app will win, also if you restart later.

           

          I recommend to not use such approach in production, I often remove hotdeployment (the complete deployment-scanner in AS7) to ensure that the deployment is not done by touching files.

          • 2. Re: What is jboss 7's behavior when two users deploy war files two different ways
            demisheep

            I don't know that this is true, as we have seen some peculiar behavior such as one user uploading a war via ssh direclty to the /deployments/ directory to replace the one that was loaded in the console and the user still sees the content from the war loaded by the console. I need to do some experimenting with this when I have time.

            • 3. Re: What is jboss 7's behavior when two users deploy war files two different ways
              wdfink

              I've checked that local with a current EAP6.1.

              It might be that you have changed the scanner configuration.

              But as for such remote access I recommend to use the CLI as I'm not sure whether all remote copy commands are atomic. It might happen that you will have unwanted results.