[jboss-jira] [JBoss JIRA] (AS7-3199) RESTEasy: Can't deploy WebApp if more than one subclass of javax.ws.rs.Application is present

Bill Burke (JIRA) jira-events at lists.jboss.org
Fri Feb 22 10:33:57 EST 2013


    [ https://issues.jboss.org/browse/AS7-3199?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12756127#comment-12756127 ] 

Bill Burke commented on AS7-3199:
---------------------------------

Its really bad practice for third-party libs to include Application classes as there is no way to exclude them from a scan.  
FWIW, you think my comments are angry, well, its more frustration that I have to keep repeating myself.  I'll elaborate a little bit more to give a better picture:  Anybody using the ServletContextListener to bootstrap resteasy would become broken if I fixed the Application problem.  This includes anybody using the Spring and Guice integrations.  Does that paint a clearer picture?

What I think can be done is to change the JAX-RS AS deployer so that it only barfs if there are multiple Application classes annotated with @ApplicationPath and ignore any other non-annotated Application class.  Anything other than that will have to wait.  Sorry, but that's just the way it is.

BTW, if you decide to remove Resteasy from AS and/or EAP or offer an alternative, please let me know so I can look for another job.  Thanks.

                
> RESTEasy: Can't deploy WebApp if more than one subclass of javax.ws.rs.Application is present
> ---------------------------------------------------------------------------------------------
>
>                 Key: AS7-3199
>                 URL: https://issues.jboss.org/browse/AS7-3199
>             Project: Application Server 7
>          Issue Type: Bug
>          Components: REST
>    Affects Versions: 7.1.0.CR1b
>            Reporter: Pavel Janousek
>         Attachments: ExampleJAXRS.war
>
>
> If I packed WAR WebApp with more that one subclass of javax.ws.rs.Application, deployment fails with "JBAS011232: Only one JAX-RS Application Class allowed."
> This is not correct because it is against JAX-RS 1.1. specs where invalid situation (in section 2.3.2) is only when "It is a n error for
> more than one application to be deployed +at the same effective servlet mapping+".
> If you have any objections, please compare to reference JEE6 and JAX-RS implementation represented by the GlassFish Prelude 3.1.1 application server with already +fully JEE6 platform support+.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira


More information about the jboss-jira mailing list