feat(GODT-2803): Gluon IMAP State access

Update to latest Gluon to allow access to the database for bridge. The
cache is placed in a `SharedCache` type to ensure that we respect calls
to `Connector.Close`.

In theory, this should never trigger an error, but this way we can catch
it if it happens.

https://github.com/ProtonMail/gluon/pull/391
This commit is contained in:
Leander Beernaert
2023-08-11 09:37:56 +02:00
parent 24331f9715
commit 41c125f65e
8 changed files with 197 additions and 12 deletions

View File

@ -675,3 +675,15 @@ func (user *User) GetSMTPService() *smtp.Service {
func (user *User) PublishEvent(_ context.Context, event events.Event) {
user.eventCh.Enqueue(event)
}
func (user *User) PauseEventLoop() {
user.eventService.Pause()
}
func (user *User) PauseEventLoopWithWaiter() *userevents.EventPollWaiter {
return user.eventService.PauseWithWaiter()
}
func (user *User) ResumeEventLoop() {
user.eventService.Resume()
}