models

package
v1.59.0 Latest Latest
Warning

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

Go to latest
Published: Dec 29, 2022 License: Apache-2.0 Imports: 0 Imported by: 9 modules, 8 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type AzAndNetConfig

type AzAndNetConfig struct {

	/* 可用区,可选目的端实例的主节点可用区、或目的端实例的从节点可用区,空表示使用目的端实例的主节点可用区 (Optional) */
	AzId *string `json:"azId"`

	/* vpc ID,必须与目的端实例所在vpc保持一致,否则网络不通,空表示使用目的端实例vpc (Optional) */
	VpcId *string `json:"vpcId"`

	/* subnet ID,可以与目的端实例所在子网保持一致,如果该子网IP不足可选其他相通的子网,空表示使用目的端实例子网 (Optional) */
	SubnetId *string `json:"subnetId"`
}

type Buckets

type Buckets struct {

	/* 槽范围起始 (Optional) */
	From int `json:"from"`

	/* 槽范围终止 (Optional) */
	To int `json:"to"`
}

type Instance

type Instance struct {

	/* 迁移任务ID (Optional) */
	InstanceId string `json:"instanceId"`

	/* 迁移任务名 (Optional) */
	MigrationName string `json:"migrationName"`

	/* 迁移状态(creating:创建中,validated:验证通过,invalid:验证失败,starting:启动中,waitMigrate:待迁移,migrating:迁移中,migrated:迁移成功,createFailed:创建失败,startFailed:启动失败,migrateFailed:迁移失败,error:异常错误,deleting:删除中,migrateTimeout:迁移超时) (Optional) */
	MigrationStatus string `json:"migrationStatus"`

	/* 迁移代理域名 (Optional) */
	ProxyDomain string `json:"proxyDomain"`

	/* 迁移代理连接密码 (Optional) */
	ProxyPassword string `json:"proxyPassword"`

	/* 当前迁移步骤 (Optional) */
	CurrentStep string `json:"currentStep"`

	/* 当前迁移步骤状态(init:初始化,running:运行中,success:成功,fail:失败) (Optional) */
	CurrentStepStatus string `json:"currentStepStatus"`

	/* 迁移失败原因 (Optional) */
	FailedReason string `json:"failedReason"`

	/* 源端redis实例配置信息 (Optional) */
	Source RedisConfig `json:"source"`

	/* 目的端redis实例配置信息 (Optional) */
	Target RedisConfig `json:"target"`

	/* 地域 (Optional) */
	Region string `json:"region"`

	/* 创建时间(ISO 8601标准的UTC时间,格式为:YYYY-MM-DDTHH:mm:ssZ) (Optional) */
	CreatedTime string `json:"createdTime"`
}

type JimdbNode

type JimdbNode struct {

	/* 节点ip (Optional) */
	Ip string `json:"ip"`

	/* 节点端口 (Optional) */
	Port int `json:"port"`

	/* 节点的角色,m是主节点,s开头的是从节点 (Optional) */
	CopyId string `json:"copyId"`

	/* 从节点列表 (Optional) */
	Slaves []JimdbNode `json:"slaves"`
}

type ListItem

type ListItem struct {

	/* 迁移任务ID (Optional) */
	InstanceId string `json:"instanceId"`

	/* 迁移名称 (Optional) */
	MigrationName string `json:"migrationName"`

	/* 迁移状态(creating:创建中,validated:验证通过,invalid:验证失败,starting:启动中,waitMigrate:待迁移,migrating:迁移中,migrated:迁移成功,createFailed:创建失败,startFailed:启动失败,migrateFailed:迁移失败,error:异常错误,deleting:删除中,migrateTimeout:迁移超时) (Optional) */
	MigrationStatus string `json:"migrationStatus"`

	/* 当前迁移步骤:
	- clientFlowInSource:初始化状态,client流量位于源端;
	- migrateAndCheck:迁移数据并且校验,client流量仍位于源端;
	- clientFlowInProxy:client的流量位于迁移代理上;
	- clientFlowRedirect:迁移代理切换client的流量;
	- clientFlowInTarget:client流量切换到目的端;
	- migrateFinish:迁移完成状态;
	 (Optional) */
	CurrentStep string `json:"currentStep"`

	/* 当前迁移步骤状态,init初始化,running运行中,success成功,fail失败 (Optional) */
	CurrentStepStatus string `json:"currentStepStatus"`

	/* 失败原因 (Optional) */
	FailedReason string `json:"failedReason"`

	/* 创建时间(ISO 8601标准的UTC时间,格式为:YYYY-MM-DDTHH:mm:ssZ) (Optional) */
	CreatedTime string `json:"createdTime"`
}

type MigrateConfig

