Class MondrianXmlaServlet

java.lang.Object
javax.servlet.GenericServlet
javax.servlet.http.HttpServlet
All Implemented Interfaces:
Serializable, javax.servlet.Servlet, javax.servlet.ServletConfig, XmlaConstants
Direct Known Subclasses:
DynamicDatasourceXmlaServlet

public class MondrianXmlaServlet extends DefaultXmlaServlet
Extension to XmlaServlet that instantiates a Mondrian engine.
Author:
jhyde
See Also:
  • Field Details

  • Constructor Details

    • MondrianXmlaServlet

      public MondrianXmlaServlet()
  • Method Details

    • createConnectionFactory

      protected XmlaHandler.ConnectionFactory createConnectionFactory(javax.servlet.ServletConfig servletConfig) throws javax.servlet.ServletException
      Specified by:
      createConnectionFactory in class XmlaServlet
      Throws:
      javax.servlet.ServletException
    • destroy

      public void destroy()
      Specified by:
      destroy in interface javax.servlet.Servlet
      Overrides:
      destroy in class javax.servlet.GenericServlet
    • makeContentFinder

      protected RepositoryContentFinder makeContentFinder(String dataSources)
      Creates a callback for reading the repository. Derived classes may override.
      Parameters:
      dataSources - Data sources
      Returns:
      Callback for reading repository
    • makeCatalogLocator

      protected CatalogLocator makeCatalogLocator(javax.servlet.ServletConfig servletConfig)
      Make catalog locator. Derived classes can roll their own.
      Parameters:
      servletConfig - Servlet configuration info
      Returns:
      Catalog locator
    • makeDataSourcesUrl

      protected String makeDataSourcesUrl(javax.servlet.ServletConfig servletConfig)
      Creates the URL where the data sources file is to be found.

      Derived classes can roll their own.

      If there is an initParameter called "DataSourcesConfig" get its value, replace any "${key}" content with "value" where "key/value" are System properties, and try to create a URL instance out of it. If that fails, then assume its a real filepath and if the file exists then create a URL from it (but only if the file exists). If there is no initParameter with that name, then attempt to find the file called "datasources.xml" under "WEB-INF/" and if it exists, use it.

      Parameters:
      servletConfig - Servlet config
      Returns:
      URL where data sources are to be found