Overview
Performance optimization is critical before deploying any Farseer model to production. It's not enough to test with a single user — each model needs to be tested with the expected volume of data and concurrent user load in a realistic environment.
Detecting Performance Bottlenecks
Before testing in a real environment, use Farseer's built-in optimization tools. Then conduct real-world testing:
Concurrent User Testing
Mobilize internal and client resources in stages:
Stage 1: 10 concurrent users
Stage 2: 20 concurrent users
Stage 3: Expected production user count
Focus on common scenarios — data entry and data retrieval in sheets and dashboards.
Common Performance Problem Classes
Observations typically fall into these categories:
Application opens slowly
Data retrieval in sheets/dashboards is slow
Data entry in cells is slow
Initial model loading is slow
Each class can have entirely different causes and solutions — from poor model design, excessive data volumes, to overly ambitious interface design.
Built-in Performance Tools
Variable Metrics
Farseer provides a quick analysis tool showing each variable's calculation time and memory cell count. Access it from the Metrics view in the top-right corner of the Variables module.
The key ratio to watch: Cell Count / Duration. A disproportionately high duration compared to cell count is a strong indicator of a problem — such as unwanted dimension fanouts or inefficient formulas.
Note: The model must be fully evaluated before Variable Metrics can display data.
Evaluation Logs
If Variable Metrics can't be accessed (e.g., the evaluator failed), use the direct evaluation log. It shows memory overflows and other issues that cause the evaluator to stop the calculation.
Variable Execution Order
Track the sequence of variable execution by expanding the "Used in X formulas" section in a variable's edit dialog. Following this chain helps you detect dimension mismatches and unwanted fanouts.
Addressing Each Problem Class
1. Application Opens Slowly
Is it constantly slow or only periodically?
If periodic, is it related to time of day or number of active users?
Contact Farseer technical support with your findings.
2. Slow Data Retrieval
Is it slow for one user or multiple concurrent users?
Complex sheets directly affect server stress — consider simplifying the user experience by breaking complex views into smaller, focused sheets.
3. Slow Data Entry
Several possible causes:
Variable has too large dimensionality — consider breaking it into smaller variables
Entry triggers cascading calculations — analyze the variable tree for unwanted fanouts. Top-down entries at high aggregation levels can trigger changes to hundreds of thousands of cells. Consider:
Activating Constrained Top-Down to restrict high-level entries
Using Template Formulas for structured data entry
Breaking the calculation chain with Calculate on Demand variables
Setting certain hierarchy levels to Read Only
4. Slow Initial Model Loading
Check for dimension fanouts using Variable Metrics
Avoid unnecessary calculations on Actual data — import pre-calculated values instead
Ensure calculations on imported Actual data use Calculate on Demand variables
Best Practices for Performance
Modularize your model. Break it into smaller modules that aggregate and reduce dimensionality toward final output variables.
Use Read Only aggressively. Set calculation variables to Read Only to prevent accidental entries that trigger unwanted recalculations.
Minimize input vectors. Avoid allowing data entry on variables with complex formulas.
Watch for dimension fanouts. Unwanted fanouts in variable formulas are the #1 suspect for poor performance.
Simplify user interfaces:
Avoid entries at high aggregation levels that trigger cascading calculations
Minimize filter usage on large-dimensionality sheets
Avoid mixing reporting columns with input masks on high-dimensionality sheets — use reporting elements in rows instead
Import pre-calculated actuals. Don't perform unnecessary calculations within Farseer when the data can be calculated externally.
Use measures for reports. For displaying reports in different currencies or calculating various indices, measures execute on demand and don't participate in initial calculations.
Don't replicate Excel blindly. Always analyze dimensions and required variables before migrating an Excel model into Farseer.
