Hi,
i created a small client wrapper with the following snippet for the fetching function:
go func() {
if err := imapClient.Fetch(seqSet, items, messages); err != nil {
log.Fatal(err)
}
}()
It works like a charm.
I added also a watchdog goroutine that collects sigint and sigterm event to manage a graceful shutdown feature.
When the shutdown goroutine call the logout function on the imapClient it hangs.
BTW the "imapClient" is a reference of the singleton IMAP client.
Any suggestion? I don't want closing the "messages" channel and manage the corresponding error, it's awful...
Hi, i created a small client wrapper with the following snippet for the fetching function:
It works like a charm. I added also a watchdog goroutine that collects sigint and sigterm event to manage a graceful shutdown feature. When the shutdown goroutine call the logout function on the imapClient it hangs. BTW the "imapClient" is a reference of the singleton IMAP client. Any suggestion? I don't want closing the "messages" channel and manage the corresponding error, it's awful...