Documentation ¶
Index ¶
- func StringIncludes(check string, shouldInclude []string) bool
- func StructToMap(obj interface{}) (map[string]interface{}, error)
- func WriteSSHEvents(sshMonitor *SSHMonitor, analytics Analytics, userID string, ...) error
- type Analytics
- type EventName
- type Properties
- type SSData
- type SSHAnalyticsStore
- type SSHAnalyticsTask
- type SSHMonitor
- type SegmentClient
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func StringIncludes ¶
returns true if empty list provided
func StructToMap ¶
func WriteSSHEvents ¶
Types ¶
type Analytics ¶
type Analytics interface { TrackUserEvent(eventName EventName, userID string, properties Properties) error TrackUserWorkspaceEvent(eventName EventName, userID string, workspace *entity.Workspace, extraProps Properties) error }
type Properties ¶
type Properties map[string]interface{}
type SSData ¶
type SSData struct { NetID string `json:"netId"` State string `json:"state"` RecvQ string `json:"recvQ"` SendQ string `json:"sendvQ"` LocalAddressPort string `json:"localAddressPort"` PeerAddressPort string `json:"peerAddressPort"` }
func RowStrToSSRow ¶
type SSHAnalyticsStore ¶
type SSHAnalyticsTask ¶
type SSHAnalyticsTask struct { SSHMonitor *SSHMonitor Analytics Analytics Store SSHAnalyticsStore // contains filtered or unexported fields }
func (SSHAnalyticsTask) Configure ¶
func (s SSHAnalyticsTask) Configure() error
func (SSHAnalyticsTask) GetTaskSpec ¶
func (s SSHAnalyticsTask) GetTaskSpec() tasks.TaskSpec
func (*SSHAnalyticsTask) Run ¶
func (s *SSHAnalyticsTask) Run() error
type SSHMonitor ¶
type SSHMonitor struct {
// contains filtered or unexported fields
}
func NewSSHMonitor ¶
func NewSSHMonitor() *SSHMonitor
func (SSHMonitor) GetAllConnections ¶
func (c SSHMonitor) GetAllConnections(include ...string) ([]string, error)
func (SSHMonitor) GetSSHConnections ¶
func (c SSHMonitor) GetSSHConnections() ([]SSData, error)
func (*SSHMonitor) GetSSHSessionEvents ¶
func (c *SSHMonitor) GetSSHSessionEvents() (EventName, error)
type SegmentClient ¶
type SegmentClient struct {
Client analytics.Client
}
func NewSegmentClient ¶
func NewSegmentClient(writeAPIKey string) SegmentClient
func (SegmentClient) TrackUserEvent ¶
func (s SegmentClient) TrackUserEvent(eventName EventName, userID string, properties Properties) error
func (SegmentClient) TrackUserWorkspaceEvent ¶ added in v0.6.39
func (s SegmentClient) TrackUserWorkspaceEvent(eventName EventName, userID string, workspace *entity.Workspace, extraProps Properties) error
Click to show internal directories.
Click to hide internal directories.