Overview of Web SDK

In this section, we introduce MicroStrategy web architecture, plugin architecture, deploying SDK, and configuring Web Customization Editor (WCE) both in Linux and in Windows, and discuss some best practices for customizations and upgrades.

MicroStrategy Web architecture

The layers that make up the MicroStrategy Web application are as follows:

  • XML API layer
  • Web Objects layer
  • Web Beans layer
  • Web Transforms layer
  • Application Objects layer
  • Presentation layer

Application programming interface (API) is an interface that enables the user to access information from other applications, and allows the user to integrate services to their own applications. A Web Bean is a Java class that contains business logic and accepts no parameters, which includes JavaBean and Enterprise JavaBean:

MicroStrategy Web architecture

MicroStrategy plugin architecture

MicroStrategy separates its main codes from plugins. Extra functionalities and customizations are implemented by using plugins, without modifying its main codes. Plugins are organized as subfolders in the plugins folder:

MicroStrategy plugin architecture

Deploying SDK and configuring WCE in Linux

Let us deploy the WCE plugin in order to change the appearance of MicroStrategy Web:

  1. We can download MicroStrategy SDK from http://community.microstrategy.com/t5/custom/page/page-id/developer-zone.
  2. Moreover, we need Eclipse in order to work with MicroStrategy SDK. Let's download Eclipse SDK using this URL: http://archive.eclipse.org/eclipse/downloads/drops4/R-4.4.2-201502041700/.

    Choose Red Hat Linux for Windows: eclipse-SDK-4.4.2-linux-gtk-x86_64.tar.gz

  3. Create a folder for MicroStrategy SDK:
          #cd /root/
          #mkdir WebSDK
    
  4. Extract eclipse-SDK-4.4.2-linux-gtk-x86_64.tar.gz to /root/WebSDK. As a result, we get Eclipse.
  5. Extract MSTRSDK.zip to /root/WebSDK and then find JAR files:
    # cd /root/WebSDK/SDK/tools/WebCustomizationEditor
    
  6. Extract com.microstrategy.web.sdk.webcustomization.zip into this folder:
    # cd /root/WebSDK/SDK/tools/WebCustomizationEditor/plugins
    

    Then copy the JAR file to /root/WebSDK/eclipse/plugins.

  7. In addition, we should deploy Apache Ant.

    Tip

    Apache Ant is a Java library and command-line tool that helps build software.

    Go to https://ant.apache.org/bindownload.cgi and download zip archive: apache-ant-1.9.6-bin.zip. Extract to /root/WebSDK.

  8. Finally, we need to deploy Apache Axis 2.

    Tip

    Apache Axis2TM is a Web Services/SOAP/WSDL engine, the successor to the widely used Apache Axis SOAP stack. There are two implementations of the Apache Axis2 Web services engine-Apache Axis2/Java and Apache Axis2/C

    Go to http://axis.apache.org/axis2/java/core/download.html.

  9. Choose Binary distribution - axis2-1.7.1-bin.zip and extract to /root/WebSDK.
  10. Now we can run Eclipse in /root/WebSDK/eclipse:
    # ./eclipse
    
  11. Set preference for MicroStrategy Plugin. Go to Window | Preferences in order to add settings to the MicroStrategy plugin accordingly:

    Deploying SDK and configuring WCE in Linux

  12. Go to Web Services and fill in the information, like in the following screenshot:

    Deploying SDK and configuring WCE in Linux

  13. Now you can go to Window | Show View | Other and choose MicroStrategy:

    Deploying SDK and configuring WCE in Linux

As a result, we deployed MicroStrategy customization plugin into Eclipse and now we are able to modify MicroStrategy Web.

Installing SDK and configuring WCE in Windows

If you are in a Windows environment, you need to download Web SDK (MSTRSDK.zip) from MicroStrategy Community (https://community.microstrategy.com/), unzip it, then cut and paste the SDK folder into the MicroStrategy installation folder:

Installing SDK and configuring WCE in Windows

The WCE is a tool provided by MicroStrategy to make developing easier, by automatically creating plugins inside the plugins folder, according to your customization requirements. It is possible to create plugins without WCE, but it will be hard and prone to mistakes. WCE is essentially a plugin of Eclipse Integrated Development Environment (IDE). It can automatically create folders and template files, so that the user can concentrate on the critical parts of the code.

The plugin is included in the SDK folder as a ZIP file. You need to locate it in /SDK/tools/com.microstrategy.web.sdk.webcustomization.zip:

Installing SDK and configuring WCE in Windows

Unzip it, and put it into the Eclipse plugins folder:

Installing SDK and configuring WCE in Windows

Best practices for customizations and upgrades

There are some tips to follow that will save you time and increase your work's durability:

  • Always encapsulate all the changes in plugin inside plugins
  • Do not change any code outside the plugins folder
  • Before an upgrade, always back up the content of the plugins folder, and redeploy the plugins folder after the upgrade
  • After upgrading, remember to check if there is a new version of WCE
..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset