Set Deployer EE version

13 views
Skip to first unread message

hantsy bai

unread,
Oct 11, 2025, 6:06:18 AM (8 days ago) Oct 11
to codehau...@googlegroups.com
HI, 
I tried to use cargo to start the latest Jetty 12.1.x with Jakarta EE 11 , and  set 
deployer ee version to ee11 or 11, and got the following error when the cargo maven goal. 

Error: Starting container [org.codehaus.cargo.container.jetty.Jetty12xInstalledLocalContainer@75345061] failed, now stopping container
Error: Failed to execute goal org.codehaus.cargo:cargo-maven3-plugin:1.10.22:start (start-server) on project spring7-examples-mvc-freemarker: Cannot start container [org.codehaus.cargo.container.jetty.Jetty12xInstalledLocalContainer@75345061]: Failed to create a Jetty 12.1.2 standalone configuration: Failed to deploy [/home/runner/work/spring7-sandbox/spring7-sandbox/mvc-freemarker/target/demo.war] to [/home/runner/work/spring7-sandbox/spring7-sandbox/mvc-freemarker/target/cargo/configurations/jetty12x/webapps]: Specified EE version is invalid. Possible values: [_9_0, _10_0, ] -> [Help 1]
---

Regards,

Hantsy Bai

Self-employed consultant, fullstack developer, agile coach, freelancer/remote worker

GitHub: https://github.com/hantsy

Twitter: https://twitter.com/@hantsy

Medium: https://medium.com/@hantsy

S. Ali Tokmen

unread,
Oct 11, 2025, 9:38:33 AM (8 days ago) Oct 11
to codehau...@googlegroups.com
Hi Hantsy

Indeed, Jetty 12.1 is actually different enough for the previous container to not function anymore 🙄 I hence checked in a series of improvements to add Jetty 12.1 and EE11 support, not released yet.

Have you tried with version 1.10.23-SNAPSHOT already?

Regards


--
Codehaus Cargo - https://codehaus-cargo.github.io/
---
You received this message because you are subscribed to the Google Groups "Codehaus Cargo" group.
To unsubscribe from this group and stop receiving emails from it, send an email to codehaus-carg...@googlegroups.com.
To view this discussion visit https://groups.google.com/d/msgid/codehaus-cargo/CAMq3Qk0z_CCy2vKdQ6_84bo-PRxdq6NJC2a_u8E80YWtGAFJeg%40mail.gmail.com.

hantsy bai

unread,
Oct 12, 2025, 10:02:25 PM (6 days ago) Oct 12
to codehau...@googlegroups.com
Updated to the cargo 1.10.23, still got the same error

Caused by: org.codehaus.cargo.util.CargoException: Specified EE version is invalid. Possible values: [_9_0, _10_0, ]
    at org.codehaus.cargo.container.jetty.Jetty12xInstalledLocalDeployer.createContextXml(Jetty12xInstalledLocalDeployer.java:74)
    at org.codehaus.cargo.container.jetty.Jetty6xInstalledLocalDeployer.doDeploy(Jetty6xInstalledLocalDeployer.java:110)
---

Regards,

Hantsy Bai

Self-employed consultant, fullstack developer, agile coach, freelancer/remote worker

GitHub: https://github.com/hantsy

Twitter: https://twitter.com/@hantsy

Medium: https://medium.com/@hantsy

S. Ali Tokmen

unread,
Oct 13, 2025, 5:12:21 PM (5 days ago) Oct 13
to codehau...@googlegroups.com

Hi Hantsy

Good catch, it seems the Jetty deplorer’s context.xml capability didn't have a single testcase and hence the EE11 implementation being incomplete was never caught 😮

I added https://github.com/codehaus-cargo/cargo/blob/master/core/samples/java/src/test/java/org/codehaus/cargo/sample/java/jetty/JettyWarContextXmlTestCase.java now, and of course a bunch of commits to fix the actual bug too. Let's see what the CI says 😉

--
Codehaus Cargo - https://codehaus-cargo.github.io/
---
You received this message because you are subscribed to the Google Groups "Codehaus Cargo" group.
To unsubscribe from this group and stop receiving emails from it, send an email to codehaus-carg...@googlegroups.com.

S. Ali Tokmen

unread,
Oct 14, 2025, 3:42:07 PM (4 days ago) Oct 14
to codehau...@googlegroups.com

Hi Hantsy

This turned out more complex than initially assessed, I now created https://codehaus-cargo.atlassian.net/browse/CARGO-1650 and added links to the different commits.

Let's see what the results from the CI build https://codehaus-cargo.semaphoreci.com/workflows/fdefca52-c67b-4891-9ce2-b8f51ed17a11?pipeline_id=4aa51bc5-3158-4433-b37b-789398f66d9c will show!

Hantsy Bai

