Bug 899666 (JBPAPP6-1542) - RESTEasy: Empty cfg. param javax.ws.rs.Application produces exception
Summary: RESTEasy: Empty cfg. param javax.ws.rs.Application produces exception
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: JBPAPP6-1542
Product: JBoss Enterprise Application Platform 6
Classification: JBoss
Component: RESTEasy
Version: TBD EAP 6
Hardware: Unspecified
OS: Unspecified
medium
medium
Target Milestone: DR9
: EAP 6.4.0
Assignee: Weinan Li
QA Contact: Katerina Odabasi
URL: http://jira.jboss.org/jira/browse/JBP...
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2011-12-15 15:55 UTC by Pavel Janousek
Modified: 2019-08-19 12:42 UTC (History)
6 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
The RESTEasy component shipped with previous versions of JBoss EAP 6 threw an `java.lang.StringIndexOutOfBoundsException: String index out of range: 0` error when the _javax.ws.rs.Application_ configuration option in the `WEB-INF/web.xml` file was left empty. The issue has been corrected in this release with an upgrade to the RESTeasy component.
Clone Of:
Environment:
Last Closed: 2019-08-19 12:42:41 UTC
Type: Bug
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Bugzilla 899665 1 None None None 2021-01-20 06:05:38 UTC
Red Hat Bugzilla 899689 1 None None None 2021-01-20 06:05:38 UTC
Red Hat Issue Tracker AS7-3055 0 None None None 2014-08-28 10:08:38 UTC
Red Hat Issue Tracker JBPAPP6-1542 0 None None None 2014-08-28 10:08:38 UTC
Red Hat Issue Tracker RESTEASY-1030 0 None None None 2014-08-28 10:08:38 UTC

Internal Links: 899665 899689

Description Pavel Janousek 2011-12-15 15:55:20 UTC
project_key: JBPAPP6

RESTEasy can be configured through several configuration options in WAR application deployment file WEB-INF/web.xml. The major one (also portable defined by JAX-RS standard) is _javax.ws.rs.Application_. When I set this parameter to empty content present behavior is raising exception "java.lang.StringIndexOutOfBoundsException: String index out of range: 0", it is not so good.

I think, this is hard miss-configuration error and deployment description as this one should be rejected and a such application should not be deployed at all with appropriate error message, but not only by messed exception.

Comment 1 Pavel Janousek 2011-12-15 15:55:48 UTC
Link: Added: This issue relates to JBPAPP-7768


Comment 2 Pavel Janousek 2011-12-15 15:56:01 UTC
Link: Added: This issue Cloned to JBPAPP-7771


Comment 5 Pavel Janousek 2012-01-05 11:34:37 UTC
Link: Added: This issue is related to JBPAPP-7859


Comment 6 Shelly McGowan 2012-02-21 18:42:47 UTC
Not yet fixed in RESTEasy trunk.  If it gets in to 2.3.2 upgrade, will be done in ER4.  

Comment 7 Rajesh Rajasekaran 2012-04-02 16:32:03 UTC
RESTEasy 2.3.2 release made it into the ER4 build. However I don't see the upstream JIRA as resolved. Weinan, can you comment if this issue was resolved in the 2.3.2 release? 

Comment 8 Rajesh Rajasekaran 2012-04-30 19:43:19 UTC
Weinan, Was the pull request merged upstream? As this priority on this release was downgraded, do you want to delay cutting a new resteasy release or do you plan to cut a release now since the fix is available. Please check the cutoff dates with Shelly if you plan to cut the release or move the fix version to TBD EAP6

Comment 10 Anne-Louise Tangring 2012-11-13 21:01:43 UTC
Docs QE Status: Removed: NEW 


Comment 11 Weinan Li 2013-09-23 10:41:25 UTC
My PR has been rejected 7 month ago and marked as 'old stuff' by Bill:

https://github.com/resteasy/Resteasy/pull/82/files

So mark this issue as won't fix.

Comment 12 Pavel Janousek 2013-09-24 07:25:55 UTC
Sorry Weinen, but I don't agree with the resolution. I understand from project PoV, this is a bit older issue and branch, but from product PoV, we need to maintain it for long time (5+ years). I can't accept the reason 'old stuff' as enough for not to fix a such weird issue in our product. Is there any other way how we can handle a such situation? Can QE help you somehow with escalation?

Comment 13 Weinan Li 2013-09-24 10:54:02 UTC
Hi Pavel, Bill has rejected the PR for this.

Please create an issue on JIRA against Branch_2_3 and assign it to Bill and explain why we need it. If he could get the PR merged then we could have a new release for RESTEasy 2.3.x.

(In reply to Pavel Janousek from comment #12)
> Sorry Weinen, but I don't agree with the resolution. I understand from
> project PoV, this is a bit older issue and branch, but from product PoV, we
> need to maintain it for long time (5+ years). I can't accept the reason 'old
> stuff' as enough for not to fix a such weird issue in our product. Is there
> any other way how we can handle a such situation? Can QE help you somehow
> with escalation?

Comment 14 Pavel Janousek 2013-09-24 11:15:06 UTC
Hi Weinen, I understand what you are requesting, but we are testing the product and its issues are tracked in BZ. I'm not sure if it is correct way how to handle the issue now. 

Based on Brian's comment on JIRA, what about to create new PR to current EAP-6.2 branch and we will see if it works? Moreover, all PRs should be against EAP plus WildFly as well, but it is a longer time I've sent some PR though.

Comment 15 Weinan Li 2013-09-25 08:34:36 UTC
All the PRs must go to Branch_2_3 branch RESTEasy. It's already the maintenance branch for EAP6.

Comment 16 mark yarborough 2014-03-18 21:21:04 UTC
Requesting clarification on owner, relevance, target since this bug
more than than two years old and less than POST state: 

http://post-office.corp.redhat.com/archives/eap6-triage/2014-March/msg00001.html

Comment 17 Weinan Li 2014-03-19 07:44:56 UTC
As Bill rejected the PR, this bug won't be fixed in Branch_2_3.

Comment 18 Petr Sakař 2014-03-19 07:49:42 UTC
Created upstream JIRA as requested. The fix is so easy I do not see the reason why it should not be done. Upstream version 2.3.8 (branch Branch_2_3) is used for EAP only at this moment. If it will not be accepted upstream, it can be sent to our internal repo from which is build resteasy for EAP

Comment 19 Petr Sakař 2014-03-19 08:10:24 UTC
PR prepared https://github.com/resteasy/Resteasy/pull/454

Comment 20 JBoss JIRA Server 2014-03-19 13:29:42 UTC
Bill Burke <bill> updated the status of jira RESTEASY-1030 to Closed

Comment 21 Weinan Li 2014-06-17 11:49:49 UTC
It will be included in RESTEasy 2.3.9

Comment 22 Scott Mumford 2014-07-02 03:48:01 UTC
Marking as a Known Issue for the 6.3.0 Release Notes.

Draft note added.

Comment 23 Scott Mumford 2014-07-17 04:15:50 UTC
Making public for inclusion in 6.3.0 Release Notes.

Comment 24 Katerina Odabasi 2014-09-24 07:51:48 UTC
The fix is not present because resteasy is still in version 2.3.8.Final-redhat-3 not 2.3.9.

Comment 29 Katerina Odabasi 2014-11-14 09:53:20 UTC
Verified in EAP 6.4.0.DR9, org.jboss.resteasy.spi.ResteasyDeploymentTest.


Note You need to log in before you can comment on or make changes to this bug.