core

package
v0.0.0-...-3598874 Latest Latest
Warning

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

Go to latest
Published: Nov 8, 2024 License: MIT Imports: 8 Imported by: 0

Documentation

Index

Constants

View Source
const (
	LuaScript = `` /* 160-byte string literal not displayed */

	PkTaskOperator = "task_operator:"
	PkTaskQueue    = "task_queue"
	PkTaskResult   = "task_result:"
	PkTaskFinished = "task_finished:"
)

Variables

Functions

This section is empty.

Types

type App

type App struct {
	Env       string
	Host      string
	Threshold uint
}

type Chain

type Chain struct {
	Id           string `json:"id"`
	Rpc          string `json:"rpc"`
	BvsHash      string `json:"bvsHash"`
	BvsDirectory string `json:"bvsDirectory"`
}

type Config

type Config struct {
	App      App
	Database Database
	Chain    Chain
	Owner    Owner
}
var C Config

type Database

type Database struct {
	RedisHost     string `json:"redisHost"`
	RedisPassword string `json:"redisPassword"`
	RedisDb       int    `json:"redisDb"`
}

type Owner

type Owner struct {
	KeyDir         string `json:"keyDir"`
	KeyName        string `json:"keyName"`
	KeyringBackend string `json:"keyringBackend"`
	Bech32Prefix   string `json:"bech32Prefix"`
}

type Store

type Store struct {
	RedisConn *redis.Client
}
var S Store

type Task

type Task struct {
	TaskId     uint64     `json:"taskID"`
	TaskResult TaskResult `json:"taskResult"`
}

type TaskResult

type TaskResult struct {
	Operator string `json:"operator"`
	Result   int64  `json:"result"`
}

Jump to

Keyboard shortcuts

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