ApplicationServiceWorkerState is a type that couples an application service, a lockable condition as well as some other state variables, allowing the roomserver to notify appservice workers when there are events ready to send externally to application services.
| 28 | // roomserver to notify appservice workers when there are events ready to send |
| 29 | // externally to application services. |
| 30 | type ApplicationServiceWorkerState struct { |
| 31 | AppService config.ApplicationService |
| 32 | Cond *sync.Cond |
| 33 | // Events ready to be sent |
| 34 | EventsReady bool |
| 35 | // Backoff exponent (2^x secs). Max 6, aka 64s. |
| 36 | Backoff int |
| 37 | } |
| 38 | |
| 39 | // NotifyNewEvents wakes up all waiting goroutines, notifying that events remain |
| 40 | // in the event queue for this application service worker. |
nothing calls this directly
no outgoing calls
no test coverage detected