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:
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:
The diagram below shows how Flexmonster Accelerator transfers your data to Flexmonster Pivot:
There are two ways to use Flexmonster Accelerator:
The main benefits of running the Accelerator as a Windows service are:
This guide contains the following sections:
npm install -g flexmonster-cli
If Flexmonster is not yet embedded, set up an empty component in your webpage:
Complete the Integrating Flexmonster guide. Your code should look similar to the following example:
let pivot = new Flexmonster({ container: "pivotContainer", componentFolder: "node_modules/flexmonster/", toolbar: true });
Complete the Integration with Angular guide. Your code should look similar to the following example:
<fm-pivot [toolbar]="true"> </fm-pivot>
Complete the Integration with React guide. Your code should look similar to the following example:
<FlexmonsterReact.Pivot toolbar={true} />
Complete the Integration with Vue guide. Your code should look similar to the following example:
<Pivot toolbar />
Start the installation process with the following CLI command:
flexmonster add accelerator -i
The flexmonster add accelerator
command does the following:
.zip
archive with Flexmonster Accelerator.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.).After a successful installation, run Flexmonster Accelerator Manager:
Click the Config button to open the flexmonster.config
configuration file. It contains the following parameters:
Note: to connect to Azure Analysis Services with Flexmonster Accelerator, specify the following parameters in flexmonster.config
:
Parameter | Description |
---|---|
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.
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.
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):
var pivot = new Flexmonster({ container: "pivotContainer", componentFolder: "node_modules/flexmonster/", 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 } } });
var pivot = new Flexmonster({ container: "pivotContainer", componentFolder: "node_modules/flexmonster/", 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.
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
You may be interested in the following articles: