Hey Bill,

Am 05.12.2012 um 22:37 schrieb Bill Burke:

> Java EE 6 doesn't support EJB + JAX-RS components that are not deployed 
> under the WEB-INF/lib or WEB-INF/classes.  SO, you must move 
> biz-stuff.jar into rest.war or create a JAX-RS service that delegates to 
> the EJBs.

I don't exactly understand this, as my set up works (except for that one case)
perfectly. I have a rest.war I set some params that are picked up by RE and
then a jar with all my rest endpoint implementation classes (SLSB with @Path 
and so on).
The REST stuff inside the jar gets activated by the presence of 
@ApplicationPath on
one of my application classes in the jar and then RE scans the EJBs and provides
endpoints for the ones decorated with @Path. Works nicely.
> 
> But, Resteasy can support it your case with a special config switch.
> 
> <context-param>
>       <param-name>resteasy.jndi.resources</param-name>
>       <param-value>LibraryBean/local</param-value>
>    </context-param>

But here I have to manually list all the @Local classes manually and can't use
the autoscan feature described above.


My issue is now that I have several web-apps inside the .ear with 
different context roots and I want the REST-endpoint only be present
below /rest and not in other places.

I was thinking that there may be an annotation or property to tell RestEasy
to only "intercept" requests that go to the /rest context root, but not to 
/examples.

Perhaps I need to change my whole application setup so that I put my rest 
endpoint
classes inside the war as EE6 allows

>> so I have in As7 the following situation:
>> 
>> rhq.ear/
>>    coregui.war/   at /coregui
>>    portal.war       at /
>>    rest.war/          at /rest
>>    rest-examples.war/   at /rest-examples
>>    biz-stuff.jar, containing the SLSBs implementing the REST-Interface
>> 
>> Now I want my rest-endpoints to live below /rest (e.g. localhost:8080/rest/ )
>> 
>> So inside the SLSBs I have one class with @ApplicationPath("/"), so that this
>> does not add another part to /rest/.
>> 
>> This has the effect that for all web contexts RestEasy is started and that 
>> then /rest/
>> is taking over requests to all other web contexts.
>> 
>> Is there a way in the above setup to still get the comfort of 
>> @ApplicationPath,
>> but limiting it to rest.war?
>> 
>>   Thanks
>>           Heiko
>> 
>> 
>> 
>> ------------------------------------------------------------------------------
>> LogMeIn Rescue: Anywhere, Anytime Remote support for IT. Free Trial
>> Remotely access PCs and mobile devices and provide instant support
>> Improve your efficiency, and focus on delivering more value-add services
>> Discover what IT Professionals Know. Rescue delivers
>> http://p.sf.net/sfu/logmein_12329d2d
>> 
>> 
>> 
>> _______________________________________________
>> Resteasy-users mailing list
>> Resteasy-users@lists.sourceforge.net
>> https://lists.sourceforge.net/lists/listinfo/resteasy-users
>> 
> 
> -- 
> Bill Burke
> JBoss, a division of Red Hat
> http://bill.burkecentral.com
> 
> ------------------------------------------------------------------------------
> LogMeIn Rescue: Anywhere, Anytime Remote support for IT. Free Trial
> Remotely access PCs and mobile devices and provide instant support
> Improve your efficiency, and focus on delivering more value-add services
> Discover what IT Professionals Know. Rescue delivers
> http://p.sf.net/sfu/logmein_12329d2d
> _______________________________________________
> Resteasy-users mailing list
> Resteasy-users@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/resteasy-users

-- 
Reg. Adresse: Red Hat GmbH, Technopark II, Haus C, 
Werner-von-Siemens-Ring 14, D-85630 Grasbrunn
Handelsregister: Amtsgericht M├╝nchen HRB 153243
Geschaeftsf├╝hrer:  Mark Hegarty, Charlie Peters, Michael Cunningham, Charles 
Cachera

Attachment: signature.asc
Description: Message signed with OpenPGP using GPGMail

------------------------------------------------------------------------------
LogMeIn Rescue: Anywhere, Anytime Remote support for IT. Free Trial
Remotely access PCs and mobile devices and provide instant support
Improve your efficiency, and focus on delivering more value-add services
Discover what IT Professionals Know. Rescue delivers
http://p.sf.net/sfu/logmein_12329d2d
_______________________________________________
Resteasy-users mailing list
Resteasy-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/resteasy-users

Reply via email to