-
Notifications
You must be signed in to change notification settings - Fork 29
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Performance issues with server-side tile composition #183
Comments
Here is the configuration we are using:
Based on my tests, it’s clear that
However, even with the same resources, I was unable to achieve comparable performance for server-side rendering as I did for client-side rendering. Probably I need to try with more resources? All tests were conducted on the same single tile. When I set |
From what I understand, titiler-pgstac uses mosaic_reader, so I attempted to rewrite the code from my initial message using it (
|
I have a hypothesis that might explain the observed behavior: In the first case, we use ThreadPoolExecutor solely for I/O-bound tasks (retrieving PNG tiles), whereas, in contrast, |
If there's anything I can do to help move this issue forward, please let me know. However, at this point, I'm leaning towards believing it's a design problem, and without refactoring of titiler-pgstac/rio-tiler, there may not be much we can do. |
I think most of the issue is that you're dealing with a large number of assets (75). As you mentioned, the way MosaicBackend/rio-tiler is designed is by using Threads to distribute the asset reading. As mentioned in https://cogeotiff.github.io/rio-tiler/mosaic/#smart-multi-threading we're trying to have a smart approach but sadly sometime we can't outsmart the task! if you're tile need to be composed of more than a couple assets, there is no magic! That's said I'm always interested to see if we can make rio-tiler/titiler better |
We’re trying to replace our current tile generation method (client-side composition using a
/cog
endpoint) with a server-side approach using the/searches
endpoint. However, this new method is up to five times slower in some tests. Is this because the same level of performance can’t be achieved withtitiler-pgstac
for server-side tile composition on the same resources?Here’s a snippet demonstrating the current approach. The issue is that it results in a high number of requests to the web server. We considered switching to
/searches
as a potential improvement, but so far, we haven’t achieved comparable performance.The text was updated successfully, but these errors were encountered: