Deploying REST endpoint from the subsystem

classic Classic list List threaded Threaded
3 messages Options
Reply | Threaded
Open this post in threaded view
|

Deploying REST endpoint from the subsystem

Gytis Trikleris
Hello,

I am writing a JBoss AS subsystem which needs to register a REST endpoint during AS initialization. I wanted to ask what is the best way to do this without simply placing a war to the deployments directory?


Thanks,
Gytis

_______________________________________________
jboss-as7-dev mailing list
[hidden email]
https://lists.jboss.org/mailman/listinfo/jboss-as7-dev
Reply | Threaded
Open this post in threaded view
|

Re: Deploying REST endpoint from the subsystem

Jeff Mesnil

On 18 avr. 2013, at 12:03, Gytis Trikleris <[hidden email]> wrote:

> Hello,
> I am writing a JBoss AS subsystem which needs to register a REST endpoint during AS initialization. I wanted to ask what is the best way to do this without simply placing a war to the deployments directory?

You can use org.jboss.as.web.host.WebHost#addWebDeployment to deploy a web app from a subsystem.

jeff

--
Jeff Mesnil
JBoss, a division of Red Hat
http://jmesnil.net/


_______________________________________________
jboss-as7-dev mailing list
[hidden email]
https://lists.jboss.org/mailman/listinfo/jboss-as7-dev
Reply | Threaded
Open this post in threaded view
|

Re: Deploying REST endpoint from the subsystem

Tristan Tarrant
On 04/18/2013 12:08 PM, Jeff Mesnil wrote:
> On 18 avr. 2013, at 12:03, Gytis Trikleris <[hidden email]> wrote:
>
>> Hello,
>> I am writing a JBoss AS subsystem which needs to register a REST endpoint during AS initialization. I wanted to ask what is the best way to do this without simply placing a war to the deployments directory?
> You can use org.jboss.as.web.host.WebHost#addWebDeployment to deploy a web app from a subsystem.
Even better, you can avoid using the deployer:

https://github.com/infinispan/infinispan-server/blob/master/integration/src/main/java/org/infinispan/server/endpoint/subsystem/RestService.java

The above is still JBossWeb based, but I'll switch to Undertow as soon
as there is a release of AS8.

Tristan
_______________________________________________
jboss-as7-dev mailing list
[hidden email]
https://lists.jboss.org/mailman/listinfo/jboss-as7-dev