Documentation
¶
Index ¶
- type AdminInfoOutput
- type AdminLoginInput
- type AdminLoginOutput
- type AppAddInput
- type AppDeleteInput
- type AppDetailInput
- type AppDetailOutput
- type AppListInput
- type AppListItemOutput
- type AppListOutput
- type AppStatInput
- type AppStatOutput
- type AppUpdateInput
- type ChangePwdInput
- type DashboardServiceStatItemOutput
- type DashboardServiceStatOutput
- type FlowStatOutput
- type PanelGroupDataOutput
- type ServiceAddGrpcInput
- type ServiceAddHTTPInput
- type ServiceAddTcpInput
- type ServiceDeleteInput
- type ServiceDetailInput
- type ServiceListInput
- type ServiceListItemOutput
- type ServiceListOutput
- type ServiceStatInput
- type ServiceStatOutput
- type ServiceUpdateGrpcInput
- type ServiceUpdateHTTPInput
- type ServiceUpdateTcpInput
- type TokensInput
- type TokensOutput
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type AdminInfoOutput ¶
type AdminLoginInput ¶
type AdminLoginInput struct { Username string `json:"username" form:"username" comment:"用户名" example:"admin" validate:"required,valid_username"` // 管理员账户 Password string `json:"password" form:"password" comment:"密码" example:"123456" validate:"required,valid_password"` // 密码 }
AdminLoginInput 登录接口输入参数
func (*AdminLoginInput) BindingValidParams ¶
func (params *AdminLoginInput) BindingValidParams(c *gin.Context) error
type AdminLoginOutput ¶
type AdminLoginOutput struct {
Token string `json:"token" from:"token" comment:"token" example:"" validate:""` // 用户 token
}
AdminLoginOutput 登录接口输出参数
type AppAddInput ¶
type AppAddInput struct { AppID string `json:"app_id" form:"app_id" comment:"租户ID" example:"" validate:"required"` // 租户ID Name string `json:"name" form:"name" comment:"租户名称" example:"" validate:"required"` // 租户名称 Secret string `json:"secret" form:"secret" comment:"秘钥" example:"" validate:""` // 秘钥 WhiteIPs string `json:"white_ips" form:"white_ips" comment:"IP白名单,支持前缀匹配" example:"" validate:""` // IP白名单,支持前缀匹配 Qps int64 `json:"qps" form:"qps" comment:"每秒请求量限制" example:"" validate:""` // 每秒请求量限制 Qpd int64 `json:"qpd" form:"qpd" comment:"日请求量限制" example:"" validate:""` // 日请求量限制 }
func (*AppAddInput) BindingValidParams ¶
func (params *AppAddInput) BindingValidParams(c *gin.Context) error
type AppDeleteInput ¶
type AppDeleteInput struct {
ID int64 `json:"id" form:"id" comment:"租户ID" example:"" validate:"required"` // 租户 ID
}
func (*AppDeleteInput) BindingValidParams ¶
func (params *AppDeleteInput) BindingValidParams(c *gin.Context) error
type AppDetailInput ¶
type AppDetailInput struct {
ID int64 `json:"id" form:"id" comment:"租户ID" example:"" validate:"required"` // 租户 ID
}
func (*AppDetailInput) BindingValidParams ¶
func (params *AppDetailInput) BindingValidParams(c *gin.Context) error
type AppDetailOutput ¶
type AppDetailOutput struct { ID int64 `json:"id" form:"" comment:"" example:"" validate:""` // Qps int64 `json:"qps" form:"qps" comment:"每秒请求量限制" example:"" validate:""` // 每秒请求量限制 Qpd int64 `json:"qpd" form:"qpd" comment:"日请求量限制" example:"" validate:""` // 日请求量限制 RealQps int64 `json:"real_qps" form:"real_qps" comment:"当前实际 QPS" example:"" validate:""` // 当前实际 QPS RealQpd int64 `json:"real_qpd" form:"real_qpd" comment:"当前实际 QPD" example:"" validate:""` // 当前实际 QPD AppID string `json:"app_id" form:"app_id" comment:"租户ID" example:"" validate:""` // 租户ID Name string `json:"name" form:"name" comment:"租户名称" example:"" validate:""` // 租户名称 Secret string `json:"secret" form:"secret" comment:"秘钥" example:"" validate:""` // 秘钥 WhiteIPs string `json:"white_ips" form:"white_ips" comment:"IP白名单,支持前缀匹配" example:"" validate:""` // IP白名单,支持前缀匹配 }
type AppListInput ¶
type AppListInput struct { Info string `json:"info" form:"info" comment:"关键词" example:"" validate:""` // 关键词 PageSize int `json:"page_size" form:"page_size" comment:"每页大小" example:"10" validate:"required,min=1,max=999"` // 每页个数 PageNo int `json:"page_no" form:"page_no" comment:"页码" example:"1" validate:"required,min=1,max=999"` // 页码 }
func (*AppListInput) BindingValidParams ¶
func (params *AppListInput) BindingValidParams(c *gin.Context) error
type AppListItemOutput ¶
type AppListItemOutput struct { ID int64 `json:"id" form:"" comment:"" example:"" validate:""` // Qps int64 `json:"qps" form:"qps" comment:"每秒请求量限制" example:"" validate:""` // 每秒请求量限制 Qpd int64 `json:"qpd" form:"qpd" comment:"日请求量限制" example:"" validate:""` // 日请求量限制 RealQps int64 `json:"real_qps" form:"real_qps" comment:"当前实际 QPS" example:"" validate:""` // 当前实际 QPS RealQpd int64 `json:"real_qpd" form:"real_qpd" comment:"当前实际 QPD" example:"" validate:""` // 当前实际 QPD AppID string `json:"app_id" form:"app_id" comment:"租户ID" example:"" validate:""` // 租户ID Name string `json:"name" form:"name" comment:"租户名称" example:"" validate:""` // 租户名称 Secret string `json:"secret" form:"secret" comment:"秘钥" example:"" validate:""` // 秘钥 WhiteIPs string `json:"white_ips" form:"white_ips" comment:"IP白名单,支持前缀匹配" example:"" validate:""` // IP白名单,支持前缀匹配 }
AppListItemOutput .
type AppListOutput ¶
type AppListOutput struct { List []AppListItemOutput `json:"list" form:"list" comment:"租户列表"` // 租户列表 Total int64 `json:"total" form:"total" comment:"租户总数"` // 租户总数 }
AppListOutput AppList 输出结构体
type AppStatInput ¶
type AppStatInput struct {
ID int64 `json:"id" form:"id" comment:"租户ID" example:"" validate:"required"` // 租户 ID
}
func (*AppStatInput) BindingValidParams ¶
func (params *AppStatInput) BindingValidParams(c *gin.Context) error
type AppStatOutput ¶
type AppUpdateInput ¶
type AppUpdateInput struct { ID int64 `json:"id" form:"id" comment:"租户ID" example:"" validate:"required"` // 主键ID AppID string `json:"app_id" form:"app_id" comment:"租户ID" example:"" validate:""` // 租户ID Name string `json:"name" form:"name" comment:"租户名称" example:"" validate:"required"` // 租户名称 Secret string `json:"secret" form:"secret" comment:"秘钥" example:"" validate:"required"` // 秘钥 WhiteIPs string `json:"white_ips" form:"white_ips" comment:"IP白名单,支持前缀匹配" example:"" validate:""` // IP白名单,支持前缀匹配 Qps int64 `json:"qps" form:"qps" comment:"每秒请求量限制" example:"" validate:""` // 每秒请求量限制 Qpd int64 `json:"qpd" form:"qpd" comment:"日请求量限制" example:"" validate:""` // 日请求量限制 }
func (*AppUpdateInput) BindingValidParams ¶
func (params *AppUpdateInput) BindingValidParams(c *gin.Context) error
type ChangePwdInput ¶
type ChangePwdInput struct {
Password string `json:"password" from:"password" comment:"新密码" example:"123456" validate:"required,valid_password"` // 新密码
}
func (*ChangePwdInput) BindingValidParams ¶
func (params *ChangePwdInput) BindingValidParams(c *gin.Context) error
type DashboardServiceStatOutput ¶
type DashboardServiceStatOutput struct { Legend []string `json:"legend"` // 服务类型列表 Data []DashboardServiceStatItemOutput `json:"data"` // 各服务类型数据列表 }
type FlowStatOutput ¶
type PanelGroupDataOutput ¶
type ServiceAddGrpcInput ¶
type ServiceAddGrpcInput struct { ServiceName string `json:"service_name" form:"service_name" comment:"服务名称" validate:"required,valid_service_name"` // 服务名称 ServiceDesc string `json:"service_desc" form:"service_desc" comment:"服务描述" validate:"required"` // 服务描述 Port int `json:"port" form:"port" comment:"端口,需要设置8001-8999范围内" validate:"required,min=8001,max=8999"` // 端口,需要设置8001-8999范围内 HeaderTransfor string `json:"header_transfor" form:"header_transfor" comment:"metadata转换" validate:"valid_header_transfor"` // metadata转换 OpenAuth int `json:"open_auth" form:"open_auth" comment:"是否开启权限验证" validate:""` // 是否开启权限验证 BlackList string `` // 黑名单IP,以逗号间隔,白名单优先级高于黑名单 /* 135-byte string literal not displayed */ WhiteList string `` // 白名单IP,以逗号间隔,白名单优先级高于黑名单 /* 135-byte string literal not displayed */ WhiteHostName string `json:"white_host_name" form:"white_host_name" comment:"白名单主机,以逗号间隔" validate:"valid_iplist"` // 白名单主机,以逗号间隔 ClientIPFlowLimit int `json:"clientip_flow_limit" form:"clientip_flow_limit" comment:"客户端IP限流" validate:""` // 客户端IP限流 ServiceFlowLimit int `json:"service_flow_limit" form:"service_flow_limit" comment:"服务端限流" validate:""` // 服务端限流 RoundType int `json:"round_type" form:"round_type" comment:"轮询策略" validate:""` // 轮询策略 IpList string `json:"ip_list" form:"ip_list" comment:"IP列表" validate:"required,valid_ipportlist"` // IP列表 WeightList string `json:"weight_list" form:"weight_list" comment:"权重列表" validate:"required,valid_weightlist"` // 权重列表 ForbidList string `json:"forbid_list" form:"forbid_list" comment:"禁用IP列表" validate:"valid_iplist"` // 禁用IP列表 }
func (*ServiceAddGrpcInput) BindingValidParams ¶
func (params *ServiceAddGrpcInput) BindingValidParams(c *gin.Context) error
type ServiceAddHTTPInput ¶
type ServiceAddHTTPInput struct { ServiceName string `json:"service_name" form:"service_name" comment:"服务名称" example:"" validate:"required,valid_service_name"` // 服务名称 ServiceDesc string `json:"service_desc" form:"service_desc" comment:"服务描述" example:"" validate:"required,max=255,min=1"` // 服务描述 RuleType int `json:"rule_type" form:"rule_type" comment:"接入类型" example:"" validate:"max=1,min=0"` // 接入类型 Rule string `json:"rule" form:"rule" comment:"接入路径:域名或前缀" example:"" validate:"required,valid_rule"` // 接入路径:域名或前缀 NeedHTTPs int `json:"need_https" form:"need_https" comment:"支持https" example:"" validate:"max=1,min=0"` // 支持https NeedStripURI int `json:"need_strip_uri" form:"need_strip_uri" comment:"启用strip_uri" example:"" validate:"max=1,min=0"` // 启用strip_uri NeedWebsocket int `json:"need_websocket" form:"need_websocket" comment:"是否支持websocket" example:"" validate:"max=1,min=0"` // 是否支持websocket UrlRewrite string `json:"url_rewrite" form:"url_rewrite" comment:"RUL重写功能" example:"" validate:"valid_url_rewrite"` // RUL重写功能 HeaderTransfor string `json:"header_transfor" form:"header_transfor" comment:"Header转换" example:"" validate:"valid_header_transfor"` // Header转换 OpenAuth int `json:"open_auth" form:"open_auth" comment:"是否开启权限" example:"" validate:"max=1,min=0"` // 是否开启权限 BlackList string `json:"black_list" form:"black_list" comment:"黑名单IP" example:"" validate:""` // 黑名单IP WhiteList string `json:"white_list" form:"white_list" comment:"白名单IP" example:"" validate:""` // 白名单IP ClientFlowLimit int `json:"client_flow_limit" form:"client_flow_limit" comment:"客户端IP限流" example:"" validate:"min=0"` // 客户端IP限流 ServiceFlowLimit int `json:"service_flow_limit" form:"service_flow_limit" comment:"服务端限流" example:"" validate:"min=0"` // 服务端限流 RoundType int `json:"round_type" form:"round_type" comment:"轮询方式" example:"" validate:"max=3,min=0"` // 轮询方式 IpList string `json:"ip_list" form:"ip_list" comment:"IP列表" example:"" validate:"required,valid_ipportlist"` // IP列表 WeightList string `json:"weight_list" form:"weight_list" comment:"IP权重" example:"" validate:"required,valid_weightlist"` // IP权重 UpstreamConnectTimeout int `json:"upstream_connect_timeout" form:"upstream_connect_timeout" comment:"建立连接超时" example:"" validate:"min=0"` // 建立连接超时 UpstreamHeaderTimeout int `json:"upstream_header_timeout" form:"upstream_header_timeout" comment:"获取header超时" example:"" validate:"min=0"` // 获取header超时 UpstreamIdleTimeout int `` // 链接最大空闲连接时间 /* 126-byte string literal not displayed */ UpstreamMaxIdle int `json:"upstream_max_idle" form:"upstream_max_idle" comment:"最大空闲连接数" example:"" validate:"min=0"` // 最大空闲连接数 }
func (*ServiceAddHTTPInput) BindingValidParams ¶
func (params *ServiceAddHTTPInput) BindingValidParams(c *gin.Context) error
type ServiceAddTcpInput ¶
type ServiceAddTcpInput struct { ServiceName string `json:"service_name" form:"service_name" comment:"服务名称" validate:"required,valid_service_name"` // 服务名称 ServiceDesc string `json:"service_desc" form:"service_desc" comment:"服务描述" validate:"required"` // 服务描述 Port int `json:"port" form:"port" comment:"端口,需要设置8001-8999范围内" validate:"required,min=8001,max=8999"` // 端口,需要设置8001-8999范围内 OpenAuth int `json:"open_auth" form:"open_auth" comment:"是否开启权限验证" validate:""` // 是否开启权限验证 BlackList string `` // 黑名单IP,以逗号间隔,白名单优先级高于黑名单 /* 135-byte string literal not displayed */ WhiteList string `` // 白名单IP,以逗号间隔,白名单优先级高于黑名单 /* 135-byte string literal not displayed */ WhiteHostName string `json:"white_host_name" form:"white_host_name" comment:"白名单主机,以逗号间隔" validate:"valid_iplist"` // 白名单主机,以逗号间隔 ClientIPFlowLimit int `json:"clientip_flow_limit" form:"clientip_flow_limit" comment:"客户端IP限流" validate:""` // 客户端IP限流 ServiceFlowLimit int `json:"service_flow_limit" form:"service_flow_limit" comment:"服务端限流" validate:""` // 服务端限流 RoundType int `json:"round_type" form:"round_type" comment:"轮询策略" validate:""` // 轮询策略 IpList string `json:"ip_list" form:"ip_list" comment:"IP列表" validate:"required,valid_ipportlist"` // IP列表 WeightList string `json:"weight_list" form:"weight_list" comment:"权重列表" validate:"required,valid_weightlist"` // 权重列表 ForbidList string `json:"forbid_list" form:"forbid_list" comment:"禁用IP列表" validate:"valid_iplist"` // 禁用IP列表 }
func (*ServiceAddTcpInput) BindingValidParams ¶
func (params *ServiceAddTcpInput) BindingValidParams(c *gin.Context) error
type ServiceDeleteInput ¶
type ServiceDeleteInput struct {
ID int64 `json:"id" form:"id" comment:"服务ID" example:"1" validate:"required"` // 服务ID
}
func (*ServiceDeleteInput) BindingValidParams ¶
func (params *ServiceDeleteInput) BindingValidParams(c *gin.Context) error
type ServiceDetailInput ¶
type ServiceDetailInput struct {
ID int64 `json:"id" form:"id" comment:"服务ID" example:"1" validate:"required"` // 服务ID
}
func (*ServiceDetailInput) BindingValidParams ¶
func (params *ServiceDetailInput) BindingValidParams(c *gin.Context) error
type ServiceListInput ¶
type ServiceListInput struct { Info string `json:"info" form:"info" comment:"关键词" example:"" validate:""` // 关键词 PageNo int `json:"page_no" form:"page_no" comment:"页数" example:"1" validate:"required"` // 页数 PageSize int `json:"page_size" form:"page_size" comment:"每页条数" example:"20" validate:"required"` // 每页条数 }
func (*ServiceListInput) BindingValidParams ¶
func (params *ServiceListInput) BindingValidParams(c *gin.Context) error
type ServiceListItemOutput ¶
type ServiceListItemOutput struct { ID int64 `json:"id" form:"id"` // id ServiceName string `json:"service_name" form:"service_name"` // 服务名称 ServiceDesc string `json:"service_desc" form:"service_desc"` // 服务描述 ServiceAddr string `json:"service_addr" form:"service_addr"` // 服务地址 LoadType int `json:"load_type" form:"load_type"` // 服务类型 Qps int `json:"qps" form:"qps"` // qps Qpd int `json:"qpd" form:"qpd"` // qpd TotalNode int `json:"total_node" form:"total_node"` // 节点数 }
type ServiceListOutput ¶
type ServiceListOutput struct { Total int64 `json:"total" form:"total" comment:"总数" example:"" validate:""` // 总数 List []ServiceListItemOutput `json:"list" form:"list" comment:"列表" example:"" validate:""` // 列表 }
type ServiceStatInput ¶
type ServiceStatInput struct {
ID int64 `json:"id" form:"id" comment:"服务ID" example:"1" validate:"required"` // 服务ID
}
func (*ServiceStatInput) BindingValidParams ¶
func (params *ServiceStatInput) BindingValidParams(c *gin.Context) error
type ServiceStatOutput ¶
type ServiceUpdateGrpcInput ¶
type ServiceUpdateGrpcInput struct { ID int64 `json:"id" form:"id" comment:"服务ID" validate:"required"` // 服务ID ServiceName string `json:"service_name" form:"service_name" comment:"服务名称" validate:"required,valid_service_name"` // 服务名称 ServiceDesc string `json:"service_desc" form:"service_desc" comment:"服务描述" validate:"required"` // 服务描述 Port int `json:"port" form:"port" comment:"端口,需要设置8001-8999范围内" validate:"required,min=8001,max=8999"` // 端口,需要设置8001-8999范围内 HeaderTransfor string `json:"header_transfor" form:"header_transfor" comment:"metadata转换" validate:"valid_header_transfor"` // metadata转换 OpenAuth int `json:"open_auth" form:"open_auth" comment:"是否开启权限验证" validate:""` // 是否开启权限验证 BlackList string `` // 黑名单IP,以逗号间隔,白名单优先级高于黑名单 /* 135-byte string literal not displayed */ WhiteList string `` // 白名单IP,以逗号间隔,白名单优先级高于黑名单 /* 135-byte string literal not displayed */ WhiteHostName string `json:"white_host_name" form:"white_host_name" comment:"白名单主机,以逗号间隔" validate:"valid_iplist"` // 白名单主机,以逗号间隔 ClientIPFlowLimit int `json:"clientip_flow_limit" form:"clientip_flow_limit" comment:"客户端IP限流" validate:""` // 客户端IP限流 ServiceFlowLimit int `json:"service_flow_limit" form:"service_flow_limit" comment:"服务端限流" validate:""` // 服务端限流 RoundType int `json:"round_type" form:"round_type" comment:"轮询策略" validate:""` // 轮询策略 IpList string `json:"ip_list" form:"ip_list" comment:"IP列表" validate:"required,valid_ipportlist"` // IP列表 WeightList string `json:"weight_list" form:"weight_list" comment:"权重列表" validate:"required,valid_weightlist"` // 权重列表 ForbidList string `json:"forbid_list" form:"forbid_list" comment:"禁用IP列表" validate:"valid_iplist"` // 禁用IP列表 }
func (*ServiceUpdateGrpcInput) BindingValidParams ¶
func (params *ServiceUpdateGrpcInput) BindingValidParams(c *gin.Context) error
type ServiceUpdateHTTPInput ¶
type ServiceUpdateHTTPInput struct { ID int64 `json:"id" form:"id" comment:"服务 ID" example:"66" validate:"required,min=1"` // 服务 ID ServiceName string `json:"service_name" form:"service_name" comment:"服务名称" example:"" validate:"required,valid_service_name"` // 服务名称 ServiceDesc string `json:"service_desc" form:"service_desc" comment:"服务描述" example:"" validate:"required,max=255,min=1"` // 服务描述 RuleType int `json:"rule_type" form:"rule_type" comment:"接入类型" example:"" validate:"max=1,min=0"` // 接入类型 Rule string `json:"rule" form:"rule" comment:"接入路径:域名或前缀" example:"" validate:"required,valid_rule"` // 接入路径:域名或前缀 NeedHTTPs int `json:"need_https" form:"need_https" comment:"支持https" example:"" validate:"max=1,min=0"` // 支持https NeedStripURI int `json:"need_strip_uri" form:"need_strip_uri" comment:"启用strip_uri" example:"" validate:"max=1,min=0"` // 启用strip_uri NeedWebsocket int `json:"need_websocket" form:"need_websocket" comment:"是否支持websocket" example:"" validate:"max=1,min=0"` // 是否支持websocket UrlRewrite string `json:"url_rewrite" form:"url_rewrite" comment:"RUL重写功能" example:"" validate:"valid_url_rewrite"` // RUL重写功能 HeaderTransfor string `json:"header_transfor" form:"header_transfor" comment:"Header转换" example:"" validate:"valid_header_transfor"` // Header转换 OpenAuth int `json:"open_auth" form:"open_auth" comment:"是否开启权限" example:"" validate:"max=1,min=0"` // 是否开启权限 BlackList string `json:"black_list" form:"black_list" comment:"黑名单IP" example:"" validate:""` // 黑名单IP WhiteList string `json:"white_list" form:"white_list" comment:"白名单IP" example:"" validate:""` // 白名单IP ClientFlowLimit int `json:"client_flow_limit" form:"client_flow_limit" comment:"客户端IP限流" example:"" validate:"min=0"` // 客户端IP限流 ServiceFlowLimit int `json:"service_flow_limit" form:"service_flow_limit" comment:"服务端限流" example:"" validate:"min=0"` // 服务端限流 RoundType int `json:"round_type" form:"round_type" comment:"轮询方式" example:"" validate:"max=3,min=0"` // 轮询方式 IpList string `json:"ip_list" form:"ip_list" comment:"IP列表" example:"" validate:"required,valid_ipportlist"` // IP列表 WeightList string `json:"weight_list" form:"weight_list" comment:"IP权重" example:"" validate:"required,valid_weightlist"` // IP权重 UpstreamConnectTimeout int `json:"upstream_connect_timeout" form:"upstream_connect_timeout" comment:"建立连接超时" example:"" validate:"min=0"` // 建立连接超时 UpstreamHeaderTimeout int `json:"upstream_header_timeout" form:"upstream_header_timeout" comment:"获取header超时" example:"" validate:"min=0"` // 获取header超时 UpstreamIdleTimeout int `` // 链接最大空闲连接时间 /* 126-byte string literal not displayed */ UpstreamMaxIdle int `json:"upstream_max_idle" form:"upstream_max_idle" comment:"最大空闲连接数" example:"" validate:"min=0"` // 最大空闲连接数 }
func (*ServiceUpdateHTTPInput) BindingValidParams ¶
func (params *ServiceUpdateHTTPInput) BindingValidParams(c *gin.Context) error
type ServiceUpdateTcpInput ¶
type ServiceUpdateTcpInput struct { ID int64 `json:"id" form:"id" comment:"服务ID" validate:"required"` // 服务ID ServiceName string `json:"service_name" form:"service_name" comment:"服务名称" validate:"required,valid_service_name"` // 服务名称 ServiceDesc string `json:"service_desc" form:"service_desc" comment:"服务描述" validate:"required"` // 服务描述 Port int `json:"port" form:"port" comment:"端口,需要设置8001-8999范围内" validate:"required,min=8001,max=8999"` // 端口,需要设置8001-8999范围内 OpenAuth int `json:"open_auth" form:"open_auth" comment:"是否开启权限验证" validate:""` // 是否开启权限验证 BlackList string `` // 黑名单IP,以逗号间隔,白名单优先级高于黑名单 /* 135-byte string literal not displayed */ WhiteList string `` // 白名单IP,以逗号间隔,白名单优先级高于黑名单 /* 135-byte string literal not displayed */ WhiteHostName string `json:"white_host_name" form:"white_host_name" comment:"白名单主机,以逗号间隔" validate:"valid_iplist"` // 白名单主机,以逗号间隔 ClientIPFlowLimit int `json:"clientip_flow_limit" form:"clientip_flow_limit" comment:"客户端IP限流" validate:""` // 客户端IP限流 ServiceFlowLimit int `json:"service_flow_limit" form:"service_flow_limit" comment:"服务端限流" validate:""` // 服务端限流 RoundType int `json:"round_type" form:"round_type" comment:"轮询策略" validate:""` // 轮询策略 IpList string `json:"ip_list" form:"ip_list" comment:"IP列表" validate:"required,valid_ipportlist"` // IP列表 WeightList string `json:"weight_list" form:"weight_list" comment:"权重列表" validate:"required,valid_weightlist"` // 权重列表 ForbidList string `json:"forbid_list" form:"forbid_list" comment:"禁用IP列表" validate:"valid_iplist"` // 禁用IP列表 }
func (*ServiceUpdateTcpInput) BindingValidParams ¶
func (params *ServiceUpdateTcpInput) BindingValidParams(c *gin.Context) error
type TokensInput ¶
type TokensInput struct { GrantType string `json:"grant_type" form:"grant_type" comment:"授权类型" example:"client_credentials" validate:"required"` // 授权类型 Scope string `json:"scope" form:"scope" comment:"权限范围" example:"read_write" validate:"required"` // 权限范围 }
func (*TokensInput) BindingValidParams ¶
func (params *TokensInput) BindingValidParams(c *gin.Context) error
Source Files
¶
Click to show internal directories.
Click to hide internal directories.