type MigrateConfig struct {

	/* 迁移任务名 (Optional) */
	Name *string `json:"name"`

	/* 源端类型,可选:jimdb表示jimdb;jcloud表示京东云redis;native_standalone表示原生redis standalone;native_cluster表示原生redis cluster  */
	SrcType string `json:"srcType"`

	/* 源端统一访问地址,jimdb形如jim://234234234423/3423;京东云redis、原生redis形如host:port,port默认为6379  */
	SrcUrl string `json:"srcUrl"`

	/* 源端版本,可选:2.8、3.0、3.2、4.0、5.0、6.0、6.2,目前只支持2.8、3.0、4.0 (Optional) */
	SrcVersion *string `json:"srcVersion"`

	/* 源端拓扑,原生cluster必须输入,其他类型不需要 (Optional) */
	SrcTopo []Topo `json:"srcTopo"`

	/* 源端连接密码  */
	SrcPwd string `json:"srcPwd"`

	/* 目的端类型,暂不支持jimdb,可选:jcloud,native_standalone  */
	TgtType string `json:"tgtType"`

	/* 目的端统一访问地址,形如host:port,port默认为6379  */
	TgtUrl string `json:"tgtUrl"`

	/* 目的端连接密码  */
	TgtPwd string `json:"tgtPwd"`

	/* 过期时间(单位分钟),可选,0表示默认值 (Optional) */
	ExExpTimeInMin *int `json:"exExpTimeInMin"`

	/* 代理个数,可选,默认的1分片为2个,n分片为n个 (Optional) */
	ProxyNum *int `json:"proxyNum"`
}

type MigrateProgress

type MigrateProgress struct {

	/* 源端key数量,即key总数量 (Optional) */
	SourceKeysCount int64 `json:"sourceKeysCount"`

	/* 目的端key数量,即已迁移的key数量 (Optional) */
	TargetKeysCount int64 `json:"targetKeysCount"`

	/* 迁移key数量百分比 (Optional) */
	Percent float32 `json:"percent"`

	/* 数据校验状态(CheckPhaseInit:初始化,CheckPhaseRunning:检验中,CheckPhaseFinished:验证完成) (Optional) */
	CheckPhase string `json:"checkPhase"`

	/* 迁移启动时间(ISO 8601标准的UTC时间,格式为:YYYY-MM-DDTHH:mm:ssZ) (Optional) */
	StartTime string `json:"startTime"`
}

type Monitor

type Monitor struct {

	/* 每秒请求个数 (Optional) */
	Ops int `json:"ops"`

	/* 输入流量,单位KBps (Optional) */
	InputKBps int `json:"inputKBps"`

	/* 源端内存规格(jimdb没有),单位Byte (Optional) */
	MaxMemory int64 `json:"maxMemory"`

	/* 源端已使用内存(jimdb没有),单位Byte (Optional) */
	UsedMemory int64 `json:"usedMemory"`
}

type Node

type Node struct {

	/* host,可以是ip或域名  */
	Host string `json:"host"`

	/* 端口  */
	Port int `json:"port"`

	/* 访问密码  */
	Password string `json:"password"`
}

type RedisConfig

type RedisConfig struct {

	/* redis实例类型 (Optional) */
	InstanceType string `json:"instanceType"`

	/* redis引擎版本 (Optional) */
	Version string `json:"version"`

	/* redis实例访问地址 (Optional) */
	Url string `json:"url"`

	/* redis实例ID,jimdb的instanceId为url (Optional) */
	InstanceId string `json:"instanceId"`
}

type Shards

type Shards struct {

	/* 分片ID (Optional) */
	ShardId int `json:"shardId"`

	/* 分片主节点信息 (Optional) */
	Master JimdbNode `json:"master"`

	/* 分片槽信息 (Optional) */
	Buckets Buckets `json:"buckets"`
}

type Topo

type Topo struct {

	/* master节点  */
	Master *Node `json:"master"`

	/* slave节点列表  */
	Slaves []Node `json:"slaves"`

	/* 槽范围起始 (Optional) */
	SlotsFrom *int `json:"slotsFrom"`

	/* 槽范围终止 (Optional) */
	SlotsTo *int `json:"slotsTo"`
}

type Topology

type Topology struct {

	/* 拓扑版本 (Optional) */
	Version string `json:"version"`

	/* 分片信息列表 (Optional) */
	Shards []Shards `json:"shards"`

	/* 拓扑创建时间 (Optional) */
	CreateTime string `json:"createTime"`
}

type TrafficMonitor

type TrafficMonitor struct {

	/* 源端流量监控 (Optional) */
	SourceCluster Monitor `json:"sourceCluster"`

	/* 迁移代理流量监控 (Optional) */
	RdtsProxy Monitor `json:"rdtsProxy"`

	/* 目的端流量监控 (Optional) */
	TargetProxy Monitor `json:"targetProxy"`

	/* 迁移代理ops与源端ops百分比 (Optional) */
	DiffPercent int `json:"diffPercent"`

	/* 当前时间(ISO 8601标准的UTC时间,格式为:YYYY-MM-DDTHH:mm:ssZ) (Optional) */
	CurrentTime string `json:"currentTime"`
}

type TrafficRedirect

type TrafficRedirect struct {

	/* 切流量开始时间(ISO 8601标准的UTC时间,格式为:YYYY-MM-DDTHH:mm:ssZ) (Optional) */
	StartTime string `json:"startTime"`

	/* 切流量结束时间(ISO 8601标准的UTC时间,格式为:YYYY-MM-DDTHH:mm:ssZ) (Optional) */
	EndTime string `json:"endTime"`

	/* 切流量实际耗时 (Optional) */
	Latency float32 `json:"latency"`

	/* 切流量策略 (Optional) */
	Strategy string `json:"strategy"`

	/* 切流量结果,OK表示切换成功 (Optional) */
	Result string `json:"result"`
}

Jump to

Keyboard shortcuts

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