how to deploy web application and web service in glassfish server
I want to deploy web application开发者_开发技巧 and web service in a glassfish server . How can I do it? can I deploy two applications on different port? I can't combine the web application and RESTful web service.
thanks
Web apps and Jersey web services are both deployed in WARs. So, you have several options.
You can combine the two in to a single web app, and deploy a single WAR.
You can deploy them in separate WARs, with separate contexts (i.e. /war1, /ws2).
You can create a new virtual server (which can listen on any port) and one WAR to each, and then they can both be using the same context, they're just use different hosts and/or ports.
It's not clear what problem you're having or what you're trying to do, but those are the three main options available to you.
精彩评论