This Confluence has been LDAP enabled, if you are an ASF Committer, please use your LDAP Credentials to login. Any problems file an INFRA jira ticket please.

Child pages
  • Load OpenI (Mondrian Implementation) under OFBiz

Access to add and change pages is restricted. See: https://cwiki.apache.org/confluence/display/OFBIZ/Wiki+access

Skip to end of metadata
Go to start of metadata

This is a simple walk through to load OpenI with The Apache Open for Business Project.  I chose OpenI over the implementation from Pentaho for this walk through simply on the basis that the default download uses a mysql database instead of an embeded hsql database.   This walk through will utilize the sample Foodmart Database that comes with the OpenI source because a Cube has already been created to view reports and the purpose of this is to make sure everything is set up correctly.   My personal implementation (down the road) will attempt to utilize minilang to obtain the results needed from mondrian and jpivot in a more integrated OFBiz manner that can benefit from the service engine.  It will also hopefully change the authorization to use the ofbiz login information. Anyway on to the meat.

  1. extract openi.war, mondrian.war, openi-projects.war to /hot-deploy/openi/webapp
  2. run sql script from create-foodmart-mysql.zip to create demo database
  3. create user foodmart with pasword foodmart in your database
  4. mondrian conflicts with the log4j that ships with tomcat and therefore ofbiz so, delete:
    • /hot-deploy/openi/webapp/openi/WEB-INF/lib/commons-logging.*.jar
    • /hot-deploy/openi/webapp/openi/WEB-INF/lib/log4j*.jar
    • /hot-deploy/openi/webapp/mondrian/WEB-INF/lib/commons-logging.*.jar
    • /hot-deploy/openi/webapp/mondrian/WEB-INF/lib/commons-logging-api.*.jar
    •  /hot-deploy/openi/webapp/mondrian/WEB-INF/lib/log4j*.jar
  5. add debug configurations as desired in /framework/base/config/debug.properties:
    log4j.logger.org.openi=DEBUG
    log4j.logger.com.loyaltymatrix=INFO
    log4j.logger.com.tonbeller.wcf.log.LogTag=INFO
    #change the padding of the resource from 24 to 44 so that the output is formated evenly, mondrian has some larger named resources
    log4j.appender.stdout.layout.ConversionPattern=%d (%t) [%44F:%-3L:%-5p]%x %m%n
    
  6. create /hot-deploy/openi/ofbiz-component.xml as desired:
    <ofbiz-component name="openi"
                xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
                xsi:noNamespaceSchemaLocation="http://www.ofbiz.org/dtds/ofbiz-component.xsd">
            <resource-loader name="main" type="component"/>
            <classpath type="jar" location="build/lib/*"/>
            <classpath type="dir" location="script"/>
            <classpath type="dir" location="config"/>
            <classpath type="jar" location="lib/*"/>
            <classpath type="jar" location="webapp/mondrian/WEB-INF/lib/*"/>
            <classpath type="jar" location="webapp/openi/WEB-INF/lib/*"/>
            <classpath type="jar" location="webapp/openi-projects/WEB-INF/lib/*"/>
            <webapp name="mondrian"
                title="mondrian"
                server="default-server"
                location="webapp/mondrian"
                mount-point="/mondrian"
                app-bar-display="false"/>
            <webapp name="openi"
                title="openi"
                server="default-server"
                location="webapp/openi"
                mount-point="/openi"
                app-bar-display="false"/>
            <webapp name="openi-projects"
                title="openi-projects"
                server="default-server"
                location="webapp/openi-projects"
                mount-point="/openi-projects"
                app-bar-display="false"/>
        </ofbiz-component>
    
  7. add some tomcat-users info in /framework/catalina/config/catalina-users.xml as desired:
    <tomcat-users>
          <role rolename="tomcat" />
          <role rolename="role1" />
          <role rolename="manager" />
          <role rolename="admin" />
          <user username="tomcat" password="tomcat" roles="tomcat" />
          <user username="both" password="tomcat" roles="tomcat,role1" />
          <user username="role1" password="tomcat" roles="role1" />
          <user username="admin" password="" roles="admin,manager" />
        </tomcat-users>