cic-custodial/internal/tasker/types.go
Mohammed Sohail 341a760f02
feat: (wip) add account activation and gas quota lock
* This is a crude lock that restricts each account to the set gas quota.
2023-03-08 06:49:09 +00:00

32 lines
734 B
Go

package tasker
import (
"encoding/json"
)
type (
QueueName string
TaskName string
)
type Task struct {
Id string `json:"id"`
Payload json.RawMessage `json:"payload"`
}
const (
AccountPrepareTask TaskName = "sys:prepare_account"
AccountRegisterTask TaskName = "sys:register_account"
AccountGiftGasTask TaskName = "sys:gift_gas"
AccountGiftVoucherTask TaskName = "sys:gift_token"
AccountRefillGasTask TaskName = "sys:refill_gas"
AccountActivateTask TaskName = "sys:quorum_check"
SignTransferTask TaskName = "usr:sign_transfer"
DispatchTxTask TaskName = "rpc:dispatch"
)
const (
HighPriority QueueName = "high_priority"
DefaultPriority QueueName = "default_priority"
)