I think that executing the following command should fix your issue:
/:full-replace-deployment(name=helloworld.war, content=[{path=/home/ehugonne/dev/wildfly/quickstart/helloworld/target/helloworld.war,
archive=true}],enabled=true, runtime-name=MyApp.war)
Emmanuel
Le 10/02/2025 à 13:26, Christian Winkler a écrit :
> I'm not sure anymore which version worked or if I'm confusing something.
> In any case, it doesn't work as it should.
>
> On Monday, February 10, 2025 at 1:12:28 PM UTC+1 Bartosz Baranowski wrote:
>
> baranowb@drone-1-1:~/tmp/wildfly-26.1.2.Final$ ./bin/jboss-cli.sh --connect --command="deploy
> /home/baranowb/redhat/git/quickstart/helloworld/target/helloworld-1.0.war --runtime-name=MyApp --force"
> baranowb@drone-1-1:~/tmp/wildfly-26.1.2.Final$ ./bin/jboss-cli.sh --connect --command="deploy
> /home/baranowb/redhat/git/quickstart/helloworld/target/helloworld-1.0.war --runtime-name=MyApp --force"
> baranowb@drone-1-1:~/tmp/wildfly-26.1.2.Final$ ./bin/jboss-cli.sh --connect --command="deploy
> /home/baranowb/redhat/git/quickstart/helloworld/target/helloworld-1.1.war --runtime-name=MyApp --force"
> {"WFLYCTL0062: Composite operation failed and was rolled back. Steps that failed:" => {"Operation step-2" => "WFLYSRV0205: There is
> already a deployment called helloworld-1.1.war with the same runtime name MyApp"}}
> baranowb@drone-1-1:~/tmp/wildfly-26.1.2.Final$
>
>
> On Monday, 10 February 2025 at 13:04:22 UTC+1 Bartosz Baranowski wrote:
>
> I did.
> I need to verify with older versions, but there is workaround, deploy artifact name must be constant to make it work.
>
> Workaround:
> ✘-INT~/redhat/git/wildfly/ee-dist/target/wildfly-35.0.0.Beta1-SNAPSHOT[master|✔]
> $ ./bin/jboss-cli.sh --connect --command="deploy /home/baranowb/redhat/git/quickstart/helloworld/target/helloworld-1.0.war
> --runtime-name=MyApp --force"
> ✔~/redhat/git/wildfly/ee-dist/target/wildfly-35.0.0.Beta1-SNAPSHOT[master|✔]
> $ ./bin/jboss-cli.sh --connect --command="deploy /home/baranowb/redhat/git/quickstart/helloworld/target/helloworld-1.0.war
> --runtime-name=MyApp --force"
> ✔~/redhat/git/wildfly/ee-dist/target/wildfly-35.0.0.Beta1-SNAPSHOT[master|✔]
>
> ^^ wont blow up.
> On Monday, 10 February 2025 at 10:21:32 UTC+1 Christian Winkler wrote:
>
> I've created
https://issues.redhat.com/browse/WFLY-20376 but cannot change the assignee.
>
> On Monday, February 10, 2025 at 9:05:02 AM UTC+1 Bartosz Baranowski wrote:
>
> Seems like its a bug:
> 08:45$ ./bin/jboss-cli.sh --connect --command="deploy
> /home/baranowb/redhat/git/quickstart/helloworld/target/helloworld-1.0.war --runtime-name=MyApp --force"
> ✔~/redhat/git/wildfly/ee-dist/target/wildfly-35.0.0.Beta1-SNAPSHOT[master|✔]
> 08:45$ ./bin/jboss-cli.sh --connect --command="deploy
> /home/baranowb/redhat/git/quickstart/helloworld/target/helloworld-1.1.war --runtime-name=MyApp --force"
> {"WFLYCTL0062: Composite operation failed and was rolled back. Steps that failed:" => {"Operation step-2" => "WFLYSRV0205:
> There is already a deployment called helloworld-1.1.war with the same runtime name MyApp"}}
> ✘-1~/redhat/git/wildfly/ee-dist/target/wildfly-35.0.0.Beta1-SNAPSHOT[master|✔]
>
>
>
> given that in cli:
> --force - if the deployment with the specified name already exists,
> by default, deploy will be aborted and the corresponding
> message will printed. Switch --force (or -f) will force the
> replacement of the existing deployment with the one
> specified in the command arguments.
>
>
> Could you please create ticket and assign it to me?
> On Thursday, 6 February 2025 at 10:24:07 UTC+1 Christian Winkler wrote:
>
> With WildFly 27 I used the following command for updating a deployed and running app 'MyApp-1.0.0.war' to new version
> 1.0.1
>
> ./jboss-cli.sh --connect --command="deploy MyApp-1.0.1.war --runtime-name=MyApp --force"
>
> The --force option led to replacing the the deployment with the new updated WAR file.
>
> The same command now fails with WildFly 32.0.1 with the following error.
> WFLYSRV0205: There is already a deployment called MyApp-1.0.1.war with the same runtime name MyApp
>
> Please note that even the error message is wrong. There is no deployment 1.0.1 in WF but the old 1.0.0
>
> Is there any change for version 32 that I've missed?
>
> --
> You received this message because you are subscribed to the Google Groups "WildFly" group.
> To unsubscribe from this group and stop receiving emails from it, send an email to
wildfly+u...@googlegroups.com.
> To view this discussion visit
https://groups.google.com/d/msgid/wildfly/10333036-79c0-47b6-8373-581d25d2a7b5n%40googlegroups.com
> <
https://groups.google.com/d/msgid/wildfly/10333036-79c0-47b6-8373-581d25d2a7b5n%40googlegroups.com?utm_medium=email&utm_source=footer>.