unread,
Oct 15, 2025, 11:44:28 PM (3 days ago) Oct 15
to Codehaus Cargo
It is still problematic. I encountered an error when upgrading to version 1.10.24. 

 2025-10-16 11:33:27.316:INFO :oejsh.ContextHandler:main: Started oeje10w.WebAppContext@4ea5b703{/cargocpc,/cargocpc,b=file:///C:/Users/hantsy/AppData/Local/Temp/jetty-0_0_0_0-8080-cargocpc_war-_cargocpc-any-4253058696989776723/webapp/,a=AVAILABLE,h=oeje10s.SessionHandler@12359a82{STARTED}}{file:///D:/hantsylabs/spring7-sandbox/mvc-freemarker/target/cargo/configurations/jetty12x/webapps/cargocpc.war}
[INFO] 2025-10-16 11:33:27.383:INFO :oeje10s.ServletContextHandler:main: Started oeje10w.WebAppContext@4ea5b703{/cargocpc,/cargocpc,b=file:///C:/Users/hantsy/AppData/Local/Temp/jetty-0_0_0_0-8080-cargocpc_war-_cargocpc-any-4253058696989776723/webapp/,a=AVAILABLE,h=oeje10s.SessionHandler@12359a82{STARTED}}{file:///D:/hantsylabs/spring7-sandbox/mvc-freemarker/target/cargo/configurations/jetty12x/webapps/cargocpc.war}
[INFO] 2025-10-16 11:33:27.392:WARN :oejd.DeploymentScanner$PathsApp:main: Environment not found ee11
[INFO] 2025-10-16 11:33:27.395:WARN :oejd.DeploymentScanner:main: Failed to to perform action DEPLOY on oejd.DeploymentScanner$PathsApp@2efde3[demo|ADDED, env=ee11, mainPath=D:\hantsylabs\spring7-sandbox\mvc-freemarker\target\cargo\configurations\jetty12x\webapps\demo.xml, paths=[D:\hantsylabs\spring7-sandbox\mvc-freemarker\target\cargo\configurations\jetty12x\webapps\demo.properties|ADDED, D:\hantsylabs\spring7-sandbox\mvc-freemarker\target\cargo\configurations\jetty12x\webapps\demo.xml|ADDED], contextHandler=<unset>]
[INFO] java.lang.IllegalStateException:
Unable to deploy demo to environment ee11. Available environments: [ee10]

According to the Eclipse Jetty distribution page, creating a new identifier for Jetty 12.1.x may be better.

https://jetty.org/docs/jetty/12.1/index.html

Jetty 12.1, the available ee should be from 8 to 11
Jetty 12, the available ee should be 8-10

S. Ali Tokmen

unread,
Oct 16, 2025, 12:40:26 AM (3 days ago) Oct 16
to codehau...@googlegroups.com

Hi Hantsy

As per https://codehaus-cargo.github.io/cargo/Jetty+12.x.html, you also need to set JettyPropertySet.MODULES (in other words, cargo.jetty.modules) so it has ee11. It would hence most likely have to be set to server,ext,http,ee11-annotations,ee11-plus,ee11-jsp,ee11-deploy

hantsy bai

unread,
Oct 16, 2025, 1:05:03 AM (3 days ago) Oct 16
to codehau...@googlegroups.com
Thanks, set the modules to make it work.

But I think the properties setup is a little tedious. I hope to set a ee deployer version to resolve the modules by ee version automatically.

Unless the developers want to customize it.

---

Regards,

Hantsy Bai

Self-employed consultant, fullstack developer, agile coach, freelancer/remote worker

GitHub: https://github.com/hantsy

Twitter: https://twitter.com/@hantsy

Medium: https://medium.com/@hantsy

You received this message because you are subscribed to a topic in the Google Groups "Codehaus Cargo" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/codehaus-cargo/Muxbd4680UU/unsubscribe.
To unsubscribe from this group and all its topics, send an email to codehaus-carg...@googlegroups.com.
To view this discussion visit https://groups.google.com/d/msgid/codehaus-cargo/581dd685-e48f-43e8-a7df-488a206471f9%40alishomepage.com.

S. Ali Tokmen

unread,
Oct 16, 2025, 5:27:04 PM (2 days ago) Oct 16
to codehau...@googlegroups.com

Hi Hantsy

Thanks for your feedback, this is more a question of "philosophy" than actual development...

As per https://jetty.org/docs/jetty/12.1/operations-guide/begin/index.html whoever uses Jetty must give the list of services - Hence Codehaus Cargo also requesting the same.

What we could do, of course, is to make the services "auto adapt" if not explicitly set in Codehaus Cargo.

What would be your thoughts?

hantsy bai

unread,
Oct 16, 2025, 9:51:45 PM (2 days ago) Oct 16
to codehau...@googlegroups.com
For an end user, I do not want to explicitly set the EE deployer version and modules together. 

When we set the EE deployer version, we can automatically set the essential modules for this version if the Jetty modules are not specified. 

Unless the developers explicitly set the modules due to some required modules are not included in the default modules list. 

Most of the time, I think I do not want to set it. 
---

Regards,

Hantsy Bai

Self-employed consultant, fullstack developer, agile coach, freelancer/remote worker

GitHub: https://github.com/hantsy

Twitter: https://twitter.com/@hantsy

Medium: https://medium.com/@hantsy

S. Ali Tokmen

unread,
3:11 AM (28 minutes ago) 3:11 AM
to codehau...@googlegroups.com
Reply all
Reply to author
Forward
0 new messages