Documentation ¶
Index ¶
- func InitWsQueue(queue common.IQueue)
- func InsertOrder(order *models.Order) error
- func InsertTrade(trade *models.Trade) error
- func Run(ctx context.Context, startMetrics func())
- func UpdateOrder(order *models.Order) error
- func UpdateTrade(trade *models.Trade) error
- type DexEngine
- type MarketHandler
- type MatchResultWithOrders
- type RedisOrderBookActivitiesHandler
- type RedisOrderBookSnapshotHandler
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func InitWsQueue ¶
func InsertOrder ¶
func InsertTrade ¶
func UpdateOrder ¶
func UpdateTrade ¶
Types ¶
type DexEngine ¶
type DexEngine struct { // Wait for all queue handler exit gracefully Wg sync.WaitGroup HydroEngine *engine.Engine // contains filtered or unexported fields }
func NewDexEngine ¶
type MarketHandler ¶
type MarketHandler struct {
// contains filtered or unexported fields
}
func NewMarketHandler ¶
func (*MarketHandler) Run ¶
func (m *MarketHandler) Run()
Run is synchronous, it will be improved in the later releases.
func (*MarketHandler) Stop ¶
func (m *MarketHandler) Stop()
type MatchResultWithOrders ¶
type MatchResultWithOrders struct { Sequence uint64 *common.MatchResult // contains filtered or unexported fields }
func NewMatchResultWithOrders ¶
func NewMatchResultWithOrders(takerOrder *models.Order, result *common.MatchResult) *MatchResultWithOrders
type RedisOrderBookActivitiesHandler ¶
type RedisOrderBookActivitiesHandler struct { }
func (RedisOrderBookActivitiesHandler) Update ¶
func (handler RedisOrderBookActivitiesHandler) Update(webSocketMessages []common.WebSocketMessage) sync.WaitGroup
type RedisOrderBookSnapshotHandler ¶
type RedisOrderBookSnapshotHandler struct {
// contains filtered or unexported fields
}
func (RedisOrderBookSnapshotHandler) Update ¶
func (handler RedisOrderBookSnapshotHandler) Update(key string, bookSnapshot *common.SnapshotV2) sync.WaitGroup
Click to show internal directories.
Click to hide internal directories.