saturn icon indicating copy to clipboard operation
saturn copied to clipboard

Performance issues

Open erikh opened this issue 2 years ago • 3 comments

Gonna keep a running tally of perf issues to resolve. Most of this revolves around google calendar:

  • [ ] tokio/thread/sit function is very expensive; maybe some use of channels would help here.
  • [ ] use the refresh token properly, right now every invocation refreshes the token
  • [ ] in sui, we really don't need to update with google calendar on every action. just a periodic refresh would work, but because it's interlocked with the draw loop we don't get that functionality.
  • [ ] look for more opportunities to leverage references in heavy iterations of local state
  • [ ] use rustix for flock instead of libc

erikh avatar Sep 30 '23 21:09 erikh

The latest version of gcal has a debug mode which helped me isolate that we make a ton of http calls when resolving recurring tasks.

Just making notes here, I know some of the issues in my head, but it helps to have a reminder for some of them.

erikh avatar Oct 02 '23 14:10 erikh

I am also seeing i/o errors in the 0.4.x series chatting with gcal which causes sui to spin out of control.

erikh avatar Oct 02 '23 14:10 erikh

I've been looking into this and one of the things I threw in there out of desperation was a call to the fetch API during a record conversion routine, which is likely causing a N*N query (yes, really) and more or less bombing google calendar with requests. I've dumped some of this which gives me educated insight. I'm just not sure what the right solution is, and I've been preoccupied with other more pressing matters, so I'm writing this down so I don't forget.

erikh avatar Oct 09 '23 21:10 erikh