Hi Neville,
As per my understanding, answer is "query separately for each user". Lobby element refresh is connected with sessions. So, a database query is executed independently at each interval per user session.
Example: I am having a list element in a lobby page with refresh rate 30 sec. Every 30 sec you can observer below perform_exec_db_query per user session.
<perform_exec_db_query>
<parameters>
<sql_command>select (TASK_ID) AS TASK_ID_ALS,(PLACE_ID_CUST) AS PLACE_ID_CUST_ALS from task where place_id_cust = 'A100' order by task_id</sql_command>
<light>false</light>
</parameters>
<authentication>
<session_info>
<session_id>NdcUykDiVy+y0txbLM9BL5lhUDZaU+jzPZAJ3FZvcSZQoyMRjaDiJQZv7NDWbp2TC3bFkx7clXXzd6kthmy3OA==DPKxm9zy0T/waif2AX6nfA==g3YW/QTPxrpcEtJ4CMAomQ==</session_id>
<token_id>aEJ+XcOHwK6eUCOOESkNUvMqzadJaQb2Y3ixcM3NnY6m/YABAvQ07TZKSdk4kEzNhctbTZ608a9MeycH+PQ8HBguwJaQSb49KSNgiPr1rHORVILhFb1ibqyFLGzLSwJR</token_id>
</session_info>
</authentication>
</perform_exec_db_query>
Regards,
Sanjeewa
Hi Sanjeewa,
Thanks for clarifying.
It maybe beneficial from performance point of view if FSM can run the query once and distribute the results among the users. I have seen a few reporting applications doing this. For e.g., SSRS server reports have the option of pulling the data from cache and it is particularly useful when we have too many concurrent users or the query is too complex. Similarly, the Power BI services has the option of refreshing data at predefined intervals and the users will not initiate separate queries pulling data from the production database.
Thanks
Regards
Neville