Here’s the reply. 2.5 months later, but better late than never.
The TLDR is, yes, WU are being overcharged, and we’re not doing anything about it in the short-medium term. There is an interesting nugget about how ‘:first item is empty’ is calculated though…
Firstly, I want to extend our sincere gratitude for your patience and for bringing this matter to our attention. It’s through feedback like yours that we’re able to delve deeper into the intricacies of our application and improve the experience for all users.
Our engineering team has conducted a thorough investigation into the unexpected behavior you reported within your application. Here’s what we’ve discovered:
When one expression in your application references another search, it introduces an additional step in the process, specifically in the “Fetching Data” phase (db_search). For example, if a condition within a repeating group checks against the first item of the group’s list (e.g., making something visible only if “The Repeating Group’s list:first item:is not empty”), and this list is populated via a search (e.g., “Do search for foos”), this operation is split into two separate searches. The first search checks the condition with an offset of 0 and a limit of 1, while the second search populates the list with an offset of 1 and a limit of N, where N represents the number of cells displayed.
From a technical standpoint, this process, while slightly inefficient, doesn’t result in duplicate data or significant issues. However, we did notice an impact on workload units (WU). Specifically, each database search incurs an overhead of 0.3 WU. In this scenario, there’s an additional 0.3 WU overhead—part of it is necessary for the search operation, but the other part represents an inefficiency we hadn’t fully accounted for until now.
Our engineering team has concluded that this is definitely something we want to continue looking into, however, any significant changes to this behavior are not anticipated to be rolled out in the short-medium term future.
Your report has had a significant impact on how we understand and calculate search-related workloads. It has prompted us to look more closely into our workload calculations, ensuring we are as efficient and transparent as possible in how resources are utilized within our application. Your experience is incredibly valuable to us, and we are committed to making continuous improvements based on the insights you and our user community provide.
Thank you again for your valuable contribution. If you have any more questions, concerns, or further feedback, please don’t hesitate to reach out. Your input is instrumental in helping us enhance our service.