Re: [Axis2] Memory leaks with 1.4.1

2009-04-08 Thread Andrei Ivanov
On Wed, Apr 8, 2009 at 11:34 AM, Amila Suriarachchi
amilasuriarach...@gmail.com wrote:
 hi,

 you may get a snapshot build from the 1.5 branch here[1]. we are hoping to
 release an RC soon.
 thanks,
 Amila.

What about backporting all these fixes to the 1.4 branch?
I think that's the stable branch... and as I see, 1.5 seems to
required JDK 1.5


Re: Axis2 MTOM and WSSecurity (encryption)

2009-03-28 Thread Andrei Ivanov
On Wed, Mar 25, 2009 at 6:13 PM, Erwin Reinhoud erwin.reinh...@ictu.nl wrote:
 Hello,

 I am wondering if more users need to use mtom and ws-security. There is an 
 issue (3407) since dec 2007, but is still not fixed. Isn;t it one of the 
 benefits that mtom supports ws-security?

 Kind regards,
 Erwin


It seems that Sandesha and Rampart don't get too much attention...


Sandesha sequence auto termination

2009-03-20 Thread Andrei Ivanov
Hello,
I found the following property:
org.apache.sandesha2.storage.beans.RMSBean.avoidAutoTermination
but I don't understand how it works
AFAIS, the setter for this property is only called on the client side,
so the client can ask Sandesha
not to terminate the sequence?
The problem seems to be that on the server side, the value of the
property isn't set anywhere... so it remains false
and the Sandesha server keeps sending TerminateSequence messages back
to the client, as a response to the
client's own TerminateSequence message(which probably is another bug)


Sandesha sequence auto termination

2009-03-19 Thread Andrei Ivanov
Hello,
I found the following property:
org.apache.sandesha2.storage.beans.RMSBean.avoidAutoTermination
but I don't understand how it works
AFAIS, the setter for this property is only called on the client side,
so the client can ask Sandesha
not to terminate the sequence?
The problem seems to be that on the server side, the value of the
property isn't set anywhere... so it remains false
and the Sandesha server keeps sending TerminateSequence messages back
to the client, as a response to the
client's own TerminateSequence message(which probably is another bug)


Sandesha sequence auto termination

2009-03-18 Thread Andrei Ivanov
Hello,
I found the following property:
org.apache.sandesha2.storage.beans.RMSBean.avoidAutoTermination
but I don't understand how it works
AFAIS, the setter for this property is only called on the client side,
so the client can ask Sandesha
not to terminate the sequence?
The problem seems to be that on the server side, the value of the
property isn't set anywhere... so it remains false
and the Sandesha server keeps sending TerminateSequence messages back
to the client, as a response to the
client's own TerminateSequence message(which probably is another bug)


Sandesha sequence auto termination

2009-03-16 Thread Andrei Ivanov
Hello,
I found the following property:
org.apache.sandesha2.storage.beans.RMSBean.avoidAutoTermination
but I don't understand how it works
AFAIS, the setter for this property is only called on the client side,
so the client can ask Sandesha
not to terminate the sequence?
The problem seems to be that on the server side, the value of the
property isn't set anywhere... so it remains false
and the Sandesha server keeps sending TerminateSequence messages back
to the client, as a response to the
client's own TerminateSequence message(which probably is another bug)


Re: sandesha problem

2009-02-06 Thread Andrei Ivanov
Any thoughts?

On Mon, Feb 2, 2009 at 11:13 AM, Andrei Ivanov andrei.iva...@gmail.com wrote:
 On Mon, Feb 2, 2009 at 8:07 AM, Amila Suriarachchi
 amilasuriarach...@gmail.com wrote:
 Can you try with the axis2 snapshot and sandesha2 snapshot.
 I see that sandesha2 snapshot is using generics... and I use java 1.4

 Try using different INTERNAL_KEY s rather than the SEQUENCE_KEY
 How can I do that?
 AFAIS, in both 1.3 and in snapshot the internal key is defined like this:
 Sandesha2Constants.INTERNAL_SEQUENCE_PREFIX + : + to + : + sequenceKey

 I am providing a different sequence key for each sequence... so this
 should make the internal key different already.


 thanks,
 Amila.

 On Sun, Feb 1, 2009 at 9:17 PM, Andrei Ivanov andrei.iva...@gmail.com
 wrote:

 Hello,
 I'm trying to add WS-RM to my services and clients, but I'm having
 some problems.
 I followed the user guide and when I tried to do some testing, I
 noticed some exceptions being thrown.

 I've generated a client stub(PersonalDataServiceStub) from the
 services WSDL and I've added these lines to the end
 of the constructor(PersonalDataServiceStub(ConfigurationContext
 configurationContext, String targetEndpoint, boolean
 useSeparateListener)):

 final String sequenceKey = SandeshaUtil.getUUID();
 clientOptions.setProperty(SandeshaClientConstants.SEQUENCE_KEY,
 sequenceKey);
 clientOptions.setProperty(SandeshaClientConstants.LAST_MESSAGE,
 Constants.VALUE_TRUE);

 Then, in the test class I created 2 instances of the stub and called
 some methods:

 ConfigurationContext configContext =

 ConfigurationContextFactory.createConfigurationContextFromFileSystem(CLIENT_REPO_PATH,
 axis2_xml);

 PersonalDataServiceStub stub = new
 PersonalDataServiceStub(configurationContext, targetEndpoint, true);
 // param was initialized
 stub.getPersonalData(param);

 stub = new PersonalDataServiceStub(configurationContext, targetEndpoint,
 true);
 stub.getFamilyTree(request);

 I'm setting the sequenceKey myself because I want to use 2 separate
 sequences for the calls, but something goes wrong.
 I used tcpmon to see what it was doing:
 Client:
 1. CreateSequence
 2. invoke getPersonalData
 3. CreateSequence (for the 2nd call)
 4. TerminateSequence (for the 1st call)
 5. invoke getFamilyTree
 6. TerminateSequence (for the 2nd call)

 Server:
 1. CreateSequenceResponse
 2. result for getPersonalData
 3. CreateSequenceResponse
 4. TerminateSequence (why is the server trying to end the 1st sequence
 itself?)
 5. result for getFamilyTree
 6. Fault, the action
 http://schemas.xmlsoap.org/ws/2005/02/rm/TerminateSequence; cannot be
 processed at the receiver (probably for the 1st TerminateSequence from
 the client)
 7. SequenceFault, the 1st sequence is already terminated... probably
 at step 4 the server terminated it
 8. TerminateSequence, for the 2nd sequence


 Am I doing something wrong? or maybe it is a bug in sandesha? remember
 that I want to use a different sequence for each operation.
 If you need additional data, please tell me.
 Thanks



 --
 Amila Suriarachchi
 WSO2 Inc.
 blog: http://amilachinthaka.blogspot.com/




Re: sandesha problem

2009-02-04 Thread Andrei Ivanov
Anyone?

On Mon, Feb 2, 2009 at 11:13 AM, Andrei Ivanov andrei.iva...@gmail.com wrote:
 On Mon, Feb 2, 2009 at 8:07 AM, Amila Suriarachchi
 amilasuriarach...@gmail.com wrote:
 Can you try with the axis2 snapshot and sandesha2 snapshot.
 I see that sandesha2 snapshot is using generics... and I use java 1.4

 Try using different INTERNAL_KEY s rather than the SEQUENCE_KEY
 How can I do that?
 AFAIS, in both 1.3 and in snapshot the internal key is defined like this:
 Sandesha2Constants.INTERNAL_SEQUENCE_PREFIX + : + to + : + sequenceKey

 I am providing a different sequence key for each sequence... so this
 should make the internal key different already.


 thanks,
 Amila.

 On Sun, Feb 1, 2009 at 9:17 PM, Andrei Ivanov andrei.iva...@gmail.com
 wrote:

 Hello,
 I'm trying to add WS-RM to my services and clients, but I'm having
 some problems.
 I followed the user guide and when I tried to do some testing, I
 noticed some exceptions being thrown.

 I've generated a client stub(PersonalDataServiceStub) from the
 services WSDL and I've added these lines to the end
 of the constructor(PersonalDataServiceStub(ConfigurationContext
 configurationContext, String targetEndpoint, boolean
 useSeparateListener)):

 final String sequenceKey = SandeshaUtil.getUUID();
 clientOptions.setProperty(SandeshaClientConstants.SEQUENCE_KEY,
 sequenceKey);
 clientOptions.setProperty(SandeshaClientConstants.LAST_MESSAGE,
 Constants.VALUE_TRUE);

 Then, in the test class I created 2 instances of the stub and called
 some methods:

 ConfigurationContext configContext =

 ConfigurationContextFactory.createConfigurationContextFromFileSystem(CLIENT_REPO_PATH,
 axis2_xml);

 PersonalDataServiceStub stub = new
 PersonalDataServiceStub(configurationContext, targetEndpoint, true);
 // param was initialized
 stub.getPersonalData(param);

 stub = new PersonalDataServiceStub(configurationContext, targetEndpoint,
 true);
 stub.getFamilyTree(request);

 I'm setting the sequenceKey myself because I want to use 2 separate
 sequences for the calls, but something goes wrong.
 I used tcpmon to see what it was doing:
 Client:
 1. CreateSequence
 2. invoke getPersonalData
 3. CreateSequence (for the 2nd call)
 4. TerminateSequence (for the 1st call)
 5. invoke getFamilyTree
 6. TerminateSequence (for the 2nd call)

 Server:
 1. CreateSequenceResponse
 2. result for getPersonalData
 3. CreateSequenceResponse
 4. TerminateSequence (why is the server trying to end the 1st sequence
 itself?)
 5. result for getFamilyTree
 6. Fault, the action
 http://schemas.xmlsoap.org/ws/2005/02/rm/TerminateSequence; cannot be
 processed at the receiver (probably for the 1st TerminateSequence from
 the client)
 7. SequenceFault, the 1st sequence is already terminated... probably
 at step 4 the server terminated it
 8. TerminateSequence, for the 2nd sequence


 Am I doing something wrong? or maybe it is a bug in sandesha? remember
 that I want to use a different sequence for each operation.
 If you need additional data, please tell me.
 Thanks



 --
 Amila Suriarachchi
 WSO2 Inc.
 blog: http://amilachinthaka.blogspot.com/




