Modes
FlexMeasures can be run in specific modes (see the FLEXMEASURES_MODE config setting). This is useful for certain special situations. Two are supported out of the box and we document here how FlexMeasures behaves differently in these modes.
Demo
In this mode, the server is assumed to be used as a demonstration tool. The following adaptations therefore happen in the UI:
[UI] Logged-in users can view queues on the demo server (usually only admins can do that)
[UI] Demo servers often display login credentials, so visitors can try out functionality. Use the FLEXMEASURES_PUBLIC_DEMO_CREDENTIALS config setting to do this.
Play
In this mode, the server is assumed to be used to run simulations.
[UI] On the asset page, the
sensors_to_showattribute can be used to show any sensor from any account, rather than only sensors from assets owned by the user’s organization.[API] The API is not rate-limited, as a simulation is expected to trigger scheduling and forecasting in a tight loop (see Plans and rate-limiting). Note that this applies to the play mode only: a development server rate-limits like production does.
Note
A former feature of play mode is now a separate config setting. To allow overwriting existing data when saving data to the database, use FLEXMEASURES_ALLOW_DATA_OVERWRITE.