Uploaded image for project: 'Jenkins'
  1. Jenkins
  2. JENKINS-23257

Non well-formed response from JIRA error is hard to diagnose

    XMLWordPrintable

Details

    Description

      My build just started failing yesterday after I pushed a change attached to a closed ticket (in my current sprint that i just checked in but it needed a tweak). It seems that Jira is returning invalid xml now when I try to do this causing the build to fail. I had to remove the Jira plugin to keep working.

      [success] Total time: 31 s, completed May 29, 2014 5:27:12 PM
      Build step 'Build using sbt' changed build result to SUCCESS
      [JIRA] Updating issues using workflow action Close Issue.
      [JIRA] JQL: project = Grocery and status in (Resolved, Staged)
      FATAL: ; nested exception is:
      org.xml.sax.SAXParseException; lineNumber: 17; columnNumber: 47; Character reference "&#
      

      Full stack

      [success] Total time: 31 s, completed May 29, 2014 5:27:12 PM 
      Build step 'Build using sbt' changed build result to SUCCESS 
      [JIRA] Updating issues using workflow action Close Issue. 
      [JIRA] JQL: project = Grocery and status in (Resolved, Staged) 
      FATAL: ; nested exception is: 
      org.xml.sax.SAXParseException; lineNumber: 17; columnNumber: 47; Character reference "&# 
      AxisFault 
      faultCode: {http://schemas.xmlsoap.org/soap/envelope/}Server.userException 
      faultSubcode: 
      faultString: org.xml.sax.SAXParseException; lineNumber: 17; columnNumber: 47; Character reference "&# 
      faultActor: 
      faultNode: 
      faultDetail: 
      {http://xml.apache.org/axis/}stackTrace:org.xml.sax.SAXParseException; lineNumber: 17; columnNumber: 47; Character reference "&# 
      at com.sun.org.apache.xerces.internal.util.ErrorHandlerWrapper.createSAXParseException(Unknown Source) 
      at com.sun.org.apache.xerces.internal.util.ErrorHandlerWrapper.fatalError(Unknown Source) 
      at com.sun.org.apache.xerces.internal.impl.XMLErrorReporter.reportError(Unknown Source) 
      at com.sun.org.apache.xerces.internal.impl.XMLErrorReporter.reportError(Unknown Source) 
      at com.sun.org.apache.xerces.internal.impl.XMLScanner.reportFatalError(Unknown Source) 
      at com.sun.org.apache.xerces.internal.impl.XMLScanner.scanCharReferenceValue(Unknown Source) 
      at com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl$FragmentContentDriver.next(Unknown Source) 
      at com.sun.org.apache.xerces.internal.impl.XMLDocumentScannerImpl.next(Unknown Source) 
      at com.sun.org.apache.xerces.internal.impl.XMLNSDocumentScannerImpl.next(Unknown Source) 
      at com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl.scanDocument(Unknown Source) 
      at com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(Unknown Source) 
      at com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(Unknown Source) 
      at com.sun.org.apache.xerces.internal.parsers.XMLParser.parse(Unknown Source) 
      at com.sun.org.apache.xerces.internal.parsers.AbstractSAXParser.parse(Unknown Source) 
      at com.sun.org.apache.xerces.internal.jaxp.SAXParserImpl$JAXPSAXParser.parse(Unknown Source) 
      at com.sun.org.apache.xerces.internal.jaxp.SAXParserImpl.parse(Unknown Source) 
      at org.apache.axis.encoding.DeserializationContext.parse(DeserializationContext.java:227) 
      at org.apache.axis.SOAPPart.getAsSOAPEnvelope(SOAPPart.java:696) 
      at org.apache.axis.Message.getSOAPEnvelope(Message.java:435) 
      at org.apache.axis.handlers.soap.MustUnderstandChecker.invoke(MustUnderstandChecker.java:62) 
      at org.apache.axis.client.AxisClient.invoke(AxisClient.java:206) 
      at org.apache.axis.client.Call.invokeEngine(Call.java:2784) 
      at org.apache.axis.client.Call.invoke(Call.java:2767) 
      at org.apache.axis.client.Call.invoke(Call.java:2443) 
      at org.apache.axis.client.Call.invoke(Call.java:2366) 
      at org.apache.axis.client.Call.invoke(Call.java:1812) 
      at hudson.plugins.jira.soap.JirasoapserviceV2SoapBindingStub.getIssuesFromJqlSearch(JirasoapserviceV2SoapBindingStub.java:7422) 
      at hudson.plugins.jira.JiraSession.getIssuesFromJqlSearch(JiraSession.java:135) 
      at hudson.plugins.jira.JiraSite.progressMatchingIssues(JiraSite.java:487) 
      at hudson.plugins.jira.JiraIssueUpdateBuilder.perform(JiraIssueUpdateBuilder.java:96) 
      at hudson.tasks.BuildStepMonitor$1.perform(BuildStepMonitor.java:20) 
      at hudson.model.AbstractBuild$AbstractBuildExecution.perform(AbstractBuild.java:795) 
      at hudson.model.Build$BuildExecution.build(Build.java:199) 
      at hudson.model.Build$BuildExecution.doRun(Build.java:160) 
      at hudson.model.AbstractBuild$AbstractBuildExecution.run(AbstractBuild.java:576) 
      at hudson.model.Run.execute(Run.java:1665) 
      at hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:46) 
      at hudson.model.ResourceController.execute(ResourceController.java:88) 
      at hudson.model.Executor.run(Executor.java:246)
      
      {http://xml.apache.org/axis/}hostname:jenkins-grocery
      
      org.xml.sax.SAXParseException; lineNumber: 17; columnNumber: 47; Character reference "&# 
      at org.apache.axis.AxisFault.makeFault(AxisFault.java:101) 
      at org.apache.axis.SOAPPart.getAsSOAPEnvelope(SOAPPart.java:701) 
      at org.apache.axis.Message.getSOAPEnvelope(Message.java:435) 
      at org.apache.axis.handlers.soap.MustUnderstandChecker.invoke(MustUnderstandChecker.java:62) 
      at org.apache.axis.client.AxisClient.invoke(AxisClient.java:206) 
      at org.apache.axis.client.Call.invokeEngine(Call.java:2784) 
      at org.apache.axis.client.Call.invoke(Call.java:2767) 
      at org.apache.axis.client.Call.invoke(Call.java:2443) 
      at org.apache.axis.client.Call.invoke(Call.java:2366) 
      at org.apache.axis.client.Call.invoke(Call.java:1812) 
      at hudson.plugins.jira.soap.JirasoapserviceV2SoapBindingStub.getIssuesFromJqlSearch(JirasoapserviceV2SoapBindingStub.java:7422) 
      at hudson.plugins.jira.JiraSession.getIssuesFromJqlSearch(JiraSession.java:135) 
      at hudson.plugins.jira.JiraSite.progressMatchingIssues(JiraSite.java:487) 
      at hudson.plugins.jira.JiraIssueUpdateBuilder.perform(JiraIssueUpdateBuilder.java:96) 
      at hudson.tasks.BuildStepMonitor$1.perform(BuildStepMonitor.java:20) 
      at hudson.model.AbstractBuild$AbstractBuildExecution.perform(AbstractBuild.java:795) 
      at hudson.model.Build$BuildExecution.build(Build.java:199) 
      at hudson.model.Build$BuildExecution.doRun(Build.java:160) 
      at hudson.model.AbstractBuild$AbstractBuildExecution.run(AbstractBuild.java:576) 
      at hudson.model.Run.execute(Run.java:1665) 
      at hudson.model.FreeStyleBuild.run(FreeStyleBuild.java:46) 
      at hudson.model.ResourceController.execute(ResourceController.java:88) 
      at hudson.model.Executor.run(Executor.java:246) 
      Caused by: org.xml.sax.SAXParseException; lineNumber: 17; columnNumber: 47; Character reference "&# 
      at com.sun.org.apache.xerces.internal.util.ErrorHandlerWrapper.createSAXParseException(Unknown Source) 
      at com.sun.org.apache.xerces.internal.util.ErrorHandlerWrapper.fatalError(Unknown Source) 
      at com.sun.org.apache.xerces.internal.impl.XMLErrorReporter.reportError(Unknown Source) 
      at com.sun.org.apache.xerces.internal.impl.XMLErrorReporter.reportError(Unknown Source) 
      at com.sun.org.apache.xerces.internal.impl.XMLScanner.reportFatalError(Unknown Source) 
      at com.sun.org.apache.xerces.internal.impl.XMLScanner.scanCharReferenceValue(Unknown Source) 
      at com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl$FragmentContentDriver.next(Unknown Source) 
      at com.sun.org.apache.xerces.internal.impl.XMLDocumentScannerImpl.next(Unknown Source) 
      at com.sun.org.apache.xerces.internal.impl.XMLNSDocumentScannerImpl.next(Unknown Source) 
      at com.sun.org.apache.xerces.internal.impl.XMLDocumentFragmentScannerImpl.scanDocument(Unknown Source) 
      at com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(Unknown Source) 
      at com.sun.org.apache.xerces.internal.parsers.XML11Configuration.parse(Unknown Source) 
      at com.sun.org.apache.xerces.internal.parsers.XMLParser.parse(Unknown Source) 
      at com.sun.org.apache.xerces.internal.parsers.AbstractSAXParser.parse(Unknown Source) 
      at com.sun.org.apache.xerces.internal.jaxp.SAXParserImpl$JAXPSAXParser.parse(Unknown Source) 
      at com.sun.org.apache.xerces.internal.jaxp.SAXParserImpl.parse(Unknown Source) 
      at org.apache.axis.encoding.DeserializationContext.parse(DeserializationContext.java:227) 
      at org.apache.axis.SOAPPart.getAsSOAPEnvelope(SOAPPart.java:696) 
      ... 21 more
      

      Attachments

        Activity

          enalmada Adam Lane added a comment -

          I assume this is a bug in the jira soap api returning invalid xml to the plugin so I also created a ticket with JIRA. If you can provide the api call that is returning the bad data that might help them fix quicker:
          https://jira.atlassian.com/browse/JRA-38555

          enalmada Adam Lane added a comment - I assume this is a bug in the jira soap api returning invalid xml to the plugin so I also created a ticket with JIRA. If you can provide the api call that is returning the bad data that might help them fix quicker: https://jira.atlassian.com/browse/JRA-38555

          Unfortunately it's Axis that makes these calls. Does anyone know how to configure logging etc for Axis so that it reports the URL its hitting and the response it's seeing?

          One possibility is that the server is returning HTML instead of SOAP XML.

          kohsuke Kohsuke Kawaguchi added a comment - Unfortunately it's Axis that makes these calls. Does anyone know how to configure logging etc for Axis so that it reports the URL its hitting and the response it's seeing? One possibility is that the server is returning HTML instead of SOAP XML.
          enalmada Adam Lane added a comment - - edited

          FYI There was a comment made in Atlassian jira about this:

          We are no longer actively developing JIRA's XML-RPC or SOAP APIs. We recommend using our REST APIs instead. Please see https://developer.atlassian.com/display/JIRADEV/_JIRA+API+Status for the current status of our various APIs.
          

          The api status link says they wont be fixing any bugs in anything but REST api:

          XML-RPC
          Deprecated in JIRA 6.0.  This means that we will not add new features nor fix bugs related to the XML-RPC API during the JIRA 6.x lifecycle. Read the deprecation announcement for more information.
          

          ...so they closed the bug ticket. Seems like this jenkins jira plugin ticket needs to be converted to a migrate to supported REST API?

          enalmada Adam Lane added a comment - - edited FYI There was a comment made in Atlassian jira about this: We are no longer actively developing JIRA's XML-RPC or SOAP APIs. We recommend using our REST APIs instead. Please see https://developer.atlassian.com/display/JIRADEV/_JIRA+API+Status for the current status of our various APIs. The api status link says they wont be fixing any bugs in anything but REST api: XML-RPC Deprecated in JIRA 6.0. This means that we will not add new features nor fix bugs related to the XML-RPC API during the JIRA 6.x lifecycle. Read the deprecation announcement for more information. ...so they closed the bug ticket. Seems like this jenkins jira plugin ticket needs to be converted to a migrate to supported REST API?

          The current plugin version is using REST API. Do you think we can close this bug?

          warden Radek Antoniuk added a comment - The current plugin version is using REST API. Do you think we can close this bug?
          enalmada Adam Lane added a comment -

          Yes, I suspect so. Please close with whatever status you see fit.

          enalmada Adam Lane added a comment - Yes, I suspect so. Please close with whatever status you see fit.

          Closing as resolved by switching to REST API in v.2.0.

          warden Radek Antoniuk added a comment - Closing as resolved by switching to REST API in v.2.0.

          People

            Unassigned Unassigned
            enalmada Adam Lane
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: