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 "Brecht Yperman (JIRA)" <ji...@apache.org> on 2006/11/10 14:33:37 UTC

[jira] Created: (AXIS2-1669) NullPointerException WSDL11ToAxisServiceBuilder due to empty documentation element

NullPointerException WSDL11ToAxisServiceBuilder due to empty documentation element
----------------------------------------------------------------------------------

                 Key: AXIS2-1669
                 URL: http://issues.apache.org/jira/browse/AXIS2-1669
             Project: Apache Axis 2.0 (Axis2)
          Issue Type: Bug
          Components: kernel
    Affects Versions: nightly
         Environment: Windows XP, JRE 1.4
            Reporter: Brecht Yperman
            Priority: Minor


I get a NullPointerException in the WSDL11ToAxisServiceBuilder.

This is due to the fact that the documentation element is empty, firstChild is null.

=CODE=
// copy the documentation element content to the description Element documentationElement = wsdl4jDefinition.getDocumentationElement();
if (documentationElement != null) {
     Node firstChild = documentationElement.getFirstChild();
     String serviceDes;
     if (firstChild.getNodeType() == Node.TEXT_NODE) {
          serviceDes = firstChild.getNodeValue();
     } else {
          serviceDes = DOM2Writer.nodeToString(firstChild);
     }
     axisService.setServiceDescription(serviceDes);
}
=CODE=

For this wsdl-fragment

=WSDL=
<definitions xmlns:tns="http://www.vanos.be/webservices/iseries/isbeurscentrum" xmlns:soap12="http://schemas.xmlsoap.org/wsdl/soap12/" xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:import0="vanos:iseries:beurscentra" name="isbeurscentrum" targetNamespace="http://www.vanos.be/webservices/iseries/isbeurscentrum" xmlns="http://schemas.xmlsoap.org/wsdl/">
  <wsdl:documentation xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" />
  <types>
[...]
=WSDL=


-- 
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] Updated: (AXIS2-1669) NullPointerException WSDL11ToAxisServiceBuilder due to empty documentation element

Posted by "Davanum Srinivas (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/AXIS2-1669?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Davanum Srinivas updated AXIS2-1669:
------------------------------------

    Assignee: Deepal Jayasinghe

> NullPointerException WSDL11ToAxisServiceBuilder due to empty documentation element
> ----------------------------------------------------------------------------------
>
>                 Key: AXIS2-1669
>                 URL: https://issues.apache.org/jira/browse/AXIS2-1669
>             Project: Axis 2.0 (Axis2)
>          Issue Type: Bug
>          Components: kernel
>    Affects Versions: nightly
>         Environment: Windows XP, JRE 1.4
>            Reporter: Brecht Yperman
>         Assigned To: Deepal Jayasinghe
>            Priority: Minor
>
> I get a NullPointerException in the WSDL11ToAxisServiceBuilder.
> This is due to the fact that the documentation element is empty, firstChild is null.
> =CODE=
> // copy the documentation element content to the description Element documentationElement = wsdl4jDefinition.getDocumentationElement();
> if (documentationElement != null) {
>      Node firstChild = documentationElement.getFirstChild();
>      String serviceDes;
>      if (firstChild.getNodeType() == Node.TEXT_NODE) {
>           serviceDes = firstChild.getNodeValue();
>      } else {
>           serviceDes = DOM2Writer.nodeToString(firstChild);
>      }
>      axisService.setServiceDescription(serviceDes);
> }
> =CODE=
> For this wsdl-fragment
> =WSDL=
> <definitions xmlns:tns="http://www.vanos.be/webservices/iseries/isbeurscentrum" xmlns:soap12="http://schemas.xmlsoap.org/wsdl/soap12/" xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:import0="vanos:iseries:beurscentra" name="isbeurscentrum" targetNamespace="http://www.vanos.be/webservices/iseries/isbeurscentrum" xmlns="http://schemas.xmlsoap.org/wsdl/">
>   <wsdl:documentation xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" />
>   <types>
> [...]
> =WSDL=

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


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


[jira] Resolved: (AXIS2-1669) NullPointerException WSDL11ToAxisServiceBuilder due to empty documentation element

