@daocloud-proto/mcamel-mysql 0.5.0-865 → 0.5.0-867
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/mysql.pb.ts +69 -0
- package/package.json +1 -1
package/mysql.pb.ts
CHANGED
|
@@ -56,6 +56,11 @@ export enum Status {
|
|
|
56
56
|
MgrUnknown = "MgrUnknown",
|
|
57
57
|
}
|
|
58
58
|
|
|
59
|
+
export enum GetSlowlogListReqSortDir {
|
|
60
|
+
ASC = "ASC",
|
|
61
|
+
DESC = "DESC",
|
|
62
|
+
}
|
|
63
|
+
|
|
59
64
|
export enum GetMinioListReqSortDir {
|
|
60
65
|
ASC = "ASC",
|
|
61
66
|
DESC = "DESC",
|
|
@@ -156,6 +161,60 @@ export enum MysqlClusterItemStatusRestoreInitialStatus {
|
|
|
156
161
|
Succeeded = "Succeeded",
|
|
157
162
|
}
|
|
158
163
|
|
|
164
|
+
export type GetSlowlogConfReq = {
|
|
165
|
+
cluster?: string
|
|
166
|
+
namespace?: string
|
|
167
|
+
name?: string
|
|
168
|
+
instanceType?: InstanceType
|
|
169
|
+
}
|
|
170
|
+
|
|
171
|
+
export type GetSlowlogConfResp = {
|
|
172
|
+
longQueryTime?: string
|
|
173
|
+
}
|
|
174
|
+
|
|
175
|
+
export type DeleteSlowlogReq = {
|
|
176
|
+
cluster?: string
|
|
177
|
+
namespace?: string
|
|
178
|
+
name?: string
|
|
179
|
+
podName?: string[]
|
|
180
|
+
instanceType?: InstanceType
|
|
181
|
+
}
|
|
182
|
+
|
|
183
|
+
export type DeleteSlowlogResp = {
|
|
184
|
+
message?: string
|
|
185
|
+
}
|
|
186
|
+
|
|
187
|
+
export type GetSlowlogListReq = {
|
|
188
|
+
page?: number
|
|
189
|
+
pageSize?: number
|
|
190
|
+
sortDir?: GetSlowlogListReqSortDir
|
|
191
|
+
sortBy?: string
|
|
192
|
+
searchKey?: string
|
|
193
|
+
cluster?: string
|
|
194
|
+
namespace?: string
|
|
195
|
+
name?: string
|
|
196
|
+
podName?: string
|
|
197
|
+
instanceType?: InstanceType
|
|
198
|
+
fromDate?: string
|
|
199
|
+
toDate?: string
|
|
200
|
+
}
|
|
201
|
+
|
|
202
|
+
export type GetSlowlogListRespItem = {
|
|
203
|
+
startTime?: string
|
|
204
|
+
db?: string
|
|
205
|
+
sqlText?: string
|
|
206
|
+
queryTime?: string
|
|
207
|
+
lockTime?: string
|
|
208
|
+
rowsExamined?: string
|
|
209
|
+
rowsSent?: string
|
|
210
|
+
userHost?: string
|
|
211
|
+
}
|
|
212
|
+
|
|
213
|
+
export type GetSlowlogListResp = {
|
|
214
|
+
items?: GetSlowlogListRespItem[]
|
|
215
|
+
pagination?: CommonCommon.Pagination
|
|
216
|
+
}
|
|
217
|
+
|
|
159
218
|
export type GetTopologyRequest = {
|
|
160
219
|
cluster?: string
|
|
161
220
|
namespace?: string
|
|
@@ -509,6 +568,7 @@ export type CreateMysqlReq = {
|
|
|
509
568
|
affinity?: CommonCommon.Affinity
|
|
510
569
|
serviceMonitorInterval?: string
|
|
511
570
|
accessWhitelist?: CommonCommon.AccessWhitelist
|
|
571
|
+
enableSlowQueryLog?: boolean
|
|
512
572
|
externalTrafficPolicy?: CommonCommon.ExternalTrafficPolicy
|
|
513
573
|
lbTyp?: CommonCommon.LBTyp
|
|
514
574
|
lbPoolName?: string
|
|
@@ -789,4 +849,13 @@ export class MysqlMgr {
|
|
|
789
849
|
static GetTopology(req: GetTopologyRequest, initReq?: fm.InitReq): Promise<GetTopologyResp> {
|
|
790
850
|
return fm.fetchReq<GetTopologyRequest, GetTopologyResp>(`/apis/mcamel.io/mysql/v1alpha2/${req["cluster"]}/${req["namespace"]}/${req["name"]}/${req["instanceType"]}/topology?${fm.renderURLSearchParams(req, ["cluster", "namespace", "name", "instanceType"])}`, {...initReq, method: "GET"})
|
|
791
851
|
}
|
|
852
|
+
static GetSlowlogList(req: GetSlowlogListReq, initReq?: fm.InitReq): Promise<GetSlowlogListResp> {
|
|
853
|
+
return fm.fetchReq<GetSlowlogListReq, GetSlowlogListResp>(`/apis/mcamel.io/mysql/v1alpha2/${req["cluster"]}/${req["namespace"]}/${req["name"]}/${req["podName"]}/${req["instanceType"]}/slowlog?${fm.renderURLSearchParams(req, ["cluster", "namespace", "name", "podName", "instanceType"])}`, {...initReq, method: "GET"})
|
|
854
|
+
}
|
|
855
|
+
static DeleteSlowlog(req: DeleteSlowlogReq, initReq?: fm.InitReq): Promise<DeleteSlowlogResp> {
|
|
856
|
+
return fm.fetchReq<DeleteSlowlogReq, DeleteSlowlogResp>(`/apis/mcamel.io/mysql/v1alpha2/mysql/${req["cluster"]}/${req["namespace"]}/${req["name"]}/${req["instanceType"]}/slowlog`, {...initReq, method: "DELETE"})
|
|
857
|
+
}
|
|
858
|
+
static GetSlowlogConf(req: GetSlowlogConfReq, initReq?: fm.InitReq): Promise<GetSlowlogConfResp> {
|
|
859
|
+
return fm.fetchReq<GetSlowlogConfReq, GetSlowlogConfResp>(`/apis/mcamel.io/mysql/v1alpha2/${req["cluster"]}/${req["namespace"]}/${req["name"]}/${req["instanceType"]}/slowlog/conf?${fm.renderURLSearchParams(req, ["cluster", "namespace", "name", "instanceType"])}`, {...initReq, method: "GET"})
|
|
860
|
+
}
|
|
792
861
|
}
|