Note: This bug is displayed in read-only format because the product is no longer active in Red Hat Bugzilla.

Bug 1068709

Summary: Unsuccessful REST request results in HTTP code 500 with exception not related to the actual error
Product: [Retired] JBoss BRMS Platform 6 Reporter: Petr Široký <psiroky>
Component: Business CentralAssignee: Roger Martínez <romartin>
Status: CLOSED CURRENTRELEASE QA Contact: Petr Široký <psiroky>
Severity: high Docs Contact:
Priority: high    
Version: 6.0.0CC: kverlaen, lpetrovi, rrajasek
Target Milestone: ER2   
Target Release: 6.0.1   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2014-08-06 19:57:28 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Attachments:
Description Flags
Internal error 500 response none

Description Petr Široký 2014-02-21 17:47:26 UTC
Created attachment 866176 [details]
Internal error 500 response

Description of problem:
If the REST request ends with an error (like when user wants to clone repository and gives the name that already exists or tries to delete non-existent repository) the server returns a 500 HTTP error code with following exception, which is _not_ related to the real problem that occurred (e.g. duplicate repo name):

java.lang.IllegalAccessError: tried to access method org.jboss.solder.exception.control.ExceptionStack.dropCause()V from class org.jboss.solder.exception.control.ExceptionHandlerDispatch

The server should return HTTP code "400 Bad Request" or something like that with clear error message.

See the attached HTML page with the complete response body.


Version-Release number of selected component (if applicable):
6.0.1-ER1


How reproducible:
Always

Steps to Reproduce:
1. Send REST request with following json payload:
{"name":"jbpm-playground", "description":"", "userName":"", "password":"", "requestType":"clone", "gitURL":"git:droolsjbpm/jbpm-playground.git"}
2. Sent the above request once more.


Actual results:
Internal error (500) HTTP response with ugly stacktrace, not related to the actual reason why the request
failed.


Expected results:
I guess some kind of 4xx HTTP response with clear error message.


Additional info:

Comment 1 manstis 2014-02-25 11:57:05 UTC
Hi Marco, would you mind taking a look at this please? Thanks, Mike

Comment 2 Kris Verlaenen 2014-02-25 16:13:35 UTC
Seems to be related to issue with modules

Comment 3 Petr Široký 2014-02-25 16:32:07 UTC
Kris, that might be the case. I just quickly explored the distributions for 6.0.0-GA and 6.0.1-ER1 and the structure regarding the modules has indeed changed.

6.0.0-GA (find . -name "*solder*"):
-----------------------------------
./standalone/deployments/business-central.war/WEB-INF/lib/org.jboss.solder-solder-impl-jar-webfragment.jar
./modules/system/layers/bpms/org/jboss/solder
./modules/system/layers/bpms/org/jboss/solder/main/solder-impl-3.2.1.Final.jar
./modules/system/layers/bpms/org/jboss/solder/main/solder-logging-3.2.1.Final.jar
./modules/system/layers/bpms/org/jboss/solder/main/solder-api-3.2.1.Final.jar

6.0.1-ER1 (find . -name "*solder*"):
------------------------------------
./standalone/deployments/business-central.war/WEB-INF/lib/solder-impl-3.2.1.Final.jar
./modules/system/layers/bpms/org/jboss/solder
./modules/system/layers/bpms/org/jboss/solder/main/solder-logging-3.2.1.Final.jar
./modules/system/layers/bpms/org/jboss/solder/main/solder-api-3.2.1.Final.jar

Comment 4 Roger Martínez 2014-02-25 21:00:52 UTC
Petr, Kris,

You are right about the module differences.

This issue is a duplicate and has been fixed in
- https://bugzilla.redhat.com/show_bug.cgi?id=1067048

Please, take a look at the last comment for that issue which explains the problem and the solution.

@Petr: Can you give me feedback about is this issue it's still not happening since the BZ 1067048 has been closed?

Thanks in advance.
Roger

(In reply to Petr Siroky from comment #3)
> Kris, that might be the case. I just quickly explored the distributions for
> 6.0.0-GA and 6.0.1-ER1 and the structure regarding the modules has indeed
> changed.
> 
> 6.0.0-GA (find . -name "*solder*"):
> -----------------------------------
> ./standalone/deployments/business-central.war/WEB-INF/lib/org.jboss.solder-
> solder-impl-jar-webfragment.jar
> ./modules/system/layers/bpms/org/jboss/solder
> ./modules/system/layers/bpms/org/jboss/solder/main/solder-impl-3.2.1.Final.
> jar
> ./modules/system/layers/bpms/org/jboss/solder/main/solder-logging-3.2.1.
> Final.jar
> ./modules/system/layers/bpms/org/jboss/solder/main/solder-api-3.2.1.Final.jar
> 
> 6.0.1-ER1 (find . -name "*solder*"):
> ------------------------------------
> ./standalone/deployments/business-central.war/WEB-INF/lib/solder-impl-3.2.1.
> Final.jar
> ./modules/system/layers/bpms/org/jboss/solder
> ./modules/system/layers/bpms/org/jboss/solder/main/solder-logging-3.2.1.
> Final.jar
> ./modules/system/layers/bpms/org/jboss/solder/main/solder-api-3.2.1.Final.jar

Comment 5 Petr Široký 2014-02-26 09:13:48 UTC
Roger,

the BZ 1067048 has not been closed, just moved to MODIFIED. That means it should be fixed in next product build ER2. I will let you know if this issue is fixed when the ER2 arrives.

Comment 6 Roger Martínez 2014-02-26 11:18:00 UTC
Thanks Petr,

Only if it's possible for you... If I provide you both bpms layer ZIP and the skinny WAR can you try it instead of waiting for the release?? 

I would like to be sure that this issue is verified before the tomorrow's release but i have still a lot of pending work for today. Not sure if I'll have enough time...

Thanks

(In reply to Petr Siroky from comment #5)
> Roger,
> 
> the BZ 1067048 has not been closed, just moved to MODIFIED. That means it
> should be fixed in next product build ER2. I will let you know if this issue
> is fixed when the ER2 arrives.

Comment 7 Roger Martínez 2014-02-26 19:02:24 UTC
I have provided BPMS EAP modules distribution aritfacts to Petr and he had tested the issue:

"I think we can consider the issue to be solved, I was not able to reproduce the exception - so please move the BZ to modified and I will verify again with the next product build"

If the error reappears please reopen the bug.

Thanks

Comment 8 Petr Široký 2014-03-11 09:45:35 UTC
Correct exception is thrown, but the server still returns the code 500. I am not sure that is correct. I will create a new BZ if I found out it is indeed a bug. 

Verified fixed in 6.0.1-ER2.