Posted by "Davanum Srinivas (JIRA)" <ji...@apache.org>.
     [ https://issues.apache.org/jira/browse/AXIS2-1669?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Davanum Srinivas resolved AXIS2-1669.
-------------------------------------

    Resolution: Fixed

> NullPointerException WSDL11ToAxisServiceBuilder due to empty documentation element
> ----------------------------------------------------------------------------------
>
>                 Key: AXIS2-1669
>                 URL: https://issues.apache.org/jira/browse/AXIS2-1669
>             Project: Axis 2.0 (Axis2)
>          Issue Type: Bug
>          Components: kernel
>    Affects Versions: nightly
>         Environment: Windows XP, JRE 1.4
>            Reporter: Brecht Yperman
>            Assignee: Deepal Jayasinghe
>            Priority: Minor
>
> I get a NullPointerException in the WSDL11ToAxisServiceBuilder.
> This is due to the fact that the documentation element is empty, firstChild is null.
> =CODE=
> // copy the documentation element content to the description Element documentationElement = wsdl4jDefinition.getDocumentationElement();
> if (documentationElement != null) {
>      Node firstChild = documentationElement.getFirstChild();
>      String serviceDes;
>      if (firstChild.getNodeType() == Node.TEXT_NODE) {
>           serviceDes = firstChild.getNodeValue();
>      } else {
>           serviceDes = DOM2Writer.nodeToString(firstChild);
>      }
>      axisService.setServiceDescription(serviceDes);
> }
> =CODE=
> For this wsdl-fragment
> =WSDL=
> <definitions xmlns:tns="http://www.vanos.be/webservices/iseries/isbeurscentrum" xmlns:soap12="http://schemas.xmlsoap.org/wsdl/soap12/" xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:import0="vanos:iseries:beurscentra" name="isbeurscentrum" targetNamespace="http://www.vanos.be/webservices/iseries/isbeurscentrum" xmlns="http://schemas.xmlsoap.org/wsdl/">
>   <wsdl:documentation xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" />
>   <types>
> [...]
> =WSDL=

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


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


[jira] Commented: (AXIS2-1669) NullPointerException WSDL11ToAxisServiceBuilder due to empty documentation element

Posted by "Davanum Srinivas (JIRA)" <ji...@apache.org>.
    [ https://issues.apache.org/jira/browse/AXIS2-1669?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel#action_12503146 ] 

Davanum Srinivas commented on AXIS2-1669:
-----------------------------------------

Already fixed.

thanks,
dims

> NullPointerException WSDL11ToAxisServiceBuilder due to empty documentation element
> ----------------------------------------------------------------------------------
>
>                 Key: AXIS2-1669
>                 URL: https://issues.apache.org/jira/browse/AXIS2-1669
>             Project: Axis 2.0 (Axis2)
>          Issue Type: Bug
>          Components: kernel
>    Affects Versions: nightly
>         Environment: Windows XP, JRE 1.4
>            Reporter: Brecht Yperman
>            Assignee: Deepal Jayasinghe
>            Priority: Minor
>
> I get a NullPointerException in the WSDL11ToAxisServiceBuilder.
> This is due to the fact that the documentation element is empty, firstChild is null.
> =CODE=
> // copy the documentation element content to the description Element documentationElement = wsdl4jDefinition.getDocumentationElement();
> if (documentationElement != null) {
>      Node firstChild = documentationElement.getFirstChild();
>      String serviceDes;
>      if (firstChild.getNodeType() == Node.TEXT_NODE) {
>           serviceDes = firstChild.getNodeValue();
>      } else {
>           serviceDes = DOM2Writer.nodeToString(firstChild);
>      }
>      axisService.setServiceDescription(serviceDes);
> }
> =CODE=
> For this wsdl-fragment
> =WSDL=
> <definitions xmlns:tns="http://www.vanos.be/webservices/iseries/isbeurscentrum" xmlns:soap12="http://schemas.xmlsoap.org/wsdl/soap12/" xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:import0="vanos:iseries:beurscentra" name="isbeurscentrum" targetNamespace="http://www.vanos.be/webservices/iseries/isbeurscentrum" xmlns="http://schemas.xmlsoap.org/wsdl/">
>   <wsdl:documentation xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" />
>   <types>
> [...]
> =WSDL=

-- 
This message is automatically generated by JIRA.
-
You can reply to this email to add a comment to the issue online.


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