I am using an open liberty to deploy a war using the application tag in the server.xml. I am required to change the context_root for an application but I want the current context root to redirect to the new url. Alternatively, if it were possible, I could use two context roots for the same app. I cannot find the answer in their documentation.
<application id="demo" location = "demo-0.0.3-SNAPSHOT.war" name="demo" context-root="/test"></application>
What are my options here for making changing /test to /newroot where my.host/test will redirect to my.host/newurl from within the server.xml?
It is not possible to bind a single war file to two context roots. A few options would be:
I would recommend upgrading to a newer release of Open Liberty since 20.0.0 is three years old now and there are a lot of fixes since then including security fixes.