Re: axis2 1.4.1 and rampart 1.4 issue

2009-02-04 Thread Andrei Ivanov
Don't top post.

On Wed, Feb 4, 2009 at 10:51 AM, Iyengar, Kumar kumar_iyen...@bmc.com wrote:
 What missing jars? I added Rampart 1.4 mar file to the modules directory
 as per the instructions in the ReadMe file. I get the error:

In your first mail, there are some exceptions like these:
java.lang.ClassNotFoundException: org.apache.rampart.Rampart

These tell you what classes are missing.
If you search through your rampart jars, you'll find that rampart-core
contains this class.
Just copy it to the lib directory.


Axiom bug?

2009-02-04 Thread Andrei Ivanov
Hello,
I'm trying to use Sandesha with Rampart and I think I've found a bug.
When the server is replying to a CreateSequence message, it gets to
RampartSender,
which calls org.apache.rampart.MessageBuilder.build(MessageContext msgCtx),
which verifies that the security header is empty and tries to remove it:

if ( secHeader != null  secHeader.isEmpty(doc) ) {
   secHeader.removeSecurityHeader(doc);
}

WSSecHeader.removeSecurityHeader(Document doc) does this:
...
Node parent = securityHeader.getParentNode();
parent.removeChild(securityHeader);

Parent:
soapenv:Header
xmlns:soapenv=http://schemas.xmlsoap.org/soap/envelope/;
xmlns:wsa=http://www.w3.org/2005/08/addressing;
  wsse:Security
xmlns:wsse=http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-secext-1.0.xsd;
soapenv:mustUnderstand=1 /
  
wsa:Tohttp://192.168.1.5:6060/axis2/services/personaldataserv...@286914895//wsa:To
  
wsa:ReplyTowsa:Addresshttp://www.w3.org/2005/08/addressing/none/wsa:Address/wsa:ReplyTo
  wsa:MessageIDurn:uuid:E3FC5985317BCF16351233758322948/wsa:MessageID
  
wsa:Actionhttp://schemas.xmlsoap.org/ws/2005/02/rm/CreateSequenceResponse/wsa:Action
  wsa:RelatesTourn:uuid:A07FCCC1972C7E06671233758319824/wsa:RelatesTo
/soapenv:Header

securityHeader:
wsse:Security 
xmlns:wsse=http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-secext-1.0.xsd;
xmlns:soapenv=http://schemas.xmlsoap.org/soap/envelope/;
soapenv:mustUnderstand=1 /

Then, org.apache.axiom.om.impl.dom.ParentNode.removeChild(Node) is
called and it gets to this, begining with line 482:
if (this.firstChild == tempNode) {
// If this is the first child
this.firstChild = null;
this.lastChild = null;
tempNode.parentNode = null;
}

tempNode is the security header and it is equal to the firstChild of
the envelope header.
The firstChild is removed... then the lastChild(which is the relatesTo
child) is removed...

The resulting envelope header is this:
soapenv:Header
xmlns:soapenv=http://schemas.xmlsoap.org/soap/envelope/;
xmlns:wsa=http://www.w3.org/2005/08/addressing; /

I'm using Axis-1.4.1, Addressing-1.41, Sandesha2-1.3, Rampart-1.4, Axiom 1.2.8
I've looked in the Axiom sources and it seems this code is from before
revision 389047 (Moving doom into ws-commons axiom from axis2)

I think this is a bug...
Am I right? Should I create an issue?


Re: Axiom bug?

2009-02-04 Thread Andrei Ivanov
On Wed, Feb 4, 2009 at 5:41 PM, Andreas Veithen
andreas.veit...@gmail.com wrote:
 Andrei,

 What is the Axiom version you are using? If it is not 1.2.8 or a
 recent snapshot, please check against version 1.2.8. If you can
 confirm that the issue still exists in that version, please open a
 JIRA issue in the WSCOMMONS project.

1.2.8... it say right at the end of my email...
I'll open an issue...
Thanks

 Regards,

 Andreas

 On Wed, Feb 4, 2009 at 16:08, Andrei Ivanov andrei.iva...@gmail.com wrote:
 Hello,
 I'm trying to use Sandesha with Rampart and I think I've found a bug.
 When the server is replying to a CreateSequence message, it gets to
 RampartSender,
 which calls org.apache.rampart.MessageBuilder.build(MessageContext msgCtx),
 which verifies that the security header is empty and tries to remove it:

 if ( secHeader != null  secHeader.isEmpty(doc) ) {
   secHeader.removeSecurityHeader(doc);
 }

 WSSecHeader.removeSecurityHeader(Document doc) does this:
 ...
 Node parent = securityHeader.getParentNode();
 parent.removeChild(securityHeader);

 Parent:
 soapenv:Header
 xmlns:soapenv=http://schemas.xmlsoap.org/soap/envelope/;
 xmlns:wsa=http://www.w3.org/2005/08/addressing;
  wsse:Security
 xmlns:wsse=http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-secext-1.0.xsd;
 soapenv:mustUnderstand=1 /
  
 wsa:Tohttp://192.168.1.5:6060/axis2/services/personaldataserv...@286914895//wsa:To
  
 wsa:ReplyTowsa:Addresshttp://www.w3.org/2005/08/addressing/none/wsa:Address/wsa:ReplyTo
  wsa:MessageIDurn:uuid:E3FC5985317BCF16351233758322948/wsa:MessageID
  
 wsa:Actionhttp://schemas.xmlsoap.org/ws/2005/02/rm/CreateSequenceResponse/wsa:Action
  wsa:RelatesTourn:uuid:A07FCCC1972C7E06671233758319824/wsa:RelatesTo
 /soapenv:Header

 securityHeader:
 wsse:Security 
 xmlns:wsse=http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-secext-1.0.xsd;
 xmlns:soapenv=http://schemas.xmlsoap.org/soap/envelope/;
 soapenv:mustUnderstand=1 /

 Then, org.apache.axiom.om.impl.dom.ParentNode.removeChild(Node) is
 called and it gets to this, begining with line 482:
 if (this.firstChild == tempNode) {
// If this is the first child
this.firstChild = null;
this.lastChild = null;
tempNode.parentNode = null;
 }

 tempNode is the security header and it is equal to the firstChild of
 the envelope header.
 The firstChild is removed... then the lastChild(which is the relatesTo
 child) is removed...

 The resulting envelope header is this:
 soapenv:Header
 xmlns:soapenv=http://schemas.xmlsoap.org/soap/envelope/;
 xmlns:wsa=http://www.w3.org/2005/08/addressing; /

 I'm using Axis-1.4.1, Addressing-1.41, Sandesha2-1.3, Rampart-1.4, Axiom 
 1.2.8
 I've looked in the Axiom sources and it seems this code is from before
 revision 389047 (Moving doom into ws-commons axiom from axis2)

 I think this is a bug...
 Am I right? Should I create an issue?




Re: sandesha problem

2009-02-02 Thread Andrei Ivanov
On Mon, Feb 2, 2009 at 8:07 AM, Amila Suriarachchi
amilasuriarach...@gmail.com wrote:
 Can you try with the axis2 snapshot and sandesha2 snapshot. Try using
 different INTERNAL_KEY s rather than the SEQUENCE_KEY
I've just tried the snapshots and I don't think there's any difference.
The server side keeps sending TerminateSequence messages, as if it is
ignoring the TerminateSequence from the client.
Or maybe the server side sees the CreateSequence messages from the
next sequence and somehow it decides it needs to terminate
the first one itself?


 thanks,
 Amila.

 On Sun, Feb 1, 2009 at 9:17 PM, Andrei Ivanov andrei.iva...@gmail.com
 wrote:

 Hello,
 I'm trying to add WS-RM to my services and clients, but I'm having
 some problems.
 I followed the user guide and when I tried to do some testing, I
 noticed some exceptions being thrown.

 I've generated a client stub(PersonalDataServiceStub) from the
 services WSDL and I've added these lines to the end
 of the constructor(PersonalDataServiceStub(ConfigurationContext
 configurationContext, String targetEndpoint, boolean
 useSeparateListener)):

 final String sequenceKey = SandeshaUtil.getUUID();
 clientOptions.setProperty(SandeshaClientConstants.SEQUENCE_KEY,
 sequenceKey);
 clientOptions.setProperty(SandeshaClientConstants.LAST_MESSAGE,
 Constants.VALUE_TRUE);

 Then, in the test class I created 2 instances of the stub and called
 some methods:

 ConfigurationContext configContext =

 ConfigurationContextFactory.createConfigurationContextFromFileSystem(CLIENT_REPO_PATH,
 axis2_xml);

 PersonalDataServiceStub stub = new
 PersonalDataServiceStub(configurationContext, targetEndpoint, true);
 // param was initialized
 stub.getPersonalData(param);

 stub = new PersonalDataServiceStub(configurationContext, targetEndpoint,
 true);
 stub.getFamilyTree(request);

 I'm setting the sequenceKey myself because I want to use 2 separate
 sequences for the calls, but something goes wrong.
 I used tcpmon to see what it was doing:
 Client:
 1. CreateSequence
 2. invoke getPersonalData
 3. CreateSequence (for the 2nd call)
 4. TerminateSequence (for the 1st call)
 5. invoke getFamilyTree
 6. TerminateSequence (for the 2nd call)

 Server:
 1. CreateSequenceResponse
 2. result for getPersonalData
 3. CreateSequenceResponse
 4. TerminateSequence (why is the server trying to end the 1st sequence
 itself?)
 5. result for getFamilyTree
 6. Fault, the action
 http://schemas.xmlsoap.org/ws/2005/02/rm/TerminateSequence; cannot be
 processed at the receiver (probably for the 1st TerminateSequence from
 the client)
 7. SequenceFault, the 1st sequence is already terminated... probably
 at step 4 the server terminated it
 8. TerminateSequence, for the 2nd sequence


 Am I doing something wrong? or maybe it is a bug in sandesha? remember
 that I want to use a different sequence for each operation.
 If you need additional data, please tell me.
 Thanks



 --
 Amila Suriarachchi
 WSO2 Inc.
 blog: http://amilachinthaka.blogspot.com/



sandesha problem

2009-02-01 Thread Andrei Ivanov
Hello,
I'm trying to add WS-RM to my services and clients, but I'm having
some problems.
I followed the user guide and when I tried to do some testing, I
noticed some exceptions being thrown.

I've generated a client stub(PersonalDataServiceStub) from the
services WSDL and I've added these lines to the end
of the constructor(PersonalDataServiceStub(ConfigurationContext
configurationContext, String targetEndpoint, boolean
useSeparateListener)):

final String sequenceKey = SandeshaUtil.getUUID();
clientOptions.setProperty(SandeshaClientConstants.SEQUENCE_KEY, sequenceKey);
clientOptions.setProperty(SandeshaClientConstants.LAST_MESSAGE,
Constants.VALUE_TRUE);

Then, in the test class I created 2 instances of the stub and called
some methods:

ConfigurationContext configContext =
ConfigurationContextFactory.createConfigurationContextFromFileSystem(CLIENT_REPO_PATH,
axis2_xml);

PersonalDataServiceStub stub = new
PersonalDataServiceStub(configurationContext, targetEndpoint, true);
// param was initialized
stub.getPersonalData(param);

stub = new PersonalDataServiceStub(configurationContext, targetEndpoint, true);
stub.getFamilyTree(request);

I'm setting the sequenceKey myself because I want to use 2 separate
sequences for the calls, but something goes wrong.
I used tcpmon to see what it was doing:
Client:
1. CreateSequence
2. invoke getPersonalData
3. CreateSequence (for the 2nd call)
4. TerminateSequence (for the 1st call)
5. invoke getFamilyTree
6. TerminateSequence (for the 2nd call)

Server:
1. CreateSequenceResponse
2. result for getPersonalData
3. CreateSequenceResponse
4. TerminateSequence (why is the server trying to end the 1st sequence itself?)
5. result for getFamilyTree
6. Fault, the action
http://schemas.xmlsoap.org/ws/2005/02/rm/TerminateSequence; cannot be
processed at the receiver (probably for the 1st TerminateSequence from
the client)
7. SequenceFault, the 1st sequence is already terminated... probably
at step 4 the server terminated it
8. TerminateSequence, for the 2nd sequence


Am I doing something wrong? or maybe it is a bug in sandesha? remember
that I want to use a different sequence for each operation.
If you need additional data, please tell me.
Thanks