Database read / write operations are very slow when running on cloud functions (appwrite cloud). Each operation takes 2-3 seconds and overall function execution takea around 3-6 seconds.
- Function execution
{"startTime":"Mon Dec 11 2023 18:45:30 GMT+0000 (Coordinated Universal Time)"}
[[1] get document by id] "1462.120"
[[4] create document in db] "2804.059"
function duration: 4854.733 ms
{"executionTime":4853,"endTime":"Mon Dec 11 2023 18:45:34 GMT+0000 (Coordinated Universal Time)"}
- Function execution
{"startTime":"Mon Dec 11 2023 18:51:11 GMT+0000 (Coordinated Universal Time)"}
[[2] third party API call] "148.158"
[[3] create document in db] "994.708"
[[4] create document in db] "2002.438"
function duration: 3776.766
{"executionTime":3776,"endTime":"Mon Dec 11 2023 18:51:15 GMT+0000 (Coordinated Universal Time)"}
3.Function execution
{"startTime":"Mon Dec 11 2023 18:53:26 GMT+0000 (Coordinated Universal Time)"}
[[2] third party API call] "121.156"
[[3] create document in db] "1284.590"
[[4] create document in db] "2619.728"
function duration: 4729.293
{"executionTime":4729,"endTime":"Mon Dec 11 2023 18:53:30 GMT+0000 (Coordinated Universal Time)"}
Do you use relationships?
Yes.
Below durations are for creating child documents [[3] create document in db] "994.708" [[3] create document in db] "1284.590"
Below duration are for creating parent document with child document reference (not nested syntax) [[4] create document in db] "2804.059" [[4] create document in db] "2002.438" [[4] create document in db] "2619.728"
Below duration is for getting the child document [[1] get document by id] "1462.120"
ya...relationships can slow things down a bit..
Creating a document without relationship takes 300~400 ms for each write operation. Is this consistent with the benchmarks or expectations you have observed?
[PostService::[0] create document in db with no relations] "384.234" [PostService::[5] create document in db with no relations] "306.835"
hmmmm possibly yes...
Is it possible that the upcoming Pro plan could reduce these operation times?
Recommended threads
- Backup policies think im on free tier
Cant create more than one policy as im told to ugprade, when clicking upgrade im taken to the upgrade page which confirms im already on pro
- Cant get rid of "get started"
Not that important, but annoying. No matter what I do I cant get the "Get started" to go away, ive added a bunch of web platforms and its just stuck.
- TEAM INVITE
There is a problem with the team invitation. When a user invites other users, that time, the newly created email address they don't get the invite link and old ...