Bug 1312887 - kie-server JSON doesn't work with singleton extra classes
kie-server JSON doesn't work with singleton extra classes
Product: JBoss BRMS Platform 6
Classification: JBoss
Component: Kie-Server (Show other bugs)
Unspecified Unspecified
medium Severity unspecified
: ER1
: 6.3.0
Assigned To: Maciej Swiderski
Karel Suta
Depends On:
  Show dependency treegraph
Reported: 2016-02-29 07:52 EST by Tomas Schlosser
Modified: 2016-03-21 07:38 EDT (History)
0 users

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Last Closed:
Type: Bug
Regression: ---
Mount Type: ---
Documentation: ---
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---

Attachments (Terms of Use)

  None (edit)
Description Tomas Schlosser 2016-02-29 07:52:03 EST
Description of problem:
Using a code like this:
KieServicesConfiguration config = createJmsConfiguration();
RuleServicesClient rules;
rules.executeCommands("testContainer", commands.newBatchExecution(commandList));

Throws unsupported operation exception:
java.lang.UnsupportedOperationException: null
	at java.util.AbstractCollection.add(AbstractCollection.java:262)
	at org.kie.server.api.marshalling.json.JSONMarshaller.<init>(JSONMarshaller.java:69)
	at org.kie.server.api.marshalling.MarshallerFactory.getMarshaller(MarshallerFactory.java:41)
	at org.kie.server.client.impl.AbstractKieServicesClientImpl.<init>(AbstractKieServicesClientImpl.java:72)
	at org.kie.server.client.impl.KieServicesClientImpl.<init>(KieServicesClientImpl.java:60)
	at org.kie.server.client.KieServicesFactory.newKieServicesClient(KieServicesFactory.java:93)
	at com.redhat.xpaas.brms.transport.TransportTest.evaluateRules(TransportTest.java:249)
	at com.redhat.xpaas.brms.transport.TransportTest.testRestJson(TransportTest.java:144)

Version-Release number of selected component (if applicable):
kie-server-api 6.3.0.Final.redhat-1

How reproducible:

Additional info:
The problem is in JSONMarshaller:69 when the passed set is singleton/unmodifiable instance.
Comment 5 Karel Suta 2016-03-21 07:38:39 EDT
Verified in 6.3.0 ER1

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