Wouldn’t that result in two copies of my webapp actually running (which means double memory, etc)?
I think the answer is “use a load balancer / URL rewriter” but I guess I’m just hoping maybe there’s clever trick?
On 11/5/10 5:11 PM, "Mark Paulus" <mark.paulus_at_technologist.com> wrote:
Can you create 2 different .ear files, both using the same
.war/.ejb, and set the different contexts in the
.ear/aplication.xml file?
Or use apache forwarding?
From: Comerford, Sean [mailto:Sean.Comerford_at_espn.com]
Sent: Friday, November 05, 2010 2:08 PM
To: users_at_glassfish.dev.java.net
Subject: Multiple context roots for webapp?
I have a webapp foo.war that I deploy to glassfish. So of course it’s available at host:1234/foo
I also want it to be available at host:1234/bar
The catch is I have a default web app deployed to the instance which I CANNOT remove.
Is there any way to assign multiple context roots to a single webapp or otherwise accomplish the same?
Again, I want a single webapp to be available at /foo and /bar but CANNOT use / + servlet mappings to accomplish this.
--
Sean Comerford, Software Engineer
ESPN.com Site Architecture Group
Office: 860.766.6454 Cell: 860.329.5842