[ https://issues.apache.org/jira/browse/TUSCANY-2252?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12591242#action_12591242 ]
Ramkumar Ramalingam commented on TUSCANY-2252: ---------------------------------------------- By removing the declared exception from destroyNode() method in org.apache.tuscany.sca.node.management.SCANodeManagerService.java interface with @OneWay annotation, we might also need to reflect the same change in org.apache.tuscany.sca.node.management.impl.SCANodeManagerServiceImpl.java > Remove exception declaration from SCANodeManagerService Interface > ----------------------------------------------------------------- > > Key: TUSCANY-2252 > URL: https://issues.apache.org/jira/browse/TUSCANY-2252 > Project: Tuscany > Issue Type: Bug > Components: Java SCA Domain Management > Affects Versions: Java-SCA-Next > Reporter: Ramkumar Ramalingam > Assignee: Ramkumar Ramalingam > Fix For: Java-SCA-Next > > > org.apache.tuscany.sca.node.NodeException: > org.apache.tuscany.sca.interfacedef.InvalidOperationException: Method should > not declare exceptions with an @OneWay annotation. > at > org.apache.tuscany.sca.node.impl.SCANodeImpl.init(SCANodeImpl.java:222) > at > org.apache.tuscany.sca.node.impl.SCANodeImpl.<init>(SCANodeImpl.java:128) > at > org.apache.tuscany.sca.node.impl.SCANodeFactoryImpl.createSCANode(SCANodeFactoryImpl.java:54) > at > org.apache.tuscany.sca.node.impl.NodeDrivenTestCase.init(NodeDrivenTestCase.java:72) > at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) > at > sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:64) > at > sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) > at java.lang.reflect.Method.invoke(Method.java:615) > at > org.junit.internal.runners.BeforeAndAfterRunner.invokeMethod(BeforeAndAfterRunner.java:74) > at > org.junit.internal.runners.BeforeAndAfterRunner.runBefores(BeforeAndAfterRunner.java:50) > at > org.junit.internal.runners.BeforeAndAfterRunner.runProtected(BeforeAndAfterRunner.java:33) > at > org.junit.internal.runners.TestClassRunner.run(TestClassRunner.java:52) > at > org.apache.maven.surefire.junit4.JUnit4TestSet.execute(JUnit4TestSet.java:62) > at > org.apache.maven.surefire.suite.AbstractDirectoryTestSuite.executeTestSet(AbstractDirectoryTestSuite.java:138) > at > org.apache.maven.surefire.suite.AbstractDirectoryTestSuite.execute(AbstractDirectoryTestSuite.java:125) > at org.apache.maven.surefire.Surefire.run(Surefire.java:132) > at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) > at > sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:64) > at > sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43) > at java.lang.reflect.Method.invoke(Method.java:615) > at > org.apache.maven.surefire.booter.SurefireBooter.runSuitesInProcess(SurefireBooter.java:308) > at > org.apache.maven.surefire.booter.SurefireBooter.main(SurefireBooter.java:879) > > DomainDrivenTestCase fails with the above exception as we have a > destroyNode() method in > org.apache.tuscany.sca.node.management.SCANodeManagerService.java interface > with @OneWay annotation, but declared to throw NodeException. > > As per the specs, "Any method that returns "void" and has no declared > exceptions may be marked with an @OneWay annotation." > > I am raising this JIRA to fix this issue by making the destroyNode() method > not to throw any exception. -- This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online.