Documentation ¶
Overview ¶
Package channel captures IPC implementation.
package channel captures file IPC implementation.
package channel captures mango socket implementation.
Index ¶
Constants ¶
This section is empty.
Variables ¶
var ( ErrIPCChannelClosed = errors.New("channel is closed") ErrDialListenUnSuccessful = errors.New("IPC connection is not established") )
Functions ¶
func GetChannelCreator ¶
func GetChannelCreator(log log.T, appConfig appconfig.SsmagentConfig, identity identity.IAgentIdentity) (channelCreateFn func(log.T, identity.IAgentIdentity) IChannel)
GetChannelCreator returns function reference for channel creation based on whether named pipe be created or not
Types ¶
type IChannel ¶
type IChannel interface { Initialize(socketType utils.SocketType) error Send(message *message.Message) error Close() error Recv() ([]byte, error) SetOption(name string, value interface{}) error Listen(addr string) error Dial(addr string) error IsChannelInitialized() bool IsDialSuccessful() bool IsListenSuccessful() bool }
IChannel interface for implementing various channels
func NewFileChannel ¶
func NewFileChannel(log log.T, identity identity.IAgentIdentity) IChannel
NewFileChannel creates an new instance of FileChannel which internally uses file watcher based ipc channel This channel does not have multi-threading support. Currently, the invocations happen only in one go-routine
func NewNamedPipeChannel ¶
func NewNamedPipeChannel(log log.T, identity identity.IAgentIdentity) IChannel
NewNamedPipeChannel creates a new instance of named pipe channel This channel does not have multi-threading support. Currently, the invocations happen only in one go-routine
Directories ¶
Path | Synopsis |
---|---|
Package protocol implements some common communication protocols using file watcher.
|
Package protocol implements some common communication protocols using file watcher. |
Package utils implements some common functionalities for channel
|
Package utils implements some common functionalities for channel |