• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

Stateless EJB 3.1 as a REST endpoint (javax.ws.rs.core.Application, @Stateless, @Path, @GET)

 
Ranch Hand
Posts: 623
1
IntelliJ IDE Java Linux
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Howdy Ranchers!

Simple question - can an @Stateless EJB which is a REST endpoint (@Path, @GET, etc.) packaged and deployed as a EJB-JAR, or to make it accessible it have to be a WAR?

Thanks in advance,

Cheers!
 
Sheriff
Posts: 10445
227
IntelliJ IDE Ubuntu
  • Likes 1
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Section 2.3 of JaxRS spec has the details. In brief, within a Java EE environment .war deployment is the only supported way. There's a section on "Other Container" in the spec which says that servers might provide a different way of packaging but I don't know if any server does.
 
Piotr Nowicki
Ranch Hand
Posts: 623
1
IntelliJ IDE Java Linux
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Thanks Jaikiran!

I looked for this answer in the EJB spec but without a luck.
I will then proceed with the JAX-RS spec.

Cheers!
 
reply
    Bookmark Topic Watch Topic
  • New Topic