VOOZH about

URL: https://thenewstack.io/navigating-the-high-concurrency-challenges-of-user-facing-analytics/

⇱ Navigating the High-Concurrency Challenges of User-Facing Analytics - The New Stack


TNS
SUBSCRIBE
Join our community of software engineering leaders and aspirational developers. Always stay in-the-know by getting the most important news and exclusive content delivered fresh to your inbox to learn more about at-scale software development.
REQUIRED
It seems that you've previously unsubscribed from our newsletter in the past. Click the button below to open the re-subscribe form in a new tab. When you're done, simply close that tab and continue with this form to complete your subscription.
The New Stack does not sell your information or share it with unaffiliated third parties. By continuing, you agree to our Terms of Use and Privacy Policy.
Welcome and thank you for joining The New Stack community!
Please answer a few simple questions to help us deliver the news and resources you are interested in.
REQUIRED
REQUIRED
REQUIRED
REQUIRED
REQUIRED
Great to meet you!
Tell us a bit about your job so we can cover the topics you find most relevant.
REQUIRED
REQUIRED
REQUIRED
REQUIRED
REQUIRED
Welcome!

We’re so glad you’re here. You can expect all the best TNS content to arrive Monday through Friday to keep you on top of the news and at the top of your game.

What’s next?

Check your inbox for a confirmation email where you can adjust your preferences and even join additional groups.

Follow TNS on your favorite social media networks.

Become a TNS follower on LinkedIn.

Check out the latest featured and trending stories while you wait for your first TNS newsletter.

PREV
1 of 2
NEXT
VOXPOP
As a JavaScript developer, what non-React tools do you use most often?
Angular
0%
Astro
0%
Svelte
0%
Vue.js
0%
Other
0%
I only use React
0%
I don't use JavaScript
0%
Thanks for your opinion! Subscribe below to get the final results, published exclusively in our TNS Update newsletter:
NEW! Try Stackie AI
From clobbered drafts to real-time sync
Apr 14th 2026 10:00am, by David Moore
TypeScript 6.0 RC arrives as a bridge to a faster future
Mar 14th 2026 9:00am, by Darryl K. Taft
Mastra empowers web devs to build AI agents in TypeScript
Jan 28th 2026 11:00am, by Loraine Lawson
2023-09-28 06:52:23
Navigating the High-Concurrency Challenges of User-Facing Analytics
sponsor-celerdata,sponsored-post-contributed,
Data

Navigating the High-Concurrency Challenges of User-Facing Analytics

This article explores different strategies for managing high-concurrent user-facing analytics.
Sep 28th, 2023 6:52am by Sida Shen
👁 Featued image for: Navigating the High-Concurrency Challenges of User-Facing Analytics
Feature image by Kanenori from Pixabay.
CelerData sponsored this post.

User-facing analytics offers end users direct access to data analytics tools, freeing them from the need to rely on data specialists or IT teams to generate insights. While this democratizes data access and usage, it also presents a challenge: how to manage high concurrency in real time. This article explores different strategies to address this challenge with user-facing analytics.

CelerData helps enterprises accelerate business growth with a unified analytics platform that delivers 3X the performance of any other solution on the market while reducing operating costs by up to 80%. Powered by StarRocks, CelerData is used worldwide by leading brands including Airbnb and Lenovo.
Learn More
The latest from CelerData

Why User-Facing Analytics Requires High Concurrency

Let’s look at the social media platform Xiaohongshu as an example of high concurrency user-facing analytics. The bulk of Xiaohongshu’s revenue is derived from advertising. This platform offers advertisers a place to create custom real-time dashboards to monitor the performance of their ads. Each dashboard is filled with graphs and summaries — each translates to one or multiple SQL queries sent to the underlying database. When an advertiser checks the engagement rates or demographic distribution of ad viewers, several queries instantly fetch and process this data.

Now, scale this up to accommodate hundreds of thousands of advertisers, each with unique campaigns and multiple dashboard interactions. The sheer volume of simultaneous queries — whether from refreshing pages, switching between metrics or merely accessing the dashboard — results in a large number of queries per second (QPS).

This transformation toward high-concurrency user-facing analytics isn’t unique to Xiaohongshu or its industry. Across diverse sectors, from IoT services and health care to e-commerce and logistics, the appeal of democratized, real-time insights is universal.

The Challenge of High Concurrency

While high concurrency is becoming increasingly necessary, it poses significant challenges. Keep in mind that it’s not just about managing large query volumes. High concurrency is a critical component for ensuring real-time, accurate data representation for your end users.

What Makes High Concurrency Difficult with User-Facing Analytics?

The dominant challenge of user-facing analytics stems from OLAP-style queries. While there might not be a vast number of these queries when compared to simpler point queries, their inherent complexity compensates for their lower frequency.

Each OLAP-style query often spans multiple tables, involves several aggregations and filters through millions, if not billions, of records. The combinatorial nature of such queries, combined with the need for real-time results, places a considerable strain on the CPU.

Therefore, addressing high concurrency in user-facing analytics isn’t just about scaling infrastructure to accommodate more queries; it’s about optimizing the system to handle the computational heft of OLAP-style queries efficiently.

Handling High Concurrency OLAP CPU Intensive Workloads

The current strategies employed to manage these challenges are multifaceted. Understand that no single approach can universally address all concurrency issues, and that you should always choose a strategy that suits your scenario the best. With that in mind, let’s examine the options and their respective pros and cons.

Precomputation: Preaggregation and Denormalization

One prevalent strategy is precomputation, which involves preaggregating and denormalizing data to speed up query processing.

Pros:

  • Anticipated query patterns: Precomputation is particularly beneficial when the query pattern is predictable. By understanding what kind of data will be frequently accessed, it’s possible to pre-process and store it in a manner that facilitates faster retrieval and analysis.

Cons:

  • Foreknowledge required: The efficacy of precomputation hinges on the ability to determine query patterns in advance. This necessitates continuous analysis and adjustments as data access patterns evolve.
  • Increased storage: Preaggregating and denormalizing data can lead to significantly increased storage requirements. While this ensures faster query execution, it might also mean that large portions of the pre-processed data are seldom used, leading to inefficiencies.

Query Result Caching

Query result caching is another technique to enhance query performance. By storing the (intermediate) results of frequently executed queries in a cache, subsequent requests for the same data can be swiftly fulfilled without the need to reprocess the entire query. Different from precomputation, this process is often automated.

Final Result Caching

Final result caching stores the final results of the executed queries on the disk to speed up subsequent identical query requests.

Pros:

  • Simple to implement: Implementing caching mechanisms can be seamlessly integrated into the application layer, providing developers with the flexibility to control cache behavior based on specific application needs.
  • Instant retrieval: When a user query matches a cached result (a cache hit), computation is entirely bypassed, resulting in almost-instant result retrieval.
  • Prevents redundant requests: Final result caching is especially valuable in scenarios where users might repetitively request the same data, like refreshing a dashboard. By serving cached results, the system conserves computational resources.

Cons:

  • Limited applicability: Final result caching is extremely sensitive to change. Even minor alterations in a query or a small change in the underlying data can result in a cache miss, necessitating a fresh computation. This makes caching less effective for dynamic datasets or applications with highly individualized user queries.

Intermediate Result Caching

Instead of solely focusing on the end result, this mechanism caches intermediate computations — like results from post-local aggregations — typically in memory. Even if the queries are not identical or the scanned data changes, part of the cached intermediate results can still be harnessed, partially bypassing the need for re-computation.

Pros:

  • Useful for user-facing analytics: In user-facing analytics, queries are generated by a BI tool or front-end application. By following some templates, these queries typically share a similar structure, which is very suitable for intermediate result caching.

Cons:

  • Not a panacea: It’s not a silver bullet. There will always be workloads such as large data transformation jobs or ad hoc queries that don’t benefit from this strategy, thereby requiring a combination of different approaches for optimization.

Moving Forward with User-Facing Analytics

Navigating OLAP high concurrency with user-facing analytics is like piecing together a complex puzzle where each piece represents a different layer of the solution. There’s no one-size-fits-all remedy; the dynamic nature of data interactions and user demands ensures that each scenario may warrant a unique approach or combination thereof. It’s essential to dig deep into your specific scenario, understand its nuances and consider multiple options. By combining various strategies tailored to your needs, you can craft an optimal solution that effectively manages concurrency while delivering a seamless user experience.

CelerData helps enterprises accelerate business growth with a unified analytics platform that delivers 3X the performance of any other solution on the market while reducing operating costs by up to 80%. Powered by StarRocks, CelerData is used worldwide by leading brands including Airbnb and Lenovo.
Learn More
The latest from CelerData
TRENDING STORIES
Sida Shen is product marketing manager at CelerData. An engineer with backgrounds in building machine learning and big data infrastructures, he oversees the company’s market research and works closely with engineers and developers across the analytics industry to tackle challenges...
Read more from Sida Shen
CelerData sponsored this post.
SHARE THIS STORY
TRENDING STORIES
TNS owner Insight Partners is an investor in: Pragma.
SHARE THIS STORY
TRENDING STORIES
TNS DAILY NEWSLETTER Receive a free roundup of the most recent TNS articles in your inbox each day.
The New Stack does not sell your information or share it with unaffiliated third parties. By continuing, you agree to our Terms of Use and Privacy Policy.