0

Anyone implemented custom querylimit timeOut during runtime while retrieving data to the CUBE.

Can I do this via xml configuration for each user.

Thanks in advance Chris

chris
  • 1
  • 1

1 Answers1

0

Since it is a context value, there are several ways to set a custom queryTimeLimit

Via XML:

  • You can set one globally in your cube definition, in the shared contexts:

    <sharedContexts>
            ....
        <queriesTimeLimit seconds="30" />
    </sharedContexts>
    
  • You can use the role mapping, and add a timeout for each role:

    <pivotsRoles id="EquityDerivativesCube">
     .....
    
        <queriesTimeLimit seconds="1"/>
    </pivotsRoles>
    

Via code:

You can override any context value using for a given user, by calling any of the two function, depending on your needs, in an authenticated thread (typically, one can call these methods through an authenticated Web-Service).

 /**
  * Set a contextValue associated with one ActivePivot instance
  */
 IContextValueManager.setContextValue(String pivotId, IContextValue contextValue);

 /**
  * Set a contextValue for any pivot instance.
  */
 IContextValueManager.setGlobalContextValue(IContextValue contextValue);

The corresponding context value interface is IQueriesTimeLimit.

Via ActivePivot Live:

A end-user can define its own context values: right click on the view, click query editor, and at the bottom of the pop-up, click "Add a context value" and add the queriesTimeLimit context value, with the desired timeout value in seconds.