config

package
v0.1.4 Latest Latest
Warning

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

Go to latest
Published: Jan 9, 2024 License: Apache-2.0 Imports: 1 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Credentials

type Credentials struct {
	// 授权,相当于用户名
	Access string `json:"access" yaml:"access" xml:"access" toml:"access" validate:"required"`
	// 授权,相当于密码
	Secret string `json:"secret" yaml:"secret" xml:"secret" toml:"secret" validate:"required"`
}

type Queue

type Queue struct {
	// 名称
	Name string `json:"name" yaml:"name" xml:"name" toml:"name" validate:"required"`
	// 标签
	Label string `json:"label" yaml:"label" xml:"label" toml:"label" validate:"required"`
}

type Sqs

type Sqs struct {
	// 区域
	Region string `default:"ap-east-1" json:"region" yaml:"region" xml:"region" toml:"region" validate:"required"`
	// 授权
	Credentials Credentials `json:"credentials" yaml:"credentials" xml:"credentials" toml:"credentials" validate:"structonly"`
	// 队列
	Queue string `json:"queue" yaml:"queue" xml:"queue" toml:"queue" validate:"required_without=Queues"`
	// 队列列表
	Queues []Queue `json:"queues" yaml:"queues" xml:"queues" toml:"queues" validate:"required_without=Queue"`
	// 授权验证(策略)
	Session string `json:"session" yaml:"session" xml:"session" toml:"session" validate:"omitempty"`
	// 长轮询,减少费用
	Wait time.Duration `json:"wait" yaml:"wait" xml:"wait" toml:"wait" validate:"omitempty,max=20000"`
}

Jump to

Keyboard shortcuts

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