Axis2
  1. Axis2
  2. AXIS2-5284

NullPointerException in org.apache.axiom.om.impl.llom.OMNodeImpl.detach(OMNodeImpl.java:194)

    Details

    • Type: Bug Bug
    • Status: Resolved
    • Priority: Critical Critical
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: None
    • Component/s: None
    • Labels:
      None
    • Environment:
      Axis 2(1.1.1), Rampart 1.5, Axiom 1.2.2

      Description

      I am trying to call a web service implemented using Axis-2(1.1.1) using Rampart 1.5 security. Sometime (1 out of 7) applicaton throws following exception. I tried googling,but could not find anything helpful. It seems axiom is trying to detach some element from its parent and parent is null. But I don't understand why parent is null. I have not done anything from client which can cause this error, and if my code is at fault then the error should come everytime I execute the client but this is not the case.

      Please suggest something, it seems that it is a bug of Axis or Axiom API but not sure.

      java.lang.NullPointerException
      at org.apache.axiom.om.impl.llom.OMNodeImpl.detach(OMNodeImpl.java:194)
      at org.apache.axiom.om.impl.llom.OMElementImpl.setText(OMElementImpl.java:686)
      at com.mercury.itg.ws.core.handlers.security.OutboundSecurityContext.set(OutboundSecurityContext.java:181)
      at com.mercury.itg.ws.core.handlers.security.OutboundSecurityContext.getSecurityContext(OutboundSecurityContext.java:73)
      at org.apache.jsp.web.knta.crt.rpt.UpdateRequestSecurity_jsp.updateField(UpdateRequestSecurity_jsp.java:25)
      at org.apache.jsp.web.knta.crt.rpt.UpdateRequestSecurity_jsp._jspService(UpdateRequestSecurity_jsp.java:299)
      at org.apache.jasper.runtime.HttpJspBase.service(HttpJspBase.java:97)
      at javax.servlet.http.HttpServlet.service(HttpServlet.java:810)
      at org.apache.jasper.servlet.JspServletWrapper.service(JspServletWrapper.java:334)
      at org.apache.jasper.servlet.JspServlet.serviceJspFile(JspServlet.java:314)
      at org.apache.jasper.servlet.JspServlet.service(JspServlet.java:264)
      at javax.servlet.http.HttpServlet.service(HttpServlet.java:810)
      at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:252)
      at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
      at org.apache.catalina.core.ApplicationDispatcher.invoke(ApplicationDispatcher.java:672)
      at org.apache.catalina.core.ApplicationDispatcher.processRequest(ApplicationDispatcher.java:463)
      at org.apache.catalina.core.ApplicationDispatcher.doForward(ApplicationDispatcher.java:398)
      at org.apache.catalina.core.ApplicationDispatcher.forward(ApplicationDispatcher.java:301)
      at com.kintana.rpt.web.servlet.RunJspReport.doPost(RunJspReport.java:90)
      at javax.servlet.http.HttpServlet.service(HttpServlet.java:717)
      at javax.servlet.http.HttpServlet.service(HttpServlet.java:810)
      at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:252)
      at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
      at com.kintana.core.web.filter.MLUFilter.applyFilter(MLUFilter.java:110)
      at com.kintana.core.web.filter.BaseFilter.doFilter(BaseFilter.java:59)
      at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:202)
      at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
      at com.kintana.core.web.filter.stinger.ValidationFilter.applyFilter(ValidationFilter.java:93)
      at com.kintana.core.web.filter.stinger.ValidationFilter.doFilter(ValidationFilter.java:66)
      at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:202)
      at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
      at com.kintana.core.web.filter.MultipartRequestFilter.applyFilter(MultipartRequestFilter.java:85)
      at com.kintana.core.web.filter.BaseFilter.doFilter(BaseFilter.java:59)
      at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:202)
      at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
      at com.kintana.core.web.filter.ControlFilter.applyFilter(ControlFilter.java:825)
      at com.kintana.core.web.filter.ControlFilter.doFilter(ControlFilter.java:1318)
      at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:202)
      at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
      at com.mercury.itg.servlet.I18NFilter.doFilter(I18NFilter.java:40)
      at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:202)
      at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
      at com.kintana.core.web.filter.Log4jFilter.applyFilter(Log4jFilter.java:49)
      at com.kintana.core.web.filter.BaseFilter.doFilter(BaseFilter.java:59)
      at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:202)
      at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
      at org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFilter.java:96)
      at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:202)
      at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
      at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:213)
      at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:178)
      at org.jboss.web.tomcat.security.SecurityAssociationValve.invoke(SecurityAssociationValve.java:175)
      at org.jboss.web.tomcat.security.JaccContextValve.invoke(JaccContextValve.java:74)
      at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:126)
      at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:105)
      at org.apache.catalina.valves.AccessLogValve.invoke(AccessLogValve.java:541)
      at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:107)
      at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:148)
      at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:869)
      at org.apache.coyote.http11.Http11BaseProtocol$Http11ConnectionHandler.processConnection(Http11BaseProtocol.java:664)
      at org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:527)
      at org.apache.tomcat.util.net.LeaderFollowerWorkerThread.runIt(LeaderFollowerWorkerThread.java:80)
      at org.apache.tomcat.util.threads.ThreadPool$ControlRunnable.run(ThreadPool.java:684)
      at java.lang.Thread.run(Thread.java:619)

        Activity

        Hide
        Sagara Gunathunga added a comment -

        Mark as resolved based on last comment.

        Show
        Sagara Gunathunga added a comment - Mark as resolved based on last comment.
        Hide
        Andreas Veithen added a comment -

        With such old versions, it is unlikely that anybody will be able to say if and in which release the issue was fixed. This would require digging through a lot of history (JIRA issues, mailing lists and code), and this is not the kind of activity people in an Open Source project will spend time on.

        PS: I doubt that the issue is identical to AXIS2-3195 because the stack trace indicates that "detach" is called by "setText", and in that case the parent node (of the node on which "detach" is called) is an OMElement, not an OMDocument.

        Show
        Andreas Veithen added a comment - With such old versions, it is unlikely that anybody will be able to say if and in which release the issue was fixed. This would require digging through a lot of history (JIRA issues, mailing lists and code), and this is not the kind of activity people in an Open Source project will spend time on. PS: I doubt that the issue is identical to AXIS2-3195 because the stack trace indicates that "detach" is called by "setText", and in that case the parent node (of the node on which "detach" is called) is an OMElement, not an OMDocument.
        Hide
        Rajesh Kumar Yadav added a comment -

        Hey Andreas , looking at the version detail will you be able to confirm that this error is because of old libraries ???

        Thanks,
        Rajesh

        Show
        Rajesh Kumar Yadav added a comment - Hey Andreas , looking at the version detail will you be able to confirm that this error is because of old libraries ??? Thanks, Rajesh
        Hide
        Rajesh Kumar Yadav added a comment -

        Hi Andreas,

        Thanks alot for responding. It was my mistake that Rampart 1.5.1 is used. Actually it is Rampart 1.1.

        Show
        Rajesh Kumar Yadav added a comment - Hi Andreas, Thanks alot for responding. It was my mistake that Rampart 1.5.1 is used. Actually it is Rampart 1.1.
        Hide
        Andreas Veithen added a comment -

        Note that Rampart 1.5 was built for Axis2 1.5.1, which in turns was released with Axiom 1.2.8. I would be surprised if you are able to get the combination Axis2 1.1.1, Rampart 1.5 and Axiom 1.2.2 working together. Also note that Axis2 1.1.1 and Axiom 1.2.2 are very old releases that are completely unsupported. Please upgrade to one of the supported releases (i.e. the latest Axis2 and Rampart 1.5.x or 1.6.x versions).

        Show
        Andreas Veithen added a comment - Note that Rampart 1.5 was built for Axis2 1.5.1, which in turns was released with Axiom 1.2.8. I would be surprised if you are able to get the combination Axis2 1.1.1, Rampart 1.5 and Axiom 1.2.2 working together. Also note that Axis2 1.1.1 and Axiom 1.2.2 are very old releases that are completely unsupported. Please upgrade to one of the supported releases (i.e. the latest Axis2 and Rampart 1.5.x or 1.6.x versions).

          People

          • Assignee:
            Unassigned
            Reporter:
            Rajesh Kumar Yadav
          • Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Development