Bug 1033726 - Kie REST API client does not work due to: java.util.Map is an interface, and JAXB can't handle interfaces.
Summary: Kie REST API client does not work due to: java.util.Map is an interface, and ...
Keywords:
Status: CLOSED NOTABUG
Alias: None
Product: JBoss BPMS Platform 6
Classification: Retired
Component: Business Central
Version: 6.0.0
Hardware: Unspecified
OS: Unspecified
high
high
Target Milestone: ---
: 6.0.0
Assignee: Marco Rietveld
QA Contact: Jiri Svitak
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2013-11-22 17:43 UTC by Jiri Svitak
Modified: 2016-09-20 05:05 UTC (History)
3 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2013-11-26 11:10:42 UTC
Type: Bug


Attachments (Terms of Use)
perfcake.log (16.11 KB, text/plain)
2013-11-22 17:43 UTC, Jiri Svitak
no flags Details

Description Jiri Svitak 2013-11-22 17:43:06 UTC
Created attachment 827910 [details]
perfcake.log

Kie REST API client does not work. Pasting the relevant error message (see also the attached perfcake.log):

Caused by: com.sun.xml.bind.v2.runtime.IllegalAnnotationsException: 2 counts of IllegalAnnotationExceptions
java.util.Map is an interface, and JAXB can't handle interfaces.
	this problem is related to the following location:
		at java.util.Map
		at private java.util.Map org.kie.services.client.serialization.jaxb.impl.process.JaxbWorkItem.parameters
		at org.kie.services.client.serialization.jaxb.impl.process.JaxbWorkItem
java.util.Map does not have a no-arg default constructor.
	this problem is related to the following location:
		at java.util.Map
		at private java.util.Map org.kie.services.client.serialization.jaxb.impl.process.JaxbWorkItem.parameters
		at org.kie.services.client.serialization.jaxb.impl.process.JaxbWorkItem


To reproduce:
1.) Download BPMS 6 ER5 and merge it with EAP 6.1.1 distribution.
2.) Add user guest, password guest into EAP config files:
application-users.properties:  guest=b5d048a237bfd2874b6928e1f37ee15e
application-roles.properties:  guest=kie-user,admin
3.) Setup datasource for BPMS, I used PostgreSQL. Make sure the db is empty before the test. Do not use the default H2.
4.) Start the server and go to http://localhost:8080/business-central.
5.) Clone repository git://git.app.eng.bos.redhat.com/bpms-assets.git to your BPMS installation.
6.) Build&Deploy a project bpms-perf from the bpms-assets.git repo.
7.) Make sure you can run REST API command POST on address:
http://localhost:8080/kie-wb/rest/runtime/com.bpms.flood:bpms-perf:1.0.0.Final/process/com.bpms.flood.HumanTask/start
8.) Run the performance framework:
git clone git://git.app.eng.bos.redhat.com/jbossqe-process-flood.git
cd jbossqe-process-flood/bpms-6.x
./execute_scenario.sh -Dscenario=HumanTask_kieREST
(kieREST means that official kie REST client will be used)

This bug prevents to create complete performance report, because the REST API will be measured only by one REST client - HTTPSender class of PerfCake framework (in this case scenario HumanTask_pcREST).

My env:
BPMS 6 ER5
EAP 6.1.1
PostgreSQL 9.1.9
postgresql-9.1-902.jdbc4.jar

Comment 1 Marco Rietveld 2013-11-26 00:03:58 UTC
Would you mind retrying this, but with the jaxb-impl 2.2.5 dependency, instead of the 2.2.4 version which is used in jbossqe-process-flood/bpms-6.x ? 

2.2.5 supports Maps, while 2.2.4 does not. 

mvn dependency:tree reports that jbossqe-process-flood/bpmns-6.x uses 2.2.4: 

[INFO] +- org.jboss.resteasy:resteasy-atom-provider:jar:2.3.7.Final:compile
[INFO] |  +- org.jboss.resteasy:resteasy-jaxb-provider:jar:2.3.7.Final:compile
[INFO] |  \- com.sun.xml.bind:jaxb-impl:jar:2.2.4:compile  <--
[INFO] |     \- javax.xml.bind:jaxb-api:jar:2.2.3:compile
[INFO] |        \- javax.xml.stream:stax-api:jar:1.0-2:compile

Thanks!

See also: https://github.com/droolsjbpm/droolsjbpm-integration/commit/0a334410b1c7258c22f8834d4a154cbced9f8da5

Comment 2 Jiri Svitak 2013-11-26 11:10:42 UTC
Thanks Marco,

You are correct. There were changes in dependencies hidden to my sight. I have changed my dependency management to use jbpm bom to fix the issue:
http://git.app.eng.bos.redhat.com/jbossqe-process-flood.git/commit/?id=a933096c753d5733b6c589d884c5f711488a9495

Now it works. Closing the BZ.


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