services

package
v0.0.0-...-c72b0ab Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Oct 19, 2018 License: Apache-2.0 Imports: 20 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ConnectMixinBlaze

func ConnectMixinBlaze(clientId, sessionId, sessionKey string) (*websocket.Conn, error)

Types

type BlazeMessage

type BlazeMessage struct {
	Id     string                 `json:"id"`
	Action string                 `json:"action"`
	Params map[string]interface{} `json:"params,omitempty"`
	Data   interface{}            `json:"data,omitempty"`
	Error  *session.Error         `json:"error,omitempty"`
}

type Event

type Event struct {
	// contains filtered or unexported fields
}

func (Event) Finalize

func (event Event) Finalize(err error) error

type EventFactory

type EventFactory struct {
	// contains filtered or unexported fields
}

func NewEventFactory

func NewEventFactory(size int64) *EventFactory

func (*EventFactory) Get

func (factory *EventFactory) Get() Event

func (*EventFactory) Insight

func (factory *EventFactory) Insight() string

func (*EventFactory) InsightRoutine

func (factory *EventFactory) InsightRoutine(logger *durable.Logger, tag string)

type Hub

type Hub struct {
	// contains filtered or unexported fields
}

func NewHub

func NewHub(spanner *spanner.Client) *Hub

func (*Hub) StartService

func (hub *Hub) StartService(name string) error

type MessageContext

type MessageContext struct {
	Transactions *tmap
	ReadDone     chan bool
	WriteDone    chan bool
	ReadBuffer   chan MessageView
	WriteBuffer  chan []byte
}

type MessageService

type MessageService struct{}

func (*MessageService) Run

func (service *MessageService) Run(ctx context.Context) error

type MessageView

type MessageView struct {
	ConversationId string    `json:"conversation_id"`
	UserId         string    `json:"user_id"`
	MessageId      string    `json:"message_id"`
	Category       string    `json:"category"`
	Data           string    `json:"data"`
	Status         string    `json:"status"`
	Source         string    `json:"source"`
	CreatedAt      time.Time `json:"created_at"`
	UpdatedAt      time.Time `json:"updated_at"`
}

type Service

type Service interface {
	Run(context.Context) error
}

type TransferView

type TransferView struct {
	Type          string    `json:"type"`
	SnapshotId    string    `json:"snapshot_id"`
	CounterUserId string    `json:"counter_user_id"`
	AssetId       string    `json:"asset_id"`
	Amount        string    `json:"amount"`
	TraceId       string    `json:"trace_id"`
	Memo          string    `json:"memo"`
	CreatedAt     time.Time `json:"created_at"`
}

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL