Package mondrian.xmla.impl
Class DefaultXmlaServlet
java.lang.Object
javax.servlet.GenericServlet
javax.servlet.http.HttpServlet
mondrian.xmla.XmlaServlet
mondrian.xmla.impl.DefaultXmlaServlet
- All Implemented Interfaces:
Serializable,javax.servlet.Servlet,javax.servlet.ServletConfig,XmlaConstants
- Direct Known Subclasses:
MondrianXmlaServlet,Olap4jXmlaServlet
Default implementation of XML/A servlet.
- Author:
- Gang Chen
- See Also:
-
Nested Class Summary
Nested classes/interfaces inherited from class mondrian.xmla.XmlaServlet
XmlaServlet.Phase -
Field Summary
FieldsFields inherited from class mondrian.xmla.XmlaServlet
charEncoding, LOGGER, PARAM_CALLBACKS, PARAM_CHAR_ENCODING, PARAM_DATASOURCES_CONFIG, PARAM_OPTIONAL_DATASOURCE_CONFIG, xmlaHandlerFields inherited from interface mondrian.xmla.XmlaConstants
CHH_AUTHORIZATION_CODE, CHH_AUTHORIZATION_FAULT_FS, CHH_CODE, CHH_FAULT_FS, CLIENT_FAULT_FC, CONTEXT_MIME_TYPE, CONTEXT_ROLE_NAME, CONTEXT_XMLA_PASSWORD, CONTEXT_XMLA_SESSION_ID, CONTEXT_XMLA_SESSION_STATE, CONTEXT_XMLA_SESSION_STATE_BEGIN, CONTEXT_XMLA_SESSION_STATE_END, CONTEXT_XMLA_SESSION_STATE_WITHIN, CONTEXT_XMLA_USERNAME, CPOSTA_CODE, CPOSTA_FAULT_FS, CPREA_CODE, CPREA_FAULT_FS, FAULT_ACTOR, FAULT_FC_PREFIX, FAULT_FS_PREFIX, FAULT_NS_PREFIX, HSB_ACCESS_DENIED_CODE, HSB_ACCESS_DENIED_FAULT_FS, HSB_BAD_COMMAND_CODE, HSB_BAD_COMMAND_FAULT_FS, HSB_BAD_METHOD_CODE, HSB_BAD_METHOD_FAULT_FS, HSB_BAD_METHOD_NS_CODE, HSB_BAD_METHOD_NS_FAULT_FS, HSB_BAD_NON_NULLABLE_COLUMN_CODE, HSB_BAD_NON_NULLABLE_COLUMN_FAULT_FS, HSB_BAD_PROPERTIES_CODE, HSB_BAD_PROPERTIES_FAULT_FS, HSB_BAD_PROPERTIES_LIST_CODE, HSB_BAD_PROPERTIES_LIST_FAULT_FS, HSB_BAD_REQUEST_TYPE_CODE, HSB_BAD_REQUEST_TYPE_FAULT_FS, HSB_BAD_RESTRICTION_LIST_CODE, HSB_BAD_RESTRICTION_LIST_FAULT_FS, HSB_BAD_RESTRICTIONS_CODE, HSB_BAD_RESTRICTIONS_FAULT_FS, HSB_BAD_SOAP_BODY_CODE, HSB_BAD_SOAP_BODY_FAULT_FS, HSB_BAD_STATEMENT_CODE, HSB_BAD_STATEMENT_FAULT_FS, HSB_CONNECTION_DATA_SOURCE_CODE, HSB_CONNECTION_DATA_SOURCE_FAULT_FS, HSB_DISCOVER_FORMAT_CODE, HSB_DISCOVER_FORMAT_FAULT_FS, HSB_DISCOVER_UNPARSE_CODE, HSB_DISCOVER_UNPARSE_FAULT_FS, HSB_DRILL_THROUGH_FORMAT_CODE, HSB_DRILL_THROUGH_FORMAT_FAULT_FS, HSB_DRILL_THROUGH_NOT_ALLOWED_CODE, HSB_DRILL_THROUGH_NOT_ALLOWED_FAULT_FS, HSB_DRILL_THROUGH_SQL_CODE, HSB_DRILL_THROUGH_SQL_FAULT_FS, HSB_EXECUTE_QUERY_CODE, HSB_EXECUTE_QUERY_FAULT_FS, HSB_EXECUTE_UNPARSE_CODE, HSB_EXECUTE_UNPARSE_FAULT_FS, HSB_PARSE_QUERY_CODE, HSB_PARSE_QUERY_FAULT_FS, HSB_PROCESS_CODE, HSB_PROCESS_FAULT_FS, HSB_UNKNOWN_CODE, HSB_UNKNOWN_FAULT_FS, HSH_BAD_SESSION_ID_CODE, HSH_BAD_SESSION_ID_FAULT_FS, HSH_MUST_UNDERSTAND_CODE, HSH_MUST_UNDERSTAND_FAULT_FS, HSH_UNKNOWN_CODE, HSH_UNKNOWN_FAULT_FS, MONDRIAN_NAMESPACE, MSM_UNKNOWN_CODE, MSM_UNKNOWN_FAULT_FS, MUST_UNDERSTAND_FAULT_FC, NS_SOAP_ENC_1_1, NS_SOAP_ENC_1_2, NS_SOAP_ENV_1_1, NS_SOAP_ENV_1_2, NS_SOAP_SECEXT, NS_SQL, NS_XMLA, NS_XMLA_EMPTY, NS_XMLA_EX, NS_XMLA_MDDATASET, NS_XMLA_ROWSET, NS_XSD, NS_XSI, SERVER_FAULT_FC, SIE_REQUEST_STATE_CODE, SIE_REQUEST_STATE_FAULT_FS, SOAP_MUST_UNDERSTAND_ATTR, SOAP_PREFIX, UNKNOWN_ERROR_CODE, UNKNOWN_ERROR_FAULT_FS, USM_DOM_FACTORY_CODE, USM_DOM_FACTORY_FAULT_FS, USM_DOM_PARSE_CODE, USM_DOM_PARSE_FAULT_FS, USM_DOM_PARSE_IO_CODE, USM_DOM_PARSE_IO_FAULT_FS, USM_REQUEST_INPUT_CODE, USM_REQUEST_INPUT_FAULT_FS, USM_REQUEST_STATE_CODE, USM_REQUEST_STATE_FAULT_FS, USM_UNKNOWN_CODE, USM_UNKNOWN_FAULT_FS, VERSION_MISSMATCH_FAULT_FC, XMLA_BEGIN_SESSION, XMLA_END_SESSION, XMLA_SECURITY, XMLA_SESSION, XMLA_SESSION_ID -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected StringgenerateSessionId(Map<String, Object> context) protected static DocumentBuilderFactoryprotected voidhandleFault(javax.servlet.http.HttpServletResponse response, byte[][] responseSoapParts, XmlaServlet.Phase phase, Throwable t) This produces a SOAP 1.1 version Fault element - not a 1.2 version.protected voidhandleSoapBody(javax.servlet.http.HttpServletResponse response, Element[] requestSoapParts, byte[][] responseSoapParts, Map<String, Object> context) Implement to handle XML/A request.protected voidhandleSoapHeader(javax.servlet.http.HttpServletResponse response, Element[] requestSoapParts, byte[][] responseSoapParts, Map<String, Object> context) Implement to handle application specified SOAP header.voidinit(javax.servlet.ServletConfig servletConfig) Initializes servlet and XML/A handler.protected voidlogXmlaRequest(Element envElem) protected voidmarshallSoapMessage(javax.servlet.http.HttpServletResponse response, byte[][] responseSoapParts, Enumeration.ResponseMimeType responseMimeType) Implement to provide application specified SOAP marshalling algorithm.protected voidunmarshallSoapMessage(javax.servlet.http.HttpServletRequest request, Element[] requestSoapParts) Implement to provide application specified SOAP unmarshalling algorithm.Methods inherited from class mondrian.xmla.XmlaServlet
addCallback, createConnectionFactory, doPost, getBooleanInitParameter, getCallbacks, getParameter, getXmlaHandler, initCallbacks, initCharEncodingHandlerMethods inherited from class javax.servlet.http.HttpServlet
doDelete, doGet, doHead, doOptions, doPut, doTrace, getLastModified, service, serviceMethods inherited from class javax.servlet.GenericServlet
destroy, getInitParameter, getInitParameterNames, getServletConfig, getServletContext, getServletInfo, getServletName, init, log, log
-
Field Details
-
nl
-
-
Constructor Details
-
DefaultXmlaServlet
public DefaultXmlaServlet()
-
-
Method Details
-
getDocumentBuilderFactory
-
init
public void init(javax.servlet.ServletConfig servletConfig) throws javax.servlet.ServletException Description copied from class:XmlaServletInitializes servlet and XML/A handler.- Specified by:
initin interfacejavax.servlet.Servlet- Overrides:
initin classXmlaServlet- Throws:
javax.servlet.ServletException
-
unmarshallSoapMessage
protected void unmarshallSoapMessage(javax.servlet.http.HttpServletRequest request, Element[] requestSoapParts) throws XmlaException Description copied from class:XmlaServletImplement to provide application specified SOAP unmarshalling algorithm.- Specified by:
unmarshallSoapMessagein classXmlaServlet- Throws:
XmlaException
-
logXmlaRequest
-
handleSoapHeader
protected void handleSoapHeader(javax.servlet.http.HttpServletResponse response, Element[] requestSoapParts, byte[][] responseSoapParts, Map<String, Object> context) throws XmlaExceptionImplement to handle application specified SOAP header.See if there is a "mustUnderstand" header element. If there is a BeginSession element, then generate a session id and add to context Map.
Excel 2000 and Excel XP generate both a BeginSession, Session and EndSession mustUnderstand=1 in the "urn:schemas-microsoft-com:xml-analysis" namespace Header elements and a NamespaceCompatibility mustUnderstand=0 in the "http://schemas.microsoft.com/analysisservices/2003/xmla" namespace. Here we handle only the session Header elements.
We also handle the Security element.
- Specified by:
handleSoapHeaderin classXmlaServlet- Throws:
XmlaException
-
generateSessionId
-
handleSoapBody
protected void handleSoapBody(javax.servlet.http.HttpServletResponse response, Element[] requestSoapParts, byte[][] responseSoapParts, Map<String, Object> context) throws XmlaExceptionDescription copied from class:XmlaServletImplement to handle XML/A request.- Specified by:
handleSoapBodyin classXmlaServlet- Throws:
XmlaException
-
marshallSoapMessage
protected void marshallSoapMessage(javax.servlet.http.HttpServletResponse response, byte[][] responseSoapParts, Enumeration.ResponseMimeType responseMimeType) throws XmlaException Description copied from class:XmlaServletImplement to provide application specified SOAP marshalling algorithm.- Specified by:
marshallSoapMessagein classXmlaServlet- Throws:
XmlaException
-
handleFault
protected void handleFault(javax.servlet.http.HttpServletResponse response, byte[][] responseSoapParts, XmlaServlet.Phase phase, Throwable t) This produces a SOAP 1.1 version Fault element - not a 1.2 version.- Specified by:
handleFaultin classXmlaServlet
-