Details
-
Type:
Bug
-
Status: Closed (View Workflow)
-
Priority:
Major
-
Resolution: Done
-
Affects Version/s: 0.1
-
Fix Version/s: 0.2
-
Component/s: core
-
Labels:None
-
Estimated Difficulty:Low
-
Git Pull Request:
Description
See the snippet of the configuration
<service name="ErrorService1" promote="ErrorService">
<binding.soap xmlns="urn:switchyard-component-soap:config:1.0">
<wsdl>wsdl/ErrorService.wsdl</wsdl>
<serverPort>9090</serverPort>
<serverHost>10.34.3.135</serverHost>
</binding.soap>
</service>
<component name="ErrorService">
<service name="ErrorService">
<interface.java interface="org.swi.ErrorService"/>
</service>
<implementation.bean xmlns="urn:switchyard-component-bean:config:1.0" class="org.swi.ErrorServiceBean"/>
</component>
Such configuration throws NPE - the only reason is that the gateway is named ServiceName1. It seems that promote attribute is not taken into consideration.
If if this not a correct configuration then an error should be reported instead of NPE
12:46:11,968 ERROR [org.jboss.msc.service.fail] (MSC service thread 1-4) MSC00001: Failed to start service jboss.deployment.unit."errhandling.jar".SwitchYardService: org.jboss.msc.service.StartException in service jboss.deployment.unit."errhandling.jar".SwitchYardService: java.lang.NullPointerException
at org.switchyard.as7.extension.services.SwitchYardService.start(SwitchYardService.java:75)
.
.
.
Gliffy Diagrams
Issue Links
- relates to
-
SWITCHYARD-334
Unnecessary service registration if promoted service name same as component service name
-
- Closed
-
Jiri,
Can you please attach a small test case that demonstrates this bug? I cannot reproduce it.
Here's the test case I just wrote, and it ran successfully:
@TestCompositeModel composite = _puller.pull(PROMOTE_XML, getClass());component = compositeService.getComponent();}}Assert.assertNotNull(component);}PROMOTE_XML ==
Thanks,
David