mbsd

package
v0.9.20 Latest Latest
Warning

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

Go to latest
Published: Feb 27, 2023 License: GPL-3.0 Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func CreateOperationLog

func CreateOperationLog(port int, timeoutSec int64, topic string, req *CreateOperationLogRequest) error

func Destroy

func Destroy()

func Init

func Init(psub, baseUrl string, timeoutSec time.Duration)

Types

type CreateOperationLogRequest

type CreateOperationLogRequest struct {
	Ip           string `json:"ip"`
	Method       string `json:"method"`
	Path         string `json:"path"`
	Agent        string `json:"agent"`
	ErrorMessage string `json:"errorMessage"`
	Body         string `json:"body"`
	Resp         string `json:"resp"`
	UserName     string `json:"userName"`
	CreateBy     string `json:"createBy"`
	Status       int    `json:"status"`
}

type GetOperationLogQuery

type GetOperationLogQuery struct {
	Path     string `form:"path"`
	CreateBy string `form:"createBy"`
	Start    string `form:"start"`
	End      string `form:"end"`
	PageNo   int    `form:"pageNo"`
	PageSize int    `form:"pageSize"`
}

type GetOperationLogResponse

type GetOperationLogResponse struct {
	Infos      []OperationLogInfo `json:"infos"`
	TotalCount int64              `json:"totalCount"`
	PageNo     int                `json:"pageNo"`
	// contains filtered or unexported fields
}

type OperationLogInfo

type OperationLogInfo struct {
	ID           string `json:"id"`
	Ip           string `json:"ip"`
	Method       string `json:"method"`
	Path         string `json:"path"`
	Status       int    `json:"status"`
	Agent        string `json:"agent"`
	ErrorMessage string `json:"errorMessage"`
	Body         string `json:"body"`
	Resp         string `json:"resp"`
	UserName     string `json:"userName"`
	CreatedAt    string `json:"createdAt"`
	CreateBy     string `json:"createBy"`
}

func GetOperationLog

func GetOperationLog(query *GetOperationLogQuery) ([]OperationLogInfo, int64, error)

Jump to

Keyboard shortcuts

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