Hi, I'm trying to, figure out why fetching a large amount of documents is so long. I suspect a network bottleneck as using the CLI locally is way faster. Doing so I checked my Chrome dev tools and I can't find any Content-encoding: zip or so. So my question: is there any compression done in Appwrite http responses? If not, is there a way to enable it? Thx
we use brotli: 🧐
are you fetching in your app or Appwrite Console?
In my app which is a PWA, so Chrome involved in the process
Here's another test from my (react) web app:
Hmm, strange. My response contains no "Content-encoding"...
while others do present this "Content-encoding: br"
The requests missing this field are big queries with limit() and offset()
I reduced the limit() from 5000 down to 100 and I've the Content-encoding: br field. Any clue?
lol you shouldn't be fetching so many things at once 😜
Ah? This is bad news for my app...
why can't you paginate?
No, I need offline feature, this is a PWA and my users may be offline and still be able to use the app.
still....why can't you paginate?
Except the compression issue, all is performing well like this.
Paginate? The fetch of my 40K documents?
I'm currently fetching 100 at a time... so 400 requests. Takes way longer.
if you're using limit + offset, can you do them concurrently?
What's the time difference between 1 request of limit(5000) and 50 request of limit (100)? You might even be able to turn that for a better result
I found it. we won't compress if it's too big: https://github.com/utopia-php/framework/blob/702c945a2b83f9ecfe57a01d4eb02c779f26f99b/src/Response.php#L485-L489
because it's chunked instead...
OK, thanks for your answer. I see 2MB is the limit, so I gonna tweak my request settings to get them under the line. Thx.
Recommended threads
- Cannot use custom SMTP for messaging (SM...
Hey there! I'm on Appwrite Self-hosted 1.9.0. I've never used the messaging feature before, always sent emails through functions or a custom backend, but I'v...
- CORS errors in Obsidian custom plugin
Hi, anyone here familiar with obsidian community plugins? In short: it's a local first note app which supports writing your own add-ons / plugin But I keep get...
- > AppwriteException: The requested servi...
When trying to read or write from my database I get the following error: > AppwriteException: The requested service is disabled. You can enable the service from...