Get Free Trial
  1. API reference
Connecting to Data Source
  1. Supported data sources
  2. Connecting to other data sources
Configuring the component
  • Documentation for older versions
  • Table of contents

    Getting started with Flexmonster Accelerator

    Flexmonster Accelerator for Microsoft Analysis Services cubes is a special server-side proxy that increases data loading speeds from the server to the user’s browser. Flexmonster Accelerator works with:

    • Microsoft Analysis Services multidimensional cubes.
    • Microsoft Analysis Services tabular models.
    • Azure Analysis Services tabular models.

    When working with OLAP cubes, a browser component communicates with the server via the XMLA protocol. The XMLA protocol is heavy and exchanges a lot of excessive information – it takes too much time and memory to load and process the data.

    We replaced the XMLA protocol and use direct requests from the component to the server.

    This is our solution to two major problems that many of those who work with big data face:

    • We made big data transfer from the server to the browser incredibly fast. Our tool allows you to transfer large multidimensional data super easily and quickly. Reporting becomes more enjoyable and prompt for your end users.
    • We greatly reduced the load on the browser memory.

    The diagram below shows how Flexmonster Accelerator transfers your data to Flexmonster Pivot:

    How Flexmonster Accelerator transfers your data to Flexmonster Pivot

    There are two ways to use Flexmonster Accelerator:

    Install Flexmonster Accelerator as a Windows Service

    The main benefits of running the Accelerator as a Windows service are:

    • It runs in the background and out of sight.
    • It starts automatically on Windows startup.
    • It’s hard for a user to inadvertently quit the application.

    This guide contains the following sections:

    Prerequisites

    • Flexmonster Pivot version 2.2 or higher
    • Microsoft Analysis Services installed and configured
    • Microsoft .NET Framework 4.5.2 or higher
    • Flexmonster CLI
      Install it with the following command:
      npm install -g flexmonster-cli

    Step 1. Embed the component into your webpage

    If Flexmonster is not yet embedded, set up an empty component in your webpage:

    In pure JavaScript

    Complete the Quick start guide. Your code should look similar to the following example:

    let pivot = new Flexmonster({
        container: "pivotContainer",
        toolbar: true
    });

    In Angular

    Complete the Integration with Angular guide. Your code should look similar to the following example:

    <fm-pivot 
    [toolbar]="true">
    </fm-pivot>

    In React

    Complete the Integration with React guide. Your code should look similar to the following example:

    <FlexmonsterReact.Pivot
    toolbar={true}
    />

    In Vue

    Complete the Integration with Vue guide. Your code should look similar to the following example:

    <Pivot
    ref="pivot"
    toolbar>
    </Pivot>

    Step 2. Install Flexmonster Accelerator

    Start the installation process with the following CLI command:

    flexmonster add accelerator -i

    The flexmonster add accelerator command does the following:

    • Downloads the .zip archive with Flexmonster Accelerator.
    • Automatically unpacks the files in the current folder — as a result, the flexmonster-accelerator/ folder will appear in your current directory.

    The -i option, which stands for --install, automatically starts the installation using the Flexmonster Accelerator.msi setup file. When the installation begins, just follow the wizard.

    The flexmonster-accelerator/ folder has the following structure:

    • Flexmonster Accelerator.msi – a server-side utility that handles the connection between Microsoft Analysis Services and Flexmonster Pivot.
    • flexmonster.config – a file that contains configuration parameters for the utility (connection string, port, etc.).

    Step 3. Configure Flexmonster Accelerator on the server

    After a successful installation, run Flexmonster Accelerator Manager:

    fm-accelerator-manager

    Click the Config button to open the flexmonster.config configuration file. It contains the following parameters:

    • CONNECTION_STRING – (required) the connection string for Microsoft Analysis Services. Example: Data Source=localhost;.
    • PORToptional the port number for the proxy service endpoint. Default value: 50005.
    • CACHE_MEMORY_LIMIToptional the maximum memory size available for caching (in MB). Default value: 0 (unlimited).
    • CACHE_ENABLEDoptional indicates whether caching is enabled. Default value: true.
    • GZIPoptional indicates whether server response compression is enabled. Default value: true.
    • HTTPSoptional indicates whether the HTTPS connection is enabled. Default value: false.
    • WINDOWS_AUTHoptional indicates whether Windows authentication is enabled.
      Note: when you are changing WINDOWS_AUTH from true to false, the Windows service restart is needed to apply the changes.
      Default value: false.
    • ALLOW_ORIGINoptional the origin from which the server accepts the requests. If ALLOW_ORIGIN is set to *, requests from all origins are accepted. Note that if authentication is enabled (WINDOWS_AUTH=true), * cannot be set as the origin. In this case, specific origins must be defined. Several origins can be defined as follows: ALLOW_ORIGIN = http://localhost, https://example.com. Default value: *.

    Note: to connect to Azure Analysis Services with Flexmonster Accelerator, specify the following parameters in flexmonster.config:

    • AZURE_AUTHORITY – the Azure authority URL (e.g., https://login.microsoftonline.com/<your_domain>). Learn more in the Microsoft guide.
    • AZURE_CLIENT_ID – the client ID of the service principal registered in Azure Active Directory.
    • AZURE_CLIENT_SECRET – the client secret of the service principal registered in Azure Active Directory.

    To apply new configs, restart the Accelerator using Flexmonster Accelerator Manager: click the Stop button and then click Start.

    You can check whether the Accelerator is up and running by navigating to its URL in the browser (http://localhost:50005 by default).

    When the configuration is finished, you can close Flexmonster Accelerator Manager – the service will continue working in the background.

    Step 4. Open a port for the Accelerator in the firewall

    If you plan to allow connections to the Accelerator from outside the server, open the appropriate port in the firewall. The default port number is 50005, but it can be changed using the PORT parameter in the flexmonster.config file.

    Step 5. Configure the component

    Now it’s time to configure the client – Flexmonster Pivot Table and Charts. Let’s create a minimal configuration using the JavaScript API (replace proxyUrl, catalog and cube parameters with your specific values):

    Connect to a multidimensional model

    var pivot = new Flexmonster({
    container: "pivotContainer",
    toolbar: true,
    report: {
    dataSource: {
    type: "microsoft analysis services",

    /* URL to Flexmonster Accelerator */
    proxyUrl: "http://localhost:50005",

    /* Catalog name */
    catalog: "Adventure Works DW Standard Edition",

    /* Cube name */
    cube: "Adventure Works",

    // Flag to use the Accelerator instead of XMLA protocol binary
    binary: true
    }
    }
    });

    Connect to a tabular model

    var pivot = new Flexmonster({
    container: "pivotContainer",
    toolbar: true,
    report: {
    dataSource: {
    type: "microsoft analysis services",

    /* URL to Flexmonster Accelerator */
    proxyUrl: "http://localhost:50005",

    /* Database name */
    catalog: "Adventure Works DW Standard Edition",

    /* Model name */
    cube: "Adventure Works",

    // Flag to use the Accelerator instead of XMLA protocol binary
    binary: true
    }
    }
    });

    See the full code on JSFiddle.

    Now launch the webpage from a browser — there you go! A pivot table is embedded in your project.

    Cache control

    Usually, a cache can improve performance greatly. However, if the underlying database ever changes, the cache goes out of date. By default, caching is enabled and controlled by the Accelerator.

    It is also possible to disable the cache with the CACHE_ENABLED parameter in the flexmonster.config file:

    CACHE_ENABLED = false

    What’s next?

    You may be interested in the following articles: