You are viewing a plain text version of this content. The canonical link for it is here.
Posted to java-dev@axis.apache.org by "Mario A. Rodriguez (JIRA)" <ji...@apache.org> on 2006/09/11 10:16:22 UTC

[jira] Created: (AXIS2-1135) ClassCastException in AddressingOutHandler when Rahas is engaged

ClassCastException in AddressingOutHandler when Rahas is engaged
----------------------------------------------------------------

                 Key: AXIS2-1135
                 URL: http://issues.apache.org/jira/browse/AXIS2-1135
             Project: Apache Axis 2.0 (Axis2)
          Issue Type: Bug
          Components: Addressing
            Reporter: Mario A. Rodriguez


I'm trying to figure out how to configure/use Rahas for WS-SecConv interactions. However, my service is failing in the MessageOut phase.

I am receiving the following exception: (some line numbers may not match due some extra logging that I've added)

Caused by: java.lang.ClassCastException: org.apache.axiom.om.impl.llom.OMElementImpl
	at org.apache.axiom.om.impl.dom.ParentNode.addChild(ParentNode.java:56)
	at org.apache.axis2.handlers.addressing.AddressingOutHandler.processReferenceInformation(AddressingOutHandler.java:364)
	at org.apache.axis2.handlers.addressing.AddressingOutHandler.addToSOAPHeader(AddressingOutHandler.java:314)
	at org.apache.axis2.handlers.addressing.AddressingOutHandler.processReplyTo(AddressingOutHandler.java:254)
	at org.apache.axis2.handlers.addressing.AddressingOutHandler.invoke(AddressingOutHandler.java:125)

The line in question is attempting to do:                 
        OMElement omElement = (OMElement) referenceInformation.get(key);
         parent.addChild(omElement);   <--- exception occurs inside this call when addChild() attempts to cast omElement to Node.

According to the Axis2 trace logs, the RequestSecurityToken request was handled successfully by Rahas, but it then gets hung up while writing the addressing headers to the response. The addressing module appears to work correctly if Rahas is not engaged.



-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

---------------------------------------------------------------------
To unsubscribe, e-mail: axis-dev-unsubscribe@ws.apache.org
For additional commands, e-mail: axis-dev-help@ws.apache.org


[jira] Resolved: (AXIS2-1135) ClassCastException in AddressingOutHandler when Rahas is engaged

Posted by "Eran Chinthaka (JIRA)" <ji...@apache.org>.
     [ http://issues.apache.org/jira/browse/AXIS2-1135?page=all ]

Eran Chinthaka resolved AXIS2-1135.
-----------------------------------

    Resolution: Fixed
      Assignee: Eran Chinthaka

Fixed in the latest svn

> ClassCastException in AddressingOutHandler when Rahas is engaged
> ----------------------------------------------------------------
>
>                 Key: AXIS2-1135
>                 URL: http://issues.apache.org/jira/browse/AXIS2-1135
>             Project: Apache Axis 2.0 (Axis2)
>          Issue Type: Bug
>          Components: Addressing
>            Reporter: Mario A. Rodriguez
>         Assigned To: Eran Chinthaka
>
> I'm trying to figure out how to configure/use Rahas for WS-SecConv interactions. However, my service is failing in the MessageOut phase.
> I am receiving the following exception: (some line numbers may not match due some extra logging that I've added)
> Caused by: java.lang.ClassCastException: org.apache.axiom.om.impl.llom.OMElementImpl
> 	at org.apache.axiom.om.impl.dom.ParentNode.addChild(ParentNode.java:56)
> 	at org.apache.axis2.handlers.addressing.AddressingOutHandler.processReferenceInformation(AddressingOutHandler.java:364)
> 	at org.apache.axis2.handlers.addressing.AddressingOutHandler.addToSOAPHeader(AddressingOutHandler.java:314)
> 	at org.apache.axis2.handlers.addressing.AddressingOutHandler.processReplyTo(AddressingOutHandler.java:254)
> 	at org.apache.axis2.handlers.addressing.AddressingOutHandler.invoke(AddressingOutHandler.java:125)
> The line in question is attempting to do:                 
>         OMElement omElement = (OMElement) referenceInformation.get(key);
>          parent.addChild(omElement);   <--- exception occurs inside this call when addChild() attempts to cast omElement to Node.
> According to the Axis2 trace logs, the RequestSecurityToken request was handled successfully by Rahas, but it then gets hung up while writing the addressing headers to the response. The addressing module appears to work correctly if Rahas is not engaged.

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

---------------------------------------------------------------------
To unsubscribe, e-mail: axis-dev-unsubscribe@ws.apache.org
For additional commands, e-mail: axis-dev-help@ws.apache.org


[jira] Commented: (AXIS2-1135) ClassCastException in AddressingOutHandler when Rahas is engaged

Posted by "Mario A. Rodriguez (JIRA)" <ji...@apache.org>.
    [ http://issues.apache.org/jira/browse/AXIS2-1135?page=comments#action_12433943 ] 
            
Mario A. Rodriguez commented on AXIS2-1135:
-------------------------------------------

I have applied all the changes described above, and now the code is getting past the ClassCastException, but it's still blowing up with a 

DOMException(DOMException.WRONG_DOCUMENT_ERR. at:
	at org.apache.axiom.om.impl.dom.ParentNode.insertBefore(ParentNode.java:160)
	at org.apache.axiom.om.impl.dom.NodeImpl.appendChild(NodeImpl.java:249)
	at org.apache.axiom.om.impl.dom.ParentNode.addChild(ParentNode.java:56)
	at org.apache.axis2.handlers.addressing.AddressingOutHandler.processReferenceInformation(AddressingOutHandler.java:370)
	at org.apache.axis2.handlers.addressing.AddressingOutHandler.addToSOAPHeader(AddressingOutHandler.java:320)
	at org.apache.axis2.handlers.addressing.AddressingOutHandler.processReplyTo(AddressingOutHandler.java:260)
	at org.apache.axis2.handlers.addressing.AddressingOutHandler.invoke(AddressingOutHandler.java:126)


> ClassCastException in AddressingOutHandler when Rahas is engaged
> ----------------------------------------------------------------
>
>                 Key: AXIS2-1135
>                 URL: http://issues.apache.org/jira/browse/AXIS2-1135
>             Project: Apache Axis 2.0 (Axis2)
>          Issue Type: Bug
>          Components: Addressing
>            Reporter: Mario A. Rodriguez
>         Assigned To: Eran Chinthaka
>
> I'm trying to figure out how to configure/use Rahas for WS-SecConv interactions. However, my service is failing in the MessageOut phase.
> I am receiving the following exception: (some line numbers may not match due some extra logging that I've added)
> Caused by: java.lang.ClassCastException: org.apache.axiom.om.impl.llom.OMElementImpl
> 	at org.apache.axiom.om.impl.dom.ParentNode.addChild(ParentNode.java:56)
> 	at org.apache.axis2.handlers.addressing.AddressingOutHandler.processReferenceInformation(AddressingOutHandler.java:364)
> 	at org.apache.axis2.handlers.addressing.AddressingOutHandler.addToSOAPHeader(AddressingOutHandler.java:314)
> 	at org.apache.axis2.handlers.addressing.AddressingOutHandler.processReplyTo(AddressingOutHandler.java:254)
> 	at org.apache.axis2.handlers.addressing.AddressingOutHandler.invoke(AddressingOutHandler.java:125)
> The line in question is attempting to do:                 
>         OMElement omElement = (OMElement) referenceInformation.get(key);
>          parent.addChild(omElement);   <--- exception occurs inside this call when addChild() attempts to cast omElement to Node.
> According to the Axis2 trace logs, the RequestSecurityToken request was handled successfully by Rahas, but it then gets hung up while writing the addressing headers to the response. The addressing module appears to work correctly if Rahas is not engaged.

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

---------------------------------------------------------------------
To unsubscribe, e-mail: axis-dev-unsubscribe@ws.apache.org
For additional commands, e-mail: axis-dev-help@ws.apache.org


[jira] Commented: (AXIS2-1135) ClassCastException in AddressingOutHandler when Rahas is engaged

Posted by "Ruchith Udayanga Fernando (JIRA)" <ji...@apache.org>.
    [ http://issues.apache.org/jira/browse/AXIS2-1135?page=comments#action_12433821 ] 
            
Ruchith Udayanga Fernando commented on AXIS2-1135:
--------------------------------------------------

This is because one MUST use the *same* OMFactory (from a parent element) when adding children to that parent element. In the described case we are trying to attach OMElements form different factories.

The above case where we run into the ClassCastException we are trying to extract the reference properties as OMElements and we try to attach them into the soap envelope. But ideally we should create the same OMElement using the OMFactory used in the soap envelope. We need something like the import() method in DOM.

Chinthaka, what do you think?

Thanks,
Ruchith

> ClassCastException in AddressingOutHandler when Rahas is engaged
> ----------------------------------------------------------------
>
>                 Key: AXIS2-1135
>                 URL: http://issues.apache.org/jira/browse/AXIS2-1135
>             Project: Apache Axis 2.0 (Axis2)
>          Issue Type: Bug
>          Components: Addressing
>            Reporter: Mario A. Rodriguez
>
> I'm trying to figure out how to configure/use Rahas for WS-SecConv interactions. However, my service is failing in the MessageOut phase.
> I am receiving the following exception: (some line numbers may not match due some extra logging that I've added)
> Caused by: java.lang.ClassCastException: org.apache.axiom.om.impl.llom.OMElementImpl
> 	at org.apache.axiom.om.impl.dom.ParentNode.addChild(ParentNode.java:56)
> 	at org.apache.axis2.handlers.addressing.AddressingOutHandler.processReferenceInformation(AddressingOutHandler.java:364)
> 	at org.apache.axis2.handlers.addressing.AddressingOutHandler.addToSOAPHeader(AddressingOutHandler.java:314)
> 	at org.apache.axis2.handlers.addressing.AddressingOutHandler.processReplyTo(AddressingOutHandler.java:254)
> 	at org.apache.axis2.handlers.addressing.AddressingOutHandler.invoke(AddressingOutHandler.java:125)
> The line in question is attempting to do:                 
>         OMElement omElement = (OMElement) referenceInformation.get(key);
>          parent.addChild(omElement);   <--- exception occurs inside this call when addChild() attempts to cast omElement to Node.
> According to the Axis2 trace logs, the RequestSecurityToken request was handled successfully by Rahas, but it then gets hung up while writing the addressing headers to the response. The addressing module appears to work correctly if Rahas is not engaged.

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

---------------------------------------------------------------------
To unsubscribe, e-mail: axis-dev-unsubscribe@ws.apache.org
For additional commands, e-mail: axis-dev-help@ws.apache.org


[jira] Commented: (AXIS2-1135) ClassCastException in AddressingOutHandler when Rahas is engaged

Posted by "Ruchith Udayanga Fernando (JIRA)" <ji...@apache.org>.
    [ http://issues.apache.org/jira/browse/AXIS2-1135?page=comments#action_12433841 ] 
            
Ruchith Udayanga Fernando commented on AXIS2-1135:
--------------------------------------------------

Created a feature improvement in AXIOM  to add method to import an OM node : http://issues.apache.org/jira/browse/WSCOMMONS-90

When this is fixed we can fix this issue by importing nodes before adding them into the new OM structure.

Thanks,
Ruchith

> ClassCastException in AddressingOutHandler when Rahas is engaged
> ----------------------------------------------------------------
>
>                 Key: AXIS2-1135
>                 URL: http://issues.apache.org/jira/browse/AXIS2-1135
>             Project: Apache Axis 2.0 (Axis2)
>          Issue Type: Bug
>          Components: Addressing
>            Reporter: Mario A. Rodriguez
>
> I'm trying to figure out how to configure/use Rahas for WS-SecConv interactions. However, my service is failing in the MessageOut phase.
> I am receiving the following exception: (some line numbers may not match due some extra logging that I've added)
> Caused by: java.lang.ClassCastException: org.apache.axiom.om.impl.llom.OMElementImpl
> 	at org.apache.axiom.om.impl.dom.ParentNode.addChild(ParentNode.java:56)
> 	at org.apache.axis2.handlers.addressing.AddressingOutHandler.processReferenceInformation(AddressingOutHandler.java:364)
> 	at org.apache.axis2.handlers.addressing.AddressingOutHandler.addToSOAPHeader(AddressingOutHandler.java:314)
> 	at org.apache.axis2.handlers.addressing.AddressingOutHandler.processReplyTo(AddressingOutHandler.java:254)
> 	at org.apache.axis2.handlers.addressing.AddressingOutHandler.invoke(AddressingOutHandler.java:125)
> The line in question is attempting to do:                 
>         OMElement omElement = (OMElement) referenceInformation.get(key);
>          parent.addChild(omElement);   <--- exception occurs inside this call when addChild() attempts to cast omElement to Node.
> According to the Axis2 trace logs, the RequestSecurityToken request was handled successfully by Rahas, but it then gets hung up while writing the addressing headers to the response. The addressing module appears to work correctly if Rahas is not engaged.

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

---------------------------------------------------------------------
To unsubscribe, e-mail: axis-dev-unsubscribe@ws.apache.org
For additional commands, e-mail: axis-dev-help@ws.apache.org


[jira] Commented: (AXIS2-1135) ClassCastException in AddressingOutHandler when Rahas is engaged

Posted by "Ruchith Udayanga Fernando (JIRA)" <ji...@apache.org>.
    [ http://issues.apache.org/jira/browse/AXIS2-1135?page=comments#action_12434056 ] 
            
Ruchith Udayanga Fernando commented on AXIS2-1135:
--------------------------------------------------

We need further improvements to fix the AXIOM issue:

http://issues.apache.org/jira/browse/WSCOMMONS-90#action_12434046
http://issues.apache.org/jira/browse/WSCOMMONS-90#action_12434055

Then we will be able to fix this issue.

Thanks,
Ruchith

> ClassCastException in AddressingOutHandler when Rahas is engaged
> ----------------------------------------------------------------
>
>                 Key: AXIS2-1135
>                 URL: http://issues.apache.org/jira/browse/AXIS2-1135
>             Project: Apache Axis 2.0 (Axis2)
>          Issue Type: Bug
>          Components: Addressing
>            Reporter: Mario A. Rodriguez
>         Assigned To: Eran Chinthaka
>
> I'm trying to figure out how to configure/use Rahas for WS-SecConv interactions. However, my service is failing in the MessageOut phase.
> I am receiving the following exception: (some line numbers may not match due some extra logging that I've added)
> Caused by: java.lang.ClassCastException: org.apache.axiom.om.impl.llom.OMElementImpl
> 	at org.apache.axiom.om.impl.dom.ParentNode.addChild(ParentNode.java:56)
> 	at org.apache.axis2.handlers.addressing.AddressingOutHandler.processReferenceInformation(AddressingOutHandler.java:364)
> 	at org.apache.axis2.handlers.addressing.AddressingOutHandler.addToSOAPHeader(AddressingOutHandler.java:314)
> 	at org.apache.axis2.handlers.addressing.AddressingOutHandler.processReplyTo(AddressingOutHandler.java:254)
> 	at org.apache.axis2.handlers.addressing.AddressingOutHandler.invoke(AddressingOutHandler.java:125)
> The line in question is attempting to do:                 
>         OMElement omElement = (OMElement) referenceInformation.get(key);
>          parent.addChild(omElement);   <--- exception occurs inside this call when addChild() attempts to cast omElement to Node.
> According to the Axis2 trace logs, the RequestSecurityToken request was handled successfully by Rahas, but it then gets hung up while writing the addressing headers to the response. The addressing module appears to work correctly if Rahas is not engaged.

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: http://issues.apache.org/jira/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

---------------------------------------------------------------------
To unsubscribe, e-mail: axis-dev-unsubscribe@ws.apache.org
For additional commands, e-mail: axis-dev-help@ws.apache.org