Documentation ¶
Overview ¶
Package imap provides IMAP server of the Bridge.
Methods are called by the go-imap library in parallel. Additional parallelism is achieved while handling each IMAP request.
For example, ListMessages internally uses `fetchWorkers` workers to resolve each requested item. When IMAP clients request message literals (or parts thereof), we sometimes need to build RFC822 message literals. To do this, we pass build jobs to the message builder, which internally manages its own parallelism. Summary:
- each IMAP fetch request is handled in parallel,
- within each IMAP fetch request, individual items are handled by a pool of `fetchWorkers` workers,
- within each worker, build jobs are posted to the message builder,
- the message builder handles build jobs using its own, independent worker pool,
The builder will handle jobs in parallel up to its own internal limit. This prevents it from overwhelming API.
Index ¶
- Constants
- func NewIMAPBackend(panicHandler panicHandler, eventListener listener.Listener, ...) *imapBackend
- type Server
- func (s *Server) Address() string
- func (s *Server) Close()
- func (s *Server) DebugClient() bool
- func (s *Server) DebugServer() bool
- func (s *Server) DisconnectUser(address string)
- func (s *Server) HandlePanic()
- func (s *Server) ListenAndServe()
- func (Server) Protocol() serverutil.Protocol
- func (s *Server) Serve(listener net.Listener) error
- func (s *Server) SetLoggers(localDebug, remoteDebug io.Writer)
- func (s *Server) StopServe() error
- func (s *Server) TLSConfig() *tls.Config
- func (s *Server) UseSSL() bool
Constants ¶
const (
SubscriptionException = "subscription_exceptions"
)
Cache keys.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type Server ¶
type Server struct {
// contains filtered or unexported fields
}
Server takes care of IMAP listening serving. It implements serverutil.Server.
func NewIMAPServer ¶
func NewIMAPServer( panicHandler panicHandler, debugClient, debugServer bool, port int, tls *tls.Config, imapBackend backend.Backend, userAgent *useragent.UserAgent, eventListener listener.Listener, ) *Server
NewIMAPServer constructs a new IMAP server configured with the given options.
func (*Server) DebugClient ¶
func (*Server) DebugServer ¶
func (*Server) DisconnectUser ¶
func (*Server) HandlePanic ¶
func (s *Server) HandlePanic()
func (*Server) ListenAndServe ¶
func (s *Server) ListenAndServe()
ListenAndServe will run server and all monitors.
func (Server) Protocol ¶
func (Server) Protocol() serverutil.Protocol
func (*Server) SetLoggers ¶
Source Files ¶
Directories ¶
Path | Synopsis |
---|---|
Package uidplus DOES NOT implement full RFC4315! Excluded parts are: * Response `UIDNOTSTICKY`: All mailboxes of Bridge support stable UIDVALIDITY so it would never return this response Otherwise the standard RFC4315 is followed.
|
Package uidplus DOES NOT implement full RFC4315! Excluded parts are: * Response `UIDNOTSTICKY`: All mailboxes of Bridge support stable UIDVALIDITY so it would never return this response Otherwise the standard RFC4315 is followed. |