Bart Pappyn - 2011-04-26

There are problems connecting jpivot to the latest version of mondrian using xml/a. Native connection works ok.

There seems to be a problem with mondrian enforcing content type headers and jpivot not providing one.

Here is the snapshot of the logs :


13 apr 2011 12:17:31,808 ERROR  mondrian.xmla.XmlaServlet#doPost: Unknown Error when handling XML/A message
java.lang.IllegalArgumentException: Accept header 'text/html, image/gif, image/jpeg, *; q=.2, */*; q=.2' is not a supported response content type. Allowed values: text/xml, application/xml, application/json.
at mondrian.xmla.XmlaServlet.doPost(XmlaServlet.java:248)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:709)
at javax.servlet.http.HttpServlet.service(HttpServlet.java:802)
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.StandardWrapperValve.invoke(StandardWrapperValve.java:213)
at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:178)
at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:126)
at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:105)
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(Unknown Source)


Client (Jpivot side)

javax.xml.soap.SOAPException: Invalid Content-Type:text/html
at com.sun.xml.messaging.saaj.soap.MessageImpl.verify(MessageImpl.java:161)
at com.sun.xml.messaging.saaj.soap.MessageImpl.<init>(MessageImpl.java:89)
at com.sun.xml.messaging.saaj.soap.MessageFactoryImpl.createMessage(MessageFactoryImpl.java:32)
at com.sun.xml.messaging.saaj.client.p2p.HttpSOAPConnection.post(HttpSOAPConnection.java:332)
at com.sun.xml.messaging.saaj.client.p2p.HttpSOAPConnection$PriviledgedPost.run(HttpSOAPConnection.java:141)
at java.security.AccessController.doPrivileged(Native Method)
at com.sun.xml.messaging.saaj.client.p2p.HttpSOAPConnection.call(HttpSOAPConnection.java:114)
at com.tonbeller.jpivot.xmla.XMLA_SOAP.discover(XMLA_SOAP.java:1429)
at com.tonbeller.jpivot.xmla.XMLA_SOAP.discoverDS(XMLA_SOAP.java:641)
at com.tonbeller.jpivot.xmla.XMLA_SOAP.<init>(XMLA_SOAP.java:95)
at com.tonbeller.jpivot.xmla.XMLA_Model.initialize(XMLA_Model.java:144)
at com.tonbeller.jpivot.olap.model.OlapModelDecorator.initialize(OlapModelDecorator.java:132)
at com.tonbeller.jpivot.tags.OlapModelProxy$MyState.initialize(OlapModelProxy.java:77)
at com.tonbeller.jpivot.tags.StackStateManager.initializeAndShow(StackStateManager.java:76)
at com.tonbeller.jpivot.tags.OlapModelProxy.initializeAndShow(OlapModelProxy.java:160)
at com.tonbeller.jpivot.tags.OlapModelTag.doEndTag(OlapModelTag.java:81)
at org.apache.jsp.WEB_002dINF.queries.xmla_jsp._jspx_meth_jp_xmlaQuery_0(xmla_jsp.java:117)
at org.apache.jsp.WEB_002dINF.queries.xmla_jsp._jspService(xmla_jsp.java:66)