Michael,
I'm not an Axis2 developer -- just a user -- but I would try your test
with a more recent release of Axis2 (the most recent release is 1.4)
before opening a bug.
Steve
I would
Michael Mathers wrote:
Yes, I use Axis2 v1.1.1
Should I log a bug for this then?
Michael
-----Original Message-----
From: Steve Hall [mailto:[EMAIL PROTECTED]
Sent: Thursday, June 19, 2008 10:21 AM
To: [email protected]
Subject: Re: AxisFault not Serializable
Michael,
I use Axis2 not Axis and I don't have Axis source code in front of me
but looking at the stack trace it appears that AxisFault has an inner
class named FaultReason that is throwing the not serializable exception.
I would guess that FaultReason doesnt implement Serializable.
Steve
Michael Mathers wrote:
Despite this class implements Serializable, I get
NotSerializableException when I try to do so.
I am using Axis 1.1.1. I searched the Issue database but I did not
find this issue anywhere (resolved or unresolved). I even searched
this list but to no avail.
Please excuse me if I'm being ignorant somehow and just kindly point
out what I'm not understanding.
Below is the sample code and the exception generated.
Michael
@Test
* public * * void * testSerial() {
AxisFault af = * new * AxisFault( "test" );
// Test serialization
* try * {
FileOutputStream os = * new * FileOutputStream(
"serial.txt" );
ObjectOutputStream oos = * new *
ObjectOutputStream(os);
oos.writeObject(af);
oos.close();
os.close();
} * catch * (Exception e) {
e.printStackTrace();
}
}
java.io.NotSerializableException :
org.apache.axis2.AxisFault$FaultReason
at java.io.ObjectOutputStream.writeObject0(
ObjectOutputStream.java:1081 )
at java.io.ObjectOutputStream.writeObject(
ObjectOutputStream.java:302 )
at java.util.ArrayList.writeObject( ArrayList.java:569 )
at sun.reflect.NativeMethodAccessorImpl.invoke0( Native Method
)
at sun.reflect.NativeMethodAccessorImpl.invoke(
NativeMethodAccessorImpl.java:39 )
at sun.reflect.DelegatingMethodAccessorImpl.invoke(
DelegatingMethodAccessorImpl.java:25 )
at java.lang.reflect.Method.invoke( Method.java:585 )
at java.io.ObjectStreamClass.invokeWriteObject(
ObjectStreamClass.java:917 )
at java.io.ObjectOutputStream.writeSerialData(
ObjectOutputStream.java:1339 )
at java.io.ObjectOutputStream.writeOrdinaryObject(
ObjectOutputStream.java:1290 )
at java.io.ObjectOutputStream.writeObject0(
ObjectOutputStream.java:1079 )
at java.io.ObjectOutputStream.defaultWriteFields(
ObjectOutputStream.java:1375 )
at java.io.ObjectOutputStream.writeSerialData(
ObjectOutputStream.java:1347 )
at java.io.ObjectOutputStream.writeOrdinaryObject(
ObjectOutputStream.java:1290 )
at java.io.ObjectOutputStream.writeObject0(
ObjectOutputStream.java:1079 )
at java.io.ObjectOutputStream.writeObject(
ObjectOutputStream.java:302 )
at com.ipd.esb.job.EFTRoster.TestEFTRosterBatch.testSerial(
TestEFTRosterBatch.java:215 )
at sun.reflect.NativeMethodAccessorImpl.invoke0( Native Method
)
at sun.reflect.NativeMethodAccessorImpl.invoke(
NativeMethodAccessorImpl.java:39 )
at sun.reflect.DelegatingMethodAccessorImpl.invoke(
DelegatingMethodAccessorImpl.java:25 )
at java.lang.reflect.Method.invoke( Method.java:585 )
at
org.junit.internal.runners.TestMethodRunner.executeMethodBody(
TestMethodRunner.java:99 )
at org.junit.internal.runners.TestMethodRunner.runUnprotected(
TestMethodRunner.java:81 )
at
org.junit.internal.runners.BeforeAndAfterRunner.runProtected(
BeforeAndAfterRunner.java:34 )
at org.junit.internal.runners.TestMethodRunner.runMethod(
TestMethodRunner.java:75 )
at org.junit.internal.runners.TestMethodRunner.run(
TestMethodRunner.java:45 )
at
org.junit.internal.runners.TestClassMethodsRunner.invokeTestMethod(
TestClassMethodsRunner.java:71 )
at org.junit.internal.runners.TestClassMethodsRunner.run(
TestClassMethodsRunner.java:35 )
at
org.junit.internal.runners.TestClassRunner$1.runUnprotected(
TestClassRunner.java:42 )
at
org.junit.internal.runners.BeforeAndAfterRunner.runProtected(
BeforeAndAfterRunner.java:34 )
at org.junit.internal.runners.TestClassRunner.run(
TestClassRunner.java:52 )
at
org.eclipse.jdt.internal.junit4.runner.JUnit4TestReference.run(
JUnit4TestReference.java:38 )
at org.eclipse.jdt.internal.junit.runner.TestExecution.run(
TestExecution.java:38 )
at
org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(
RemoteTestRunner.java:460 )
at
org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(
RemoteTestRunner.java:673 )
at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.run(
RemoteTestRunner.java:386 )
at
org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.main(
RemoteTestRunner.java:196 )
This message is private and confidential. If you have received it in
error, please notify the sender and remove it from your system.
This message is private and confidential. If you have received it in
error, please notify the sender and remove it from your system.
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
This message is private and confidential. If you have received it in error,
please notify the sender and remove it from your system.
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]