Documentation ¶ Index ¶ Constants func PopRawEvent(ctx context.Context, redis *redis.Client, connCode string, ...) (string, error) func PushEvent(ctx context.Context, redis *redis.Client, connCode string, jobType EventType, ...) error type Event type EventType Constants ¶ View Source const EventTTLSeconds = 3600 Variables ¶ This section is empty. Functions ¶ func PopRawEvent ¶ func PopRawEvent(ctx context.Context, redis *redis.Client, connCode string, timeout time.Duration) (string, error) func PushEvent ¶ func PushEvent(ctx context.Context, redis *redis.Client, connCode string, jobType EventType, payload string) error Types ¶ type Event ¶ type Event struct { EventType EventType `json:"type"` Payload []byte `json:"payload"` } type EventType ¶ type EventType int const ( Connection EventType = iota Lobby State Player GameOver ) Source Files ¶ View all Source files event.go Click to show internal directories. Click to hide internal directories.