How do I guarantee consistent endpoint performance with list filters?
My app's endpoint performance is great across the board when there is less traffic. "Endpoint A" will take less than 1 second to run consistently.
However, when traffic increases for a 6 hour period, "Endpoint A" begins to take 40+ seconds to run.
The 2 biggest culprits contain list filtering on a table Query.
Example:
Post's list of Tags — OVERLAPS — User's list of Tags
Both lists have a maximum of 10 Tags.
Indexes don't seem to be a problem and the GIN INDEX doesn't seem to work for my use case. Pagination is enabled. We don't want to cache responses.
Any ideas?
Typical performance:
Performance during increased traffic:
Answers
-
Hi,
is it normal that this endpoint is called so many times? In your screenshots I can see 7 times at 7:09am? If not then that would be my first thing to investigate and prevent since it affect your performance significantly.
-
Yes @Pawel Magdanski, that's as expected. I do have a change coming that will reduce the number of API requests across the board that I know will help. However, with more traffic expected over time, I would assume this problem to continue unless there I implement a long-term solution.
For context, certain optimizations (caching, recurring tasks, etc…) on other endpoints have kept performance up and usage down without a hiccup.
The list on list filtering specifically seems to be the issue here. Again, this isn't an issue during lower traffic. -
Update, this spike on this specific endpoint seemed to be isolated to a 3 minute period on October 10th. from 7:07 - 7:10.
Is it possible we hit max usage without the graph indicating it? -
Does anything specific happened in that time period?
Categories
- All Categories
- 53 ? Announcements
- 47 ? Releases
- 37 ? Welcome
- 983 ? Help! I'm a Noob
- 125 ? No-Code Front-Ends
- 633 ? Working with APIs
- 439 ? Transforming data
- 126 ? Connect Xano to ...
- 50 ?? Find an Expert
- 348 ❓Other questions
- 35 ? Security
- 22 ✂️ Snippets
- 19 ? Showcase
- 7 ?️ Xano Chatter
- 62 ? Video Tutorials
- 171 ? Request a feature
- 229 ? Report a Bug
- 19 ? Templates & Extensions
- 7 ? Feedback