You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@tuscany.apache.org by Ignacio Silva-Lepe <is...@verizon.net> on 2006/09/29 23:08:09 UTC
NoClassDefFoundError, apparently in Axis2
I am trying to run the hellowordwsclient sample by changing the bound reference to use an interface.java, with which it runs ok. But if I then add a callbackInterface I get the error below.
By using a callbackInterface, an Axis2AsyncTargetInvoker is chosen that calls Axis2's operationClient.execute(false), i.e. non-blocking. Without the callbackInterface an Axis2TargetInvoker is chosen which calls operationClient.execute(true). So it seems as if trying to using a non-blocking operation client execute triggers the error.
I have to wonder whether this may be an Axis2 dependency that has not been set up.
Any ideas?
-------------------------------------------------------
T E S T S
-------------------------------------------------------
Running helloworld.HelloWorldWSClientTestCase
log4j:WARN No appenders could be found for logger (org.apache.axiom.om.util.StAX
Utils).
log4j:WARN Please initialize the log4j system properly.
org.apache.tuscany.spi.wire.InvocationRuntimeException: java.lang.NoClassDefFoun
dError: edu/emory/mathcs/backport/java/util/concurrent/BlockingQueue
at org.apache.tuscany.core.databinding.impl.DataBindingInteceptor.invoke
(DataBindingInteceptor.java:76)
at org.apache.tuscany.core.wire.BridgingInterceptor.invoke(BridgingInter
ceptor.java:41)
at org.apache.tuscany.core.databinding.impl.DataBindingInteceptor.invoke
(DataBindingInteceptor.java:71)
at org.apache.tuscany.core.wire.AbstractOutboundInvocationHandler.invoke
(AbstractOutboundInvocationHandler.java:65)
at org.apache.tuscany.core.wire.jdk.JDKOutboundInvocationHandler.invoke(
JDKOutboundInvocationHandler.java:121)
at $Proxy20.getGreetings(Unknown Source)
at helloworld.HelloWorldServiceComponent.getGreetings(HelloWorldServiceC
omponent.java:39)
at helloworld.HelloWorldWSClientTestCase.testWSClient(HelloWorldWSClient
TestCase.java:43)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.
java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAcces
sorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:585)
at junit.framework.TestCase.runTest(TestCase.java:154)
at junit.framework.TestCase.runBare(TestCase.java:127)
at junit.framework.TestResult$1.protect(TestResult.java:106)
at junit.framework.TestResult.runProtected(TestResult.java:124)
at junit.framework.TestResult.run(TestResult.java:109)
at junit.framework.TestCase.run(TestCase.java:118)
at junit.framework.TestSuite.runTest(TestSuite.java:208)
at junit.framework.TestSuite.run(TestSuite.java:203)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.
java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAcces
sorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:585)
at org.apache.maven.surefire.junit.JUnitTestSet.execute(JUnitTestSet.jav
a:210)
at org.apache.maven.surefire.suite.AbstractDirectoryTestSuite.executeTes
tSet(AbstractDirectoryTestSuite.java:135)
at org.apache.maven.surefire.suite.AbstractDirectoryTestSuite.execute(Ab
stractDirectoryTestSuite.java:122)
at org.apache.maven.surefire.Surefire.run(Surefire.java:129)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.
java:39)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAcces
sorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:585)
at org.apache.maven.surefire.booter.SurefireBooter.runSuitesInProcess(Su
refireBooter.java:269)
at org.apache.maven.surefire.booter.SurefireBooter.main(SurefireBooter.j
ava:788)
Caused by: java.lang.NoClassDefFoundError: edu/emory/mathcs/backport/java/util/c
oncurrent/BlockingQueue
at org.apache.axis2.context.ConfigurationContext.getThreadPool(Configura
tionContext.java:296)
at org.apache.axis2.description.OutInAxisOperationClient.execute(OutInAx
isOperation.java:306)
at org.apache.tuscany.binding.axis2.Axis2AsyncTargetInvoker.invokeTarget
(Axis2AsyncTargetInvoker.java:58)
at org.apache.tuscany.binding.axis2.Axis2AsyncTargetInvoker.invoke(Axis2
AsyncTargetInvoker.java:70)
at org.apache.tuscany.core.wire.InvokerInterceptor.invoke(InvokerInterce
ptor.java:44)
at org.apache.tuscany.core.databinding.impl.DataBindingInteceptor.invoke
(DataBindingInteceptor.java:71)
... 33 more
Tests run: 1, Failures: 0, Errors: 1, Skipped: 0, Time elapsed: 3.032 sec <<< FA
ILURE!
Results :
Tests in error:
testWSClient(helloworld.HelloWorldWSClientTestCase)
Tests run: 1, Failures: 0, Errors: 1, Skipped: 0
Re: NoClassDefFoundError, apparently in Axis2
Posted by Raymond Feng <en...@gmail.com>.
Hi, Ignacio.
I think the "helloworldwsclient" callback test case is different than the
"business" callback cases covered by the SCA spec.
For bidirectional interfaces, the initiator of the callback is in the
business logic (with the help of the container to inject the callback proxy
based on @Callback annotationd) and no system level correlation is required.
But in your case, the sequence is "comp1.ref --> composte.ref (w/ axis2
binding which supports async WS invocations) --> Axis2 async client -->
SOAP/HTTP". The Web Service invocation is made asynchronously and the
reponse will come later to trigger the callback. The initiator of the
callback is the reference with Axis2 binding (OMElement representation for
the previous reponse) and the system has to correlate the previous operation
to a matching callback operation whose input type is compatible with the
output type of the original operation. I don't think the SCA spec talks
about this case, i.e., references or services with bindings capable of
asynchronous communications.
Thanks,
Raymond
----- Original Message -----
From: "Ignacio Silva-Lepe" <is...@verizon.net>
To: <tu...@ws.apache.org>
Sent: Saturday, September 30, 2006 7:07 AM
Subject: Re: NoClassDefFoundError, apparently in Axis2
> Some more thoughts on this.
>
> The specs (assembly and C&I) do not seem to be very explicit about what
> should happen with an interface that is annotated as @Callback and that
> defines more than one method. But notice that if this is the case then the
> next question pertains to a previous question, which is what happens when
> the callback interface (the one in the annotation, not the annotated one)
> has more than one method.
>
> Let i1 be an intrerface annotated with @Callback(c1), where c1 is the
> callback interface. The simplest case is when both i1 and c1 have only one
> method. If i1 has > 1 methods there are two cases: c1 has only one method,
> and c1 has > 1 methods. The first case is the case at hand. Notice that
> one last case is where i1 has one method and c1 has > 1, but that really
> is a special case of the second case.
>
> The second case is the one we had asked about before, how do we associate
> methods in c1 with methods in i1. Again, the specs are not explicit about
> this. In general, this association may require knowledge about the
> implementation of i1. That is, i1Impl will get an injected instance of c1
> which then it will use in its method(s) to make callback invocations.
> Which c1 method is invoked in i1 is arbitrary and we may have to resort to
> non-trivial introspection to figure it out. Btw, nontice that this case
> also includes the first case.
>
> So it seems we have a choice of how to interpret the specs.
> 1- The simplest choice is to assume i1 and c1 both have only one method.
> 2- We can assume that c1 has only one method (case at hand) and introspect
> each method in i1 to figure out which is intended as async with callback
> and which is not. In addition, here we also have a choice of whether to
> treat non-callback methods as sync or async.
> 3- We can try go for the general case.
>
> My vote is to go with choice 1, which is what I have been assuming so far,
> at least for the coming release. And if we don't feel comfortable with
> this choice long term, then we can try for choice 2 or maybe even choice
> 3, if we can make sense of it.
> It would also be useful to try to go back to the spec collaboration to try
> to calrify the intent.
>
> Thoughts?
>
> ----- Original Message -----
> From: "Ignacio Silva-Lepe" <is...@verizon.net>
> To: <tu...@ws.apache.org>
> Sent: Friday, September 29, 2006 8:58 PM
> Subject: Re: NoClassDefFoundError, apparently in Axis2
>
>
>> Yeah, one option could be to assume that if an interface is annotated as
>> having a callback, then all of its methods need to be one-way.
>> Alternatively, we may need to introspect each method. If a method has a
>> return value then it follows that it does not have a callback. But does
>> it get invoked asynchronously?
>>
>> For now the sample could be tweaked further, or perhaps separated into a
>> new sample, which I was trying to avoid.
>>
>> ----- Original Message -----
>> From: "Raymond Feng" <en...@gmail.com>
>> To: <tu...@ws.apache.org>
>> Sent: Friday, September 29, 2006 6:51 PM
>> Subject: Re: NoClassDefFoundError, apparently in Axis2
>>
>>> Hi, Ignacio.
>>>
>>> I can now reach a point that we use the Axis2 client to invokes the WS
>>> asynchronously (operationClient.invoke(false)) but it fails after that
>>> because the DataBindingInterceptor excepts a synchronous response but a
>>> "ImmutableMessage" is returned instead. So the question is that how do
>>> we tell if a given operation is invoked asynchronously or not.
>>>
>>> For the test case, we have the following interface:
>>>
>>> @Callback(HelloWorldCallback.class)
>>> public interface HelloWorldService {
>>> public String getGreetings(String name);
>>>
>>> @DataType(name="commonj.sdo.DataObject")
>>> public String getGreetings1(DataObject name);
>>>
>>> public void getGreetingsWithCallback(String name);
>>> }
>>>
>>> It seems that getGreetings(...) goes to the async path in my debugging.
>>>
>>> Please help me understand here.
>>>
>>> Thanks,
>>> Raymond
>>>
>>>
>>> ----- Original Message -----
>>> From: "Ignacio Silva-Lepe" <is...@verizon.net>
>>> To: "Tuscany Dev" <tu...@ws.apache.org>
>>> Sent: Friday, September 29, 2006 2:08 PM
>>> Subject: NoClassDefFoundError, apparently in Axis2
>>>
>>>
>>> I am trying to run the hellowordwsclient sample by changing the bound
>>> reference to use an interface.java, with which it runs ok. But if I then
>>> add a callbackInterface I get the error below.
>>> By using a callbackInterface, an Axis2AsyncTargetInvoker is chosen that
>>> calls Axis2's operationClient.execute(false), i.e. non-blocking. Without
>>> the callbackInterface an Axis2TargetInvoker is chosen which calls
>>> operationClient.execute(true). So it seems as if trying to using a
>>> non-blocking operation client execute triggers the error.
>>> I have to wonder whether this may be an Axis2 dependency that has not
>>> been set up.
>>> Any ideas?
>>>
>>> -------------------------------------------------------
>>> T E S T S
>>> -------------------------------------------------------
>>> Running helloworld.HelloWorldWSClientTestCase
>>> log4j:WARN No appenders could be found for logger
>>> (org.apache.axiom.om.util.StAX
>>> Utils).
>>> log4j:WARN Please initialize the log4j system properly.
>>> org.apache.tuscany.spi.wire.InvocationRuntimeException:
>>> java.lang.NoClassDefFoun
>>> dError: edu/emory/mathcs/backport/java/util/concurrent/BlockingQueue
>>> at
>>> org.apache.tuscany.core.databinding.impl.DataBindingInteceptor.invoke
>>> (DataBindingInteceptor.java:76)
>>> at
>>> org.apache.tuscany.core.wire.BridgingInterceptor.invoke(BridgingInter
>>> ceptor.java:41)
>>> at
>>> org.apache.tuscany.core.databinding.impl.DataBindingInteceptor.invoke
>>> (DataBindingInteceptor.java:71)
>>> at
>>> org.apache.tuscany.core.wire.AbstractOutboundInvocationHandler.invoke
>>> (AbstractOutboundInvocationHandler.java:65)
>>> at
>>> org.apache.tuscany.core.wire.jdk.JDKOutboundInvocationHandler.invoke(
>>> JDKOutboundInvocationHandler.java:121)
>>> at $Proxy20.getGreetings(Unknown Source)
>>> at
>>> helloworld.HelloWorldServiceComponent.getGreetings(HelloWorldServiceC
>>> omponent.java:39)
>>> at
>>> helloworld.HelloWorldWSClientTestCase.testWSClient(HelloWorldWSClient
>>> TestCase.java:43)
>>> at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
>>> at
>>> sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.
>>> java:39)
>>> at
>>> sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAcces
>>> sorImpl.java:25)
>>> at java.lang.reflect.Method.invoke(Method.java:585)
>>> at junit.framework.TestCase.runTest(TestCase.java:154)
>>> at junit.framework.TestCase.runBare(TestCase.java:127)
>>> at junit.framework.TestResult$1.protect(TestResult.java:106)
>>> at junit.framework.TestResult.runProtected(TestResult.java:124)
>>> at junit.framework.TestResult.run(TestResult.java:109)
>>> at junit.framework.TestCase.run(TestCase.java:118)
>>> at junit.framework.TestSuite.runTest(TestSuite.java:208)
>>> at junit.framework.TestSuite.run(TestSuite.java:203)
>>> at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
>>> at
>>> sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.
>>> java:39)
>>> at
>>> sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAcces
>>> sorImpl.java:25)
>>> at java.lang.reflect.Method.invoke(Method.java:585)
>>> at
>>> org.apache.maven.surefire.junit.JUnitTestSet.execute(JUnitTestSet.jav
>>> a:210)
>>> at
>>> org.apache.maven.surefire.suite.AbstractDirectoryTestSuite.executeTes
>>> tSet(AbstractDirectoryTestSuite.java:135)
>>> at
>>> org.apache.maven.surefire.suite.AbstractDirectoryTestSuite.execute(Ab
>>> stractDirectoryTestSuite.java:122)
>>> at org.apache.maven.surefire.Surefire.run(Surefire.java:129)
>>> at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
>>> at
>>> sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.
>>> java:39)
>>> at
>>> sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAcces
>>> sorImpl.java:25)
>>> at java.lang.reflect.Method.invoke(Method.java:585)
>>> at
>>> org.apache.maven.surefire.booter.SurefireBooter.runSuitesInProcess(Su
>>> refireBooter.java:269)
>>> at
>>> org.apache.maven.surefire.booter.SurefireBooter.main(SurefireBooter.j
>>> ava:788)
>>> Caused by: java.lang.NoClassDefFoundError:
>>> edu/emory/mathcs/backport/java/util/c
>>> oncurrent/BlockingQueue
>>> at
>>> org.apache.axis2.context.ConfigurationContext.getThreadPool(Configura
>>> tionContext.java:296)
>>> at
>>> org.apache.axis2.description.OutInAxisOperationClient.execute(OutInAx
>>> isOperation.java:306)
>>> at
>>> org.apache.tuscany.binding.axis2.Axis2AsyncTargetInvoker.invokeTarget
>>> (Axis2AsyncTargetInvoker.java:58)
>>> at
>>> org.apache.tuscany.binding.axis2.Axis2AsyncTargetInvoker.invoke(Axis2
>>> AsyncTargetInvoker.java:70)
>>> at
>>> org.apache.tuscany.core.wire.InvokerInterceptor.invoke(InvokerInterce
>>> ptor.java:44)
>>> at
>>> org.apache.tuscany.core.databinding.impl.DataBindingInteceptor.invoke
>>> (DataBindingInteceptor.java:71)
>>> ... 33 more
>>> Tests run: 1, Failures: 0, Errors: 1, Skipped: 0, Time elapsed: 3.032
>>> sec <<< FA
>>> ILURE!
>>>
>>> Results :
>>>
>>> Tests in error:
>>> testWSClient(helloworld.HelloWorldWSClientTestCase)
>>>
>>> Tests run: 1, Failures: 0, Errors: 1, Skipped: 0
>>>
>>> ---------------------------------------------------------------------
>>> To unsubscribe, e-mail: tuscany-dev-unsubscribe@ws.apache.org
>>> For additional commands, e-mail: tuscany-dev-help@ws.apache.org
>>>
>>>
>>
>>
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: tuscany-dev-unsubscribe@ws.apache.org
>> For additional commands, e-mail: tuscany-dev-help@ws.apache.org
>>
>>
>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: tuscany-dev-unsubscribe@ws.apache.org
> For additional commands, e-mail: tuscany-dev-help@ws.apache.org
>
---------------------------------------------------------------------
To unsubscribe, e-mail: tuscany-dev-unsubscribe@ws.apache.org
For additional commands, e-mail: tuscany-dev-help@ws.apache.org
Associating callback methods, was Re: NoClassDefFoundError,
apparently in Axis2
Posted by Ignacio Silva-Lepe <is...@verizon.net>.
Yeah, actually, for components that are directly wired this is not really a
problem. But for a component that is invoked remotely via a binding, this is
a problem for the current architecture. In particular, without a more or
less explicit association of callback methods, it does not seem to be
possible to statically setup target invokers on the invocation chains for
the outbound wire on a bound reference, e.g., Axis2Reference.
We will probably depend on dynamic information to be conveyed by a response
message, and then use this info to complete the wiring and connection setup.
For instance, with Axis2 we'll need to carry an indicator of what callback
method was invoked, with the Tuscany infrastructure needing to unpack this
info to perform the association. Notice that a correlation id does not
suffice as it only indicates an association between the response and request
messages
This can have interop ramifications if we want to allow a component with an
Axis2-bound reference to invoke an arbitrary implementation of the
corresponding web service. And this is just considering Axis2, other
bindings are bound to have similar issues (pun not intended ... maybe ;-)
----- Original Message -----
From: "scabooz" <sc...@gmail.com>
To: <tu...@ws.apache.org>
Sent: Saturday, September 30, 2006 10:54 AM
Subject: Re: NoClassDefFoundError, apparently in Axis2
> FWIW, This is an area of the specs that are under discussion, and this
> exact point has been raised. The following assumes that conversational
> support is out of scope of this thread of discussion. However, it does
> have effect on the use cases in the end.
>
> The intention in the current specs is that there is no relationship
> between
> i1 and c1 operations. The spec is open enough to allow the consumer
> to invoke i1 operations independently from the service provider invoking
> c1 operations. I think this is a 4th case that you haven't even listed
> yet.
> Therefore, if the designer of the service wants to build in a relationship
> between i1 operations and c1 operations, they are free to do that, but
> the SCA runtime is not aware of it. Such a relationship would be
> documented in an appropriate out of band mechanism. An example
> of such a relationship is the idea that a callback invocation carries a
> response from a previous i1 invocation by the consumer. It's only the
> business logic in the callback service that knows this. I think this is
> your
> case3.
>
>
> Dave Booz
>
> ----- Original Message -----
> From: "Ignacio Silva-Lepe" <is...@verizon.net>
> To: <tu...@ws.apache.org>
> Sent: Saturday, September 30, 2006 10:07 AM
> Subject: Re: NoClassDefFoundError, apparently in Axis2
>
>
>> Some more thoughts on this.
>>
>> The specs (assembly and C&I) do not seem to be very explicit about what
>> should happen with an interface that is annotated as @Callback and that
>> defines more than one method. But notice that if this is the case then
>> the next question pertains to a previous question, which is what happens
>> when the callback interface (the one in the annotation, not the annotated
>> one) has more than one method.
>>
>> Let i1 be an intrerface annotated with @Callback(c1), where c1 is the
>> callback interface. The simplest case is when both i1 and c1 have only
>> one method. If i1 has > 1 methods there are two cases: c1 has only one
>> method, and c1 has > 1 methods. The first case is the case at hand.
>> Notice that one last case is where i1 has one method and c1 has > 1, but
>> that really is a special case of the second case.
>>
>> The second case is the one we had asked about before, how do we associate
>> methods in c1 with methods in i1. Again, the specs are not explicit about
>> this. In general, this association may require knowledge about the
>> implementation of i1. That is, i1Impl will get an injected instance of c1
>> which then it will use in its method(s) to make callback invocations.
>> Which c1 method is invoked in i1 is arbitrary and we may have to resort
>> to non-trivial introspection to figure it out. Btw, nontice that this
>> case also includes the first case.
>>
>> So it seems we have a choice of how to interpret the specs.
>> 1- The simplest choice is to assume i1 and c1 both have only one method.
>> 2- We can assume that c1 has only one method (case at hand) and
>> introspect each method in i1 to figure out which is intended as async
>> with callback and which is not. In addition, here we also have a choice
>> of whether to treat non-callback methods as sync or async.
>> 3- We can try go for the general case.
>>
>> My vote is to go with choice 1, which is what I have been assuming so
>> far, at least for the coming release. And if we don't feel comfortable
>> with this choice long term, then we can try for choice 2 or maybe even
>> choice 3, if we can make sense of it.
>> It would also be useful to try to go back to the spec collaboration to
>> try to calrify the intent.
>>
>> Thoughts?
---------------------------------------------------------------------
To unsubscribe, e-mail: tuscany-dev-unsubscribe@ws.apache.org
For additional commands, e-mail: tuscany-dev-help@ws.apache.org
Re: NoClassDefFoundError, apparently in Axis2
Posted by scabooz <sc...@gmail.com>.
FWIW, This is an area of the specs that are under discussion, and this
exact point has been raised. The following assumes that conversational
support is out of scope of this thread of discussion. However, it does
have effect on the use cases in the end.
The intention in the current specs is that there is no relationship between
i1 and c1 operations. The spec is open enough to allow the consumer
to invoke i1 operations independently from the service provider invoking
c1 operations. I think this is a 4th case that you haven't even listed yet.
Therefore, if the designer of the service wants to build in a relationship
between i1 operations and c1 operations, they are free to do that, but
the SCA runtime is not aware of it. Such a relationship would be
documented in an appropriate out of band mechanism. An example
of such a relationship is the idea that a callback invocation carries a
response from a previous i1 invocation by the consumer. It's only the
business logic in the callback service that knows this. I think this is your
case3.
Dave Booz
----- Original Message -----
From: "Ignacio Silva-Lepe" <is...@verizon.net>
To: <tu...@ws.apache.org>
Sent: Saturday, September 30, 2006 10:07 AM
Subject: Re: NoClassDefFoundError, apparently in Axis2
> Some more thoughts on this.
>
> The specs (assembly and C&I) do not seem to be very explicit about what
> should happen with an interface that is annotated as @Callback and that
> defines more than one method. But notice that if this is the case then the
> next question pertains to a previous question, which is what happens when
> the callback interface (the one in the annotation, not the annotated one)
> has more than one method.
>
> Let i1 be an intrerface annotated with @Callback(c1), where c1 is the
> callback interface. The simplest case is when both i1 and c1 have only one
> method. If i1 has > 1 methods there are two cases: c1 has only one method,
> and c1 has > 1 methods. The first case is the case at hand. Notice that
> one last case is where i1 has one method and c1 has > 1, but that really
> is a special case of the second case.
>
> The second case is the one we had asked about before, how do we associate
> methods in c1 with methods in i1. Again, the specs are not explicit about
> this. In general, this association may require knowledge about the
> implementation of i1. That is, i1Impl will get an injected instance of c1
> which then it will use in its method(s) to make callback invocations.
> Which c1 method is invoked in i1 is arbitrary and we may have to resort to
> non-trivial introspection to figure it out. Btw, nontice that this case
> also includes the first case.
>
> So it seems we have a choice of how to interpret the specs.
> 1- The simplest choice is to assume i1 and c1 both have only one method.
> 2- We can assume that c1 has only one method (case at hand) and introspect
> each method in i1 to figure out which is intended as async with callback
> and which is not. In addition, here we also have a choice of whether to
> treat non-callback methods as sync or async.
> 3- We can try go for the general case.
>
> My vote is to go with choice 1, which is what I have been assuming so far,
> at least for the coming release. And if we don't feel comfortable with
> this choice long term, then we can try for choice 2 or maybe even choice
> 3, if we can make sense of it.
> It would also be useful to try to go back to the spec collaboration to try
> to calrify the intent.
>
> Thoughts?
>
> ----- Original Message -----
> From: "Ignacio Silva-Lepe" <is...@verizon.net>
> To: <tu...@ws.apache.org>
> Sent: Friday, September 29, 2006 8:58 PM
> Subject: Re: NoClassDefFoundError, apparently in Axis2
>
>
>> Yeah, one option could be to assume that if an interface is annotated as
>> having a callback, then all of its methods need to be one-way.
>> Alternatively, we may need to introspect each method. If a method has a
>> return value then it follows that it does not have a callback. But does
>> it get invoked asynchronously?
>>
>> For now the sample could be tweaked further, or perhaps separated into a
>> new sample, which I was trying to avoid.
>>
>> ----- Original Message -----
>> From: "Raymond Feng" <en...@gmail.com>
>> To: <tu...@ws.apache.org>
>> Sent: Friday, September 29, 2006 6:51 PM
>> Subject: Re: NoClassDefFoundError, apparently in Axis2
>>
>>> Hi, Ignacio.
>>>
>>> I can now reach a point that we use the Axis2 client to invokes the WS
>>> asynchronously (operationClient.invoke(false)) but it fails after that
>>> because the DataBindingInterceptor excepts a synchronous response but a
>>> "ImmutableMessage" is returned instead. So the question is that how do
>>> we tell if a given operation is invoked asynchronously or not.
>>>
>>> For the test case, we have the following interface:
>>>
>>> @Callback(HelloWorldCallback.class)
>>> public interface HelloWorldService {
>>> public String getGreetings(String name);
>>>
>>> @DataType(name="commonj.sdo.DataObject")
>>> public String getGreetings1(DataObject name);
>>>
>>> public void getGreetingsWithCallback(String name);
>>> }
>>>
>>> It seems that getGreetings(...) goes to the async path in my debugging.
>>>
>>> Please help me understand here.
>>>
>>> Thanks,
>>> Raymond
>>>
>>>
>>> ----- Original Message -----
>>> From: "Ignacio Silva-Lepe" <is...@verizon.net>
>>> To: "Tuscany Dev" <tu...@ws.apache.org>
>>> Sent: Friday, September 29, 2006 2:08 PM
>>> Subject: NoClassDefFoundError, apparently in Axis2
>>>
>>>
>>> I am trying to run the hellowordwsclient sample by changing the bound
>>> reference to use an interface.java, with which it runs ok. But if I then
>>> add a callbackInterface I get the error below.
>>> By using a callbackInterface, an Axis2AsyncTargetInvoker is chosen that
>>> calls Axis2's operationClient.execute(false), i.e. non-blocking. Without
>>> the callbackInterface an Axis2TargetInvoker is chosen which calls
>>> operationClient.execute(true). So it seems as if trying to using a
>>> non-blocking operation client execute triggers the error.
>>> I have to wonder whether this may be an Axis2 dependency that has not
>>> been set up.
>>> Any ideas?
>>>
>>> -------------------------------------------------------
>>> T E S T S
>>> -------------------------------------------------------
>>> Running helloworld.HelloWorldWSClientTestCase
>>> log4j:WARN No appenders could be found for logger
>>> (org.apache.axiom.om.util.StAX
>>> Utils).
>>> log4j:WARN Please initialize the log4j system properly.
>>> org.apache.tuscany.spi.wire.InvocationRuntimeException:
>>> java.lang.NoClassDefFoun
>>> dError: edu/emory/mathcs/backport/java/util/concurrent/BlockingQueue
>>> at
>>> org.apache.tuscany.core.databinding.impl.DataBindingInteceptor.invoke
>>> (DataBindingInteceptor.java:76)
>>> at
>>> org.apache.tuscany.core.wire.BridgingInterceptor.invoke(BridgingInter
>>> ceptor.java:41)
>>> at
>>> org.apache.tuscany.core.databinding.impl.DataBindingInteceptor.invoke
>>> (DataBindingInteceptor.java:71)
>>> at
>>> org.apache.tuscany.core.wire.AbstractOutboundInvocationHandler.invoke
>>> (AbstractOutboundInvocationHandler.java:65)
>>> at
>>> org.apache.tuscany.core.wire.jdk.JDKOutboundInvocationHandler.invoke(
>>> JDKOutboundInvocationHandler.java:121)
>>> at $Proxy20.getGreetings(Unknown Source)
>>> at
>>> helloworld.HelloWorldServiceComponent.getGreetings(HelloWorldServiceC
>>> omponent.java:39)
>>> at
>>> helloworld.HelloWorldWSClientTestCase.testWSClient(HelloWorldWSClient
>>> TestCase.java:43)
>>> at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
>>> at
>>> sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.
>>> java:39)
>>> at
>>> sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAcces
>>> sorImpl.java:25)
>>> at java.lang.reflect.Method.invoke(Method.java:585)
>>> at junit.framework.TestCase.runTest(TestCase.java:154)
>>> at junit.framework.TestCase.runBare(TestCase.java:127)
>>> at junit.framework.TestResult$1.protect(TestResult.java:106)
>>> at junit.framework.TestResult.runProtected(TestResult.java:124)
>>> at junit.framework.TestResult.run(TestResult.java:109)
>>> at junit.framework.TestCase.run(TestCase.java:118)
>>> at junit.framework.TestSuite.runTest(TestSuite.java:208)
>>> at junit.framework.TestSuite.run(TestSuite.java:203)
>>> at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
>>> at
>>> sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.
>>> java:39)
>>> at
>>> sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAcces
>>> sorImpl.java:25)
>>> at java.lang.reflect.Method.invoke(Method.java:585)
>>> at
>>> org.apache.maven.surefire.junit.JUnitTestSet.execute(JUnitTestSet.jav
>>> a:210)
>>> at
>>> org.apache.maven.surefire.suite.AbstractDirectoryTestSuite.executeTes
>>> tSet(AbstractDirectoryTestSuite.java:135)
>>> at
>>> org.apache.maven.surefire.suite.AbstractDirectoryTestSuite.execute(Ab
>>> stractDirectoryTestSuite.java:122)
>>> at org.apache.maven.surefire.Surefire.run(Surefire.java:129)
>>> at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
>>> at
>>> sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.
>>> java:39)
>>> at
>>> sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAcces
>>> sorImpl.java:25)
>>> at java.lang.reflect.Method.invoke(Method.java:585)
>>> at
>>> org.apache.maven.surefire.booter.SurefireBooter.runSuitesInProcess(Su
>>> refireBooter.java:269)
>>> at
>>> org.apache.maven.surefire.booter.SurefireBooter.main(SurefireBooter.j
>>> ava:788)
>>> Caused by: java.lang.NoClassDefFoundError:
>>> edu/emory/mathcs/backport/java/util/c
>>> oncurrent/BlockingQueue
>>> at
>>> org.apache.axis2.context.ConfigurationContext.getThreadPool(Configura
>>> tionContext.java:296)
>>> at
>>> org.apache.axis2.description.OutInAxisOperationClient.execute(OutInAx
>>> isOperation.java:306)
>>> at
>>> org.apache.tuscany.binding.axis2.Axis2AsyncTargetInvoker.invokeTarget
>>> (Axis2AsyncTargetInvoker.java:58)
>>> at
>>> org.apache.tuscany.binding.axis2.Axis2AsyncTargetInvoker.invoke(Axis2
>>> AsyncTargetInvoker.java:70)
>>> at
>>> org.apache.tuscany.core.wire.InvokerInterceptor.invoke(InvokerInterce
>>> ptor.java:44)
>>> at
>>> org.apache.tuscany.core.databinding.impl.DataBindingInteceptor.invoke
>>> (DataBindingInteceptor.java:71)
>>> ... 33 more
>>> Tests run: 1, Failures: 0, Errors: 1, Skipped: 0, Time elapsed: 3.032
>>> sec <<< FA
>>> ILURE!
>>>
>>> Results :
>>>
>>> Tests in error:
>>> testWSClient(helloworld.HelloWorldWSClientTestCase)
>>>
>>> Tests run: 1, Failures: 0, Errors: 1, Skipped: 0
>>>
>>> ---------------------------------------------------------------------
>>> To unsubscribe, e-mail: tuscany-dev-unsubscribe@ws.apache.org
>>> For additional commands, e-mail: tuscany-dev-help@ws.apache.org
>>>
>>>
>>
>>
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: tuscany-dev-unsubscribe@ws.apache.org
>> For additional commands, e-mail: tuscany-dev-help@ws.apache.org
>>
>>
>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: tuscany-dev-unsubscribe@ws.apache.org
> For additional commands, e-mail: tuscany-dev-help@ws.apache.org
>
---------------------------------------------------------------------
To unsubscribe, e-mail: tuscany-dev-unsubscribe@ws.apache.org
For additional commands, e-mail: tuscany-dev-help@ws.apache.org
Re: NoClassDefFoundError, apparently in Axis2
Posted by Ignacio Silva-Lepe <is...@verizon.net>.
Some more thoughts on this.
The specs (assembly and C&I) do not seem to be very explicit about what
should happen with an interface that is annotated as @Callback and that
defines more than one method. But notice that if this is the case then the
next question pertains to a previous question, which is what happens when
the callback interface (the one in the annotation, not the annotated one)
has more than one method.
Let i1 be an intrerface annotated with @Callback(c1), where c1 is the
callback interface. The simplest case is when both i1 and c1 have only one
method. If i1 has > 1 methods there are two cases: c1 has only one method,
and c1 has > 1 methods. The first case is the case at hand. Notice that one
last case is where i1 has one method and c1 has > 1, but that really is a
special case of the second case.
The second case is the one we had asked about before, how do we associate
methods in c1 with methods in i1. Again, the specs are not explicit about
this. In general, this association may require knowledge about the
implementation of i1. That is, i1Impl will get an injected instance of c1
which then it will use in its method(s) to make callback invocations. Which
c1 method is invoked in i1 is arbitrary and we may have to resort to
non-trivial introspection to figure it out. Btw, nontice that this case also
includes the first case.
So it seems we have a choice of how to interpret the specs.
1- The simplest choice is to assume i1 and c1 both have only one method.
2- We can assume that c1 has only one method (case at hand) and introspect
each method in i1 to figure out which is intended as async with callback and
which is not. In addition, here we also have a choice of whether to treat
non-callback methods as sync or async.
3- We can try go for the general case.
My vote is to go with choice 1, which is what I have been assuming so far,
at least for the coming release. And if we don't feel comfortable with this
choice long term, then we can try for choice 2 or maybe even choice 3, if we
can make sense of it.
It would also be useful to try to go back to the spec collaboration to try
to calrify the intent.
Thoughts?
----- Original Message -----
From: "Ignacio Silva-Lepe" <is...@verizon.net>
To: <tu...@ws.apache.org>
Sent: Friday, September 29, 2006 8:58 PM
Subject: Re: NoClassDefFoundError, apparently in Axis2
> Yeah, one option could be to assume that if an interface is annotated as
> having a callback, then all of its methods need to be one-way.
> Alternatively, we may need to introspect each method. If a method has a
> return value then it follows that it does not have a callback. But does it
> get invoked asynchronously?
>
> For now the sample could be tweaked further, or perhaps separated into a
> new sample, which I was trying to avoid.
>
> ----- Original Message -----
> From: "Raymond Feng" <en...@gmail.com>
> To: <tu...@ws.apache.org>
> Sent: Friday, September 29, 2006 6:51 PM
> Subject: Re: NoClassDefFoundError, apparently in Axis2
>
>> Hi, Ignacio.
>>
>> I can now reach a point that we use the Axis2 client to invokes the WS
>> asynchronously (operationClient.invoke(false)) but it fails after that
>> because the DataBindingInterceptor excepts a synchronous response but a
>> "ImmutableMessage" is returned instead. So the question is that how do we
>> tell if a given operation is invoked asynchronously or not.
>>
>> For the test case, we have the following interface:
>>
>> @Callback(HelloWorldCallback.class)
>> public interface HelloWorldService {
>> public String getGreetings(String name);
>>
>> @DataType(name="commonj.sdo.DataObject")
>> public String getGreetings1(DataObject name);
>>
>> public void getGreetingsWithCallback(String name);
>> }
>>
>> It seems that getGreetings(...) goes to the async path in my debugging.
>>
>> Please help me understand here.
>>
>> Thanks,
>> Raymond
>>
>>
>> ----- Original Message -----
>> From: "Ignacio Silva-Lepe" <is...@verizon.net>
>> To: "Tuscany Dev" <tu...@ws.apache.org>
>> Sent: Friday, September 29, 2006 2:08 PM
>> Subject: NoClassDefFoundError, apparently in Axis2
>>
>>
>> I am trying to run the hellowordwsclient sample by changing the bound
>> reference to use an interface.java, with which it runs ok. But if I then
>> add a callbackInterface I get the error below.
>> By using a callbackInterface, an Axis2AsyncTargetInvoker is chosen that
>> calls Axis2's operationClient.execute(false), i.e. non-blocking. Without
>> the callbackInterface an Axis2TargetInvoker is chosen which calls
>> operationClient.execute(true). So it seems as if trying to using a
>> non-blocking operation client execute triggers the error.
>> I have to wonder whether this may be an Axis2 dependency that has not
>> been set up.
>> Any ideas?
>>
>> -------------------------------------------------------
>> T E S T S
>> -------------------------------------------------------
>> Running helloworld.HelloWorldWSClientTestCase
>> log4j:WARN No appenders could be found for logger
>> (org.apache.axiom.om.util.StAX
>> Utils).
>> log4j:WARN Please initialize the log4j system properly.
>> org.apache.tuscany.spi.wire.InvocationRuntimeException:
>> java.lang.NoClassDefFoun
>> dError: edu/emory/mathcs/backport/java/util/concurrent/BlockingQueue
>> at
>> org.apache.tuscany.core.databinding.impl.DataBindingInteceptor.invoke
>> (DataBindingInteceptor.java:76)
>> at
>> org.apache.tuscany.core.wire.BridgingInterceptor.invoke(BridgingInter
>> ceptor.java:41)
>> at
>> org.apache.tuscany.core.databinding.impl.DataBindingInteceptor.invoke
>> (DataBindingInteceptor.java:71)
>> at
>> org.apache.tuscany.core.wire.AbstractOutboundInvocationHandler.invoke
>> (AbstractOutboundInvocationHandler.java:65)
>> at
>> org.apache.tuscany.core.wire.jdk.JDKOutboundInvocationHandler.invoke(
>> JDKOutboundInvocationHandler.java:121)
>> at $Proxy20.getGreetings(Unknown Source)
>> at
>> helloworld.HelloWorldServiceComponent.getGreetings(HelloWorldServiceC
>> omponent.java:39)
>> at
>> helloworld.HelloWorldWSClientTestCase.testWSClient(HelloWorldWSClient
>> TestCase.java:43)
>> at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
>> at
>> sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.
>> java:39)
>> at
>> sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAcces
>> sorImpl.java:25)
>> at java.lang.reflect.Method.invoke(Method.java:585)
>> at junit.framework.TestCase.runTest(TestCase.java:154)
>> at junit.framework.TestCase.runBare(TestCase.java:127)
>> at junit.framework.TestResult$1.protect(TestResult.java:106)
>> at junit.framework.TestResult.runProtected(TestResult.java:124)
>> at junit.framework.TestResult.run(TestResult.java:109)
>> at junit.framework.TestCase.run(TestCase.java:118)
>> at junit.framework.TestSuite.runTest(TestSuite.java:208)
>> at junit.framework.TestSuite.run(TestSuite.java:203)
>> at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
>> at
>> sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.
>> java:39)
>> at
>> sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAcces
>> sorImpl.java:25)
>> at java.lang.reflect.Method.invoke(Method.java:585)
>> at
>> org.apache.maven.surefire.junit.JUnitTestSet.execute(JUnitTestSet.jav
>> a:210)
>> at
>> org.apache.maven.surefire.suite.AbstractDirectoryTestSuite.executeTes
>> tSet(AbstractDirectoryTestSuite.java:135)
>> at
>> org.apache.maven.surefire.suite.AbstractDirectoryTestSuite.execute(Ab
>> stractDirectoryTestSuite.java:122)
>> at org.apache.maven.surefire.Surefire.run(Surefire.java:129)
>> at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
>> at
>> sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.
>> java:39)
>> at
>> sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAcces
>> sorImpl.java:25)
>> at java.lang.reflect.Method.invoke(Method.java:585)
>> at
>> org.apache.maven.surefire.booter.SurefireBooter.runSuitesInProcess(Su
>> refireBooter.java:269)
>> at
>> org.apache.maven.surefire.booter.SurefireBooter.main(SurefireBooter.j
>> ava:788)
>> Caused by: java.lang.NoClassDefFoundError:
>> edu/emory/mathcs/backport/java/util/c
>> oncurrent/BlockingQueue
>> at
>> org.apache.axis2.context.ConfigurationContext.getThreadPool(Configura
>> tionContext.java:296)
>> at
>> org.apache.axis2.description.OutInAxisOperationClient.execute(OutInAx
>> isOperation.java:306)
>> at
>> org.apache.tuscany.binding.axis2.Axis2AsyncTargetInvoker.invokeTarget
>> (Axis2AsyncTargetInvoker.java:58)
>> at
>> org.apache.tuscany.binding.axis2.Axis2AsyncTargetInvoker.invoke(Axis2
>> AsyncTargetInvoker.java:70)
>> at
>> org.apache.tuscany.core.wire.InvokerInterceptor.invoke(InvokerInterce
>> ptor.java:44)
>> at
>> org.apache.tuscany.core.databinding.impl.DataBindingInteceptor.invoke
>> (DataBindingInteceptor.java:71)
>> ... 33 more
>> Tests run: 1, Failures: 0, Errors: 1, Skipped: 0, Time elapsed: 3.032 sec
>> <<< FA
>> ILURE!
>>
>> Results :
>>
>> Tests in error:
>> testWSClient(helloworld.HelloWorldWSClientTestCase)
>>
>> Tests run: 1, Failures: 0, Errors: 1, Skipped: 0
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: tuscany-dev-unsubscribe@ws.apache.org
>> For additional commands, e-mail: tuscany-dev-help@ws.apache.org
>>
>>
>
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: tuscany-dev-unsubscribe@ws.apache.org
> For additional commands, e-mail: tuscany-dev-help@ws.apache.org
>
>
---------------------------------------------------------------------
To unsubscribe, e-mail: tuscany-dev-unsubscribe@ws.apache.org
For additional commands, e-mail: tuscany-dev-help@ws.apache.org
Re: NoClassDefFoundError, apparently in Axis2
Posted by Ignacio Silva-Lepe <is...@verizon.net>.
Yeah, one option could be to assume that if an interface is annotated as
having a callback, then all of its methods need to be one-way.
Alternatively, we may need to introspect each method. If a method has a
return value then it follows that it does not have a callback. But does it
get invoked asynchronously?
For now the sample could be tweaked further, or perhaps separated into a new
sample, which I was trying to avoid.
----- Original Message -----
From: "Raymond Feng" <en...@gmail.com>
To: <tu...@ws.apache.org>
Sent: Friday, September 29, 2006 6:51 PM
Subject: Re: NoClassDefFoundError, apparently in Axis2
> Hi, Ignacio.
>
> I can now reach a point that we use the Axis2 client to invokes the WS
> asynchronously (operationClient.invoke(false)) but it fails after that
> because the DataBindingInterceptor excepts a synchronous response but a
> "ImmutableMessage" is returned instead. So the question is that how do we
> tell if a given operation is invoked asynchronously or not.
>
> For the test case, we have the following interface:
>
> @Callback(HelloWorldCallback.class)
> public interface HelloWorldService {
> public String getGreetings(String name);
>
> @DataType(name="commonj.sdo.DataObject")
> public String getGreetings1(DataObject name);
>
> public void getGreetingsWithCallback(String name);
> }
>
> It seems that getGreetings(...) goes to the async path in my debugging.
>
> Please help me understand here.
>
> Thanks,
> Raymond
>
>
> ----- Original Message -----
> From: "Ignacio Silva-Lepe" <is...@verizon.net>
> To: "Tuscany Dev" <tu...@ws.apache.org>
> Sent: Friday, September 29, 2006 2:08 PM
> Subject: NoClassDefFoundError, apparently in Axis2
>
>
> I am trying to run the hellowordwsclient sample by changing the bound
> reference to use an interface.java, with which it runs ok. But if I then
> add a callbackInterface I get the error below.
> By using a callbackInterface, an Axis2AsyncTargetInvoker is chosen that
> calls Axis2's operationClient.execute(false), i.e. non-blocking. Without
> the callbackInterface an Axis2TargetInvoker is chosen which calls
> operationClient.execute(true). So it seems as if trying to using a
> non-blocking operation client execute triggers the error.
> I have to wonder whether this may be an Axis2 dependency that has not been
> set up.
> Any ideas?
>
> -------------------------------------------------------
> T E S T S
> -------------------------------------------------------
> Running helloworld.HelloWorldWSClientTestCase
> log4j:WARN No appenders could be found for logger
> (org.apache.axiom.om.util.StAX
> Utils).
> log4j:WARN Please initialize the log4j system properly.
> org.apache.tuscany.spi.wire.InvocationRuntimeException:
> java.lang.NoClassDefFoun
> dError: edu/emory/mathcs/backport/java/util/concurrent/BlockingQueue
> at
> org.apache.tuscany.core.databinding.impl.DataBindingInteceptor.invoke
> (DataBindingInteceptor.java:76)
> at
> org.apache.tuscany.core.wire.BridgingInterceptor.invoke(BridgingInter
> ceptor.java:41)
> at
> org.apache.tuscany.core.databinding.impl.DataBindingInteceptor.invoke
> (DataBindingInteceptor.java:71)
> at
> org.apache.tuscany.core.wire.AbstractOutboundInvocationHandler.invoke
> (AbstractOutboundInvocationHandler.java:65)
> at
> org.apache.tuscany.core.wire.jdk.JDKOutboundInvocationHandler.invoke(
> JDKOutboundInvocationHandler.java:121)
> at $Proxy20.getGreetings(Unknown Source)
> at
> helloworld.HelloWorldServiceComponent.getGreetings(HelloWorldServiceC
> omponent.java:39)
> at
> helloworld.HelloWorldWSClientTestCase.testWSClient(HelloWorldWSClient
> TestCase.java:43)
> at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
> at
> sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.
> java:39)
> at
> sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAcces
> sorImpl.java:25)
> at java.lang.reflect.Method.invoke(Method.java:585)
> at junit.framework.TestCase.runTest(TestCase.java:154)
> at junit.framework.TestCase.runBare(TestCase.java:127)
> at junit.framework.TestResult$1.protect(TestResult.java:106)
> at junit.framework.TestResult.runProtected(TestResult.java:124)
> at junit.framework.TestResult.run(TestResult.java:109)
> at junit.framework.TestCase.run(TestCase.java:118)
> at junit.framework.TestSuite.runTest(TestSuite.java:208)
> at junit.framework.TestSuite.run(TestSuite.java:203)
> at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
> at
> sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.
> java:39)
> at
> sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAcces
> sorImpl.java:25)
> at java.lang.reflect.Method.invoke(Method.java:585)
> at
> org.apache.maven.surefire.junit.JUnitTestSet.execute(JUnitTestSet.jav
> a:210)
> at
> org.apache.maven.surefire.suite.AbstractDirectoryTestSuite.executeTes
> tSet(AbstractDirectoryTestSuite.java:135)
> at
> org.apache.maven.surefire.suite.AbstractDirectoryTestSuite.execute(Ab
> stractDirectoryTestSuite.java:122)
> at org.apache.maven.surefire.Surefire.run(Surefire.java:129)
> at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
> at
> sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.
> java:39)
> at
> sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAcces
> sorImpl.java:25)
> at java.lang.reflect.Method.invoke(Method.java:585)
> at
> org.apache.maven.surefire.booter.SurefireBooter.runSuitesInProcess(Su
> refireBooter.java:269)
> at
> org.apache.maven.surefire.booter.SurefireBooter.main(SurefireBooter.j
> ava:788)
> Caused by: java.lang.NoClassDefFoundError:
> edu/emory/mathcs/backport/java/util/c
> oncurrent/BlockingQueue
> at
> org.apache.axis2.context.ConfigurationContext.getThreadPool(Configura
> tionContext.java:296)
> at
> org.apache.axis2.description.OutInAxisOperationClient.execute(OutInAx
> isOperation.java:306)
> at
> org.apache.tuscany.binding.axis2.Axis2AsyncTargetInvoker.invokeTarget
> (Axis2AsyncTargetInvoker.java:58)
> at
> org.apache.tuscany.binding.axis2.Axis2AsyncTargetInvoker.invoke(Axis2
> AsyncTargetInvoker.java:70)
> at
> org.apache.tuscany.core.wire.InvokerInterceptor.invoke(InvokerInterce
> ptor.java:44)
> at
> org.apache.tuscany.core.databinding.impl.DataBindingInteceptor.invoke
> (DataBindingInteceptor.java:71)
> ... 33 more
> Tests run: 1, Failures: 0, Errors: 1, Skipped: 0, Time elapsed: 3.032 sec
> <<< FA
> ILURE!
>
> Results :
>
> Tests in error:
> testWSClient(helloworld.HelloWorldWSClientTestCase)
>
> Tests run: 1, Failures: 0, Errors: 1, Skipped: 0
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: tuscany-dev-unsubscribe@ws.apache.org
> For additional commands, e-mail: tuscany-dev-help@ws.apache.org
>
>
---------------------------------------------------------------------
To unsubscribe, e-mail: tuscany-dev-unsubscribe@ws.apache.org
For additional commands, e-mail: tuscany-dev-help@ws.apache.org
Re: NoClassDefFoundError, apparently in Axis2
Posted by Raymond Feng <en...@gmail.com>.
Hi, Ignacio.
I can now reach a point that we use the Axis2 client to invokes the WS
asynchronously (operationClient.invoke(false)) but it fails after that
because the DataBindingInterceptor excepts a synchronous response but a
"ImmutableMessage" is returned instead. So the question is that how do we
tell if a given operation is invoked asynchronously or not.
For the test case, we have the following interface:
@Callback(HelloWorldCallback.class)
public interface HelloWorldService {
public String getGreetings(String name);
@DataType(name="commonj.sdo.DataObject")
public String getGreetings1(DataObject name);
public void getGreetingsWithCallback(String name);
}
It seems that getGreetings(...) goes to the async path in my debugging.
Please help me understand here.
Thanks,
Raymond
----- Original Message -----
From: "Ignacio Silva-Lepe" <is...@verizon.net>
To: "Tuscany Dev" <tu...@ws.apache.org>
Sent: Friday, September 29, 2006 2:08 PM
Subject: NoClassDefFoundError, apparently in Axis2
I am trying to run the hellowordwsclient sample by changing the bound
reference to use an interface.java, with which it runs ok. But if I then add
a callbackInterface I get the error below.
By using a callbackInterface, an Axis2AsyncTargetInvoker is chosen that
calls Axis2's operationClient.execute(false), i.e. non-blocking. Without the
callbackInterface an Axis2TargetInvoker is chosen which calls
operationClient.execute(true). So it seems as if trying to using a
non-blocking operation client execute triggers the error.
I have to wonder whether this may be an Axis2 dependency that has not been
set up.
Any ideas?
-------------------------------------------------------
T E S T S
-------------------------------------------------------
Running helloworld.HelloWorldWSClientTestCase
log4j:WARN No appenders could be found for logger
(org.apache.axiom.om.util.StAX
Utils).
log4j:WARN Please initialize the log4j system properly.
org.apache.tuscany.spi.wire.InvocationRuntimeException:
java.lang.NoClassDefFoun
dError: edu/emory/mathcs/backport/java/util/concurrent/BlockingQueue
at
org.apache.tuscany.core.databinding.impl.DataBindingInteceptor.invoke
(DataBindingInteceptor.java:76)
at
org.apache.tuscany.core.wire.BridgingInterceptor.invoke(BridgingInter
ceptor.java:41)
at
org.apache.tuscany.core.databinding.impl.DataBindingInteceptor.invoke
(DataBindingInteceptor.java:71)
at
org.apache.tuscany.core.wire.AbstractOutboundInvocationHandler.invoke
(AbstractOutboundInvocationHandler.java:65)
at
org.apache.tuscany.core.wire.jdk.JDKOutboundInvocationHandler.invoke(
JDKOutboundInvocationHandler.java:121)
at $Proxy20.getGreetings(Unknown Source)
at
helloworld.HelloWorldServiceComponent.getGreetings(HelloWorldServiceC
omponent.java:39)
at
helloworld.HelloWorldWSClientTestCase.testWSClient(HelloWorldWSClient
TestCase.java:43)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.
java:39)
at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAcces
sorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:585)
at junit.framework.TestCase.runTest(TestCase.java:154)
at junit.framework.TestCase.runBare(TestCase.java:127)
at junit.framework.TestResult$1.protect(TestResult.java:106)
at junit.framework.TestResult.runProtected(TestResult.java:124)
at junit.framework.TestResult.run(TestResult.java:109)
at junit.framework.TestCase.run(TestCase.java:118)
at junit.framework.TestSuite.runTest(TestSuite.java:208)
at junit.framework.TestSuite.run(TestSuite.java:203)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.
java:39)
at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAcces
sorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:585)
at
org.apache.maven.surefire.junit.JUnitTestSet.execute(JUnitTestSet.jav
a:210)
at
org.apache.maven.surefire.suite.AbstractDirectoryTestSuite.executeTes
tSet(AbstractDirectoryTestSuite.java:135)
at
org.apache.maven.surefire.suite.AbstractDirectoryTestSuite.execute(Ab
stractDirectoryTestSuite.java:122)
at org.apache.maven.surefire.Surefire.run(Surefire.java:129)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.
java:39)
at
sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAcces
sorImpl.java:25)
at java.lang.reflect.Method.invoke(Method.java:585)
at
org.apache.maven.surefire.booter.SurefireBooter.runSuitesInProcess(Su
refireBooter.java:269)
at
org.apache.maven.surefire.booter.SurefireBooter.main(SurefireBooter.j
ava:788)
Caused by: java.lang.NoClassDefFoundError:
edu/emory/mathcs/backport/java/util/c
oncurrent/BlockingQueue
at
org.apache.axis2.context.ConfigurationContext.getThreadPool(Configura
tionContext.java:296)
at
org.apache.axis2.description.OutInAxisOperationClient.execute(OutInAx
isOperation.java:306)
at
org.apache.tuscany.binding.axis2.Axis2AsyncTargetInvoker.invokeTarget
(Axis2AsyncTargetInvoker.java:58)
at
org.apache.tuscany.binding.axis2.Axis2AsyncTargetInvoker.invoke(Axis2
AsyncTargetInvoker.java:70)
at
org.apache.tuscany.core.wire.InvokerInterceptor.invoke(InvokerInterce
ptor.java:44)
at
org.apache.tuscany.core.databinding.impl.DataBindingInteceptor.invoke
(DataBindingInteceptor.java:71)
... 33 more
Tests run: 1, Failures: 0, Errors: 1, Skipped: 0, Time elapsed: 3.032 sec
<<< FA
ILURE!
Results :
Tests in error:
testWSClient(helloworld.HelloWorldWSClientTestCase)
Tests run: 1, Failures: 0, Errors: 1, Skipped: 0
---------------------------------------------------------------------
To unsubscribe, e-mail: tuscany-dev-unsubscribe@ws.apache.org
For additional commands, e-mail: tuscany-dev-help@ws.apache.org
Re: NoClassDefFoundError, apparently in Axis2
Posted by Raymond Feng <en...@gmail.com>.
Hi,
I have found the culprit. I'm adding the following to binding.axis2 pom.xml:
<dependency>
<groupId>backport-util-concurrent</groupId>
<artifactId>backport-util-concurrent</artifactId>
<version>2.2</version>
<scope>runtime</scope>
</dependency>
Thanks,
Raymond
----- Original Message -----
From: "Jeremy Boynes" <jb...@apache.org>
To: <tu...@ws.apache.org>
Sent: Friday, September 29, 2006 3:19 PM
Subject: Re: NoClassDefFoundError, apparently in Axis2
>
> On Sep 29, 2006, at 2:08 PM, Ignacio Silva-Lepe wrote:
>
>> I am trying to run the hellowordwsclient sample by changing the bound
>> reference to use an interface.java, with which it runs ok. But if I then
>> add a callbackInterface I get the error below.
>> By using a callbackInterface, an Axis2AsyncTargetInvoker is chosen that
>> calls Axis2's operationClient.execute(false), i.e. non- blocking. Without
>> the callbackInterface an Axis2TargetInvoker is chosen which calls
>> operationClient.execute(true). So it seems as if trying to using a
>> non-blocking operation client execute triggers the error.
>> I have to wonder whether this may be an Axis2 dependency that has not
>> been set up.
>> Any ideas?
>
> Some version of concurrent I would imagine - I'd suggest looking at the
> axis2 POM to see if anything is listed there.
>
> Ultimately we don't want to be using a separate thread pool for this - it
> should hook into our work manager (perhaps Meeraj could help here).
> --
> Jeremy
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: tuscany-dev-unsubscribe@ws.apache.org
> For additional commands, e-mail: tuscany-dev-help@ws.apache.org
>
---------------------------------------------------------------------
To unsubscribe, e-mail: tuscany-dev-unsubscribe@ws.apache.org
For additional commands, e-mail: tuscany-dev-help@ws.apache.org
Re: NoClassDefFoundError, apparently in Axis2
Posted by Jeremy Boynes <jb...@apache.org>.
On Sep 29, 2006, at 2:08 PM, Ignacio Silva-Lepe wrote:
> I am trying to run the hellowordwsclient sample by changing the
> bound reference to use an interface.java, with which it runs ok.
> But if I then add a callbackInterface I get the error below.
> By using a callbackInterface, an Axis2AsyncTargetInvoker is chosen
> that calls Axis2's operationClient.execute(false), i.e. non-
> blocking. Without the callbackInterface an Axis2TargetInvoker is
> chosen which calls operationClient.execute(true). So it seems as if
> trying to using a non-blocking operation client execute triggers
> the error.
> I have to wonder whether this may be an Axis2 dependency that has
> not been set up.
> Any ideas?
Some version of concurrent I would imagine - I'd suggest looking at
the axis2 POM to see if anything is listed there.
Ultimately we don't want to be using a separate thread pool for this
- it should hook into our work manager (perhaps Meeraj could help here).
--
Jeremy
---------------------------------------------------------------------
To unsubscribe, e-mail: tuscany-dev-unsubscribe@ws.apache.org
For additional commands, e-mail: tuscany-dev-help@ws.apache.org