provisioner.yaml 12 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419
  1. swagger: '2.0'
  2. x-interface-model: cluster
  3. x-endpoint-name: dw
  4. x-releases: DW,SDX
  5. info:
  6. version: 0.1-SNAPSHOT
  7. title: Cloudera Data Warehouse
  8. license:
  9. name: Apache 2.0
  10. description: Cloudera Data Warehouse is a service that makes it easy to analyze large amounts of data efficiently.
  11. schemes:
  12. - http
  13. consumes:
  14. - application/json
  15. produces:
  16. - application/json
  17. paths:
  18. /dw/createCluster:
  19. post:
  20. summary: Creates a new cluster.
  21. description: Creates a new cluster.
  22. operationId: createCluster
  23. x-entitlement: DW
  24. parameters:
  25. - name: input
  26. in: body
  27. required: true
  28. schema:
  29. $ref: '#/definitions/CreateClusterRequest'
  30. responses:
  31. 200:
  32. description: Expected response to a valid request.
  33. schema:
  34. $ref: '#/definitions/CreateClusterResponse'
  35. default:
  36. description: The default response on an error.
  37. schema:
  38. $ref: '#/definitions/Error'
  39. /dw/deleteCluster:
  40. post:
  41. summary: Deletes a cluster.
  42. description: Deletes a cluster.
  43. operationId: deleteCluster
  44. parameters:
  45. - name: input
  46. in: body
  47. required: true
  48. schema:
  49. $ref: '#/definitions/DeleteClusterRequest'
  50. responses:
  51. 200:
  52. description: Expected response to a valid request.
  53. schema:
  54. $ref: '#/definitions/DeleteClusterResponse'
  55. default:
  56. description: The default response on an error.
  57. schema:
  58. $ref: '#/definitions/Error'
  59. /dw/listClusters:
  60. post:
  61. summary: Lists clusters.
  62. description: Lists clusters. If no cluster names are specified, the call lists all clusters.
  63. operationId: listClusters
  64. x-right: dw/listClusters
  65. x-paginates: true
  66. x-paging-default-max-items: 100
  67. parameters:
  68. - name: input
  69. in: body
  70. required: true
  71. schema:
  72. $ref: '#/definitions/ListClustersRequest'
  73. responses:
  74. 200:
  75. description: Expected response to a valid request.
  76. schema:
  77. $ref: '#/definitions/ListClustersResponse'
  78. default:
  79. description: The default response on an error.
  80. schema:
  81. $ref: '#/definitions/Error'
  82. /dw/describeCluster:
  83. post:
  84. summary: Describe a cluster.
  85. description: Describe a cluster.
  86. operationId: describeCluster
  87. x-right: dw/describeCluster
  88. parameters:
  89. - name: input
  90. in: body
  91. required: true
  92. schema:
  93. $ref: '#/definitions/DescribeClusterRequest'
  94. responses:
  95. 200:
  96. description: Expected response to a valid request.
  97. schema:
  98. $ref: '#/definitions/DescribeClusterResponse'
  99. default:
  100. description: The default response on an error.
  101. schema:
  102. $ref: '#/definitions/Error'
  103. /dw/updateCluster:
  104. post:
  105. summary: Update a cluster.
  106. description: Update a cluster.
  107. operationId: updateCluster
  108. x-right: dw/updateClusters
  109. parameters:
  110. - name: input
  111. in: body
  112. required: true
  113. schema:
  114. $ref: '#/definitions/UpdateClusterRequest'
  115. responses:
  116. 200:
  117. description: Expected response to a valid request.
  118. schema:
  119. $ref: '#/definitions/UpdateClusterResponse'
  120. default:
  121. description: The default response on an error.
  122. schema:
  123. $ref: '#/definitions/Error'
  124. definitions:
  125. Error:
  126. type: object
  127. description: An object returned on an error.
  128. properties:
  129. code:
  130. type: string
  131. description: The error code.
  132. message:
  133. type: string
  134. description: The error message.
  135. ClusterSummary:
  136. type: object
  137. description: Information about a cluster.
  138. required:
  139. - clusterName
  140. - crn
  141. - creationDate
  142. - cdhVersion
  143. - workerCpuCores
  144. - workerMemoryInGib
  145. - workerReplicas
  146. - workerReplicasOnline
  147. - workerAutoResize
  148. - status
  149. properties:
  150. clusterName:
  151. type: string
  152. description: The name of the cluster.
  153. crn:
  154. type: string
  155. description: The CRN of the cluster.
  156. creationDate:
  157. type: string
  158. format: date-time
  159. description: The date when the cluster was created.
  160. status:
  161. $ref: '#/definitions/ClusterStatus'
  162. description: The status of the cluster.
  163. cdhVersion:
  164. type: string
  165. description: The CDH version for the cluster.
  166. workerCpuCores:
  167. type: integer
  168. format: int32
  169. description: CPU cores per worker.
  170. workerMemoryInGib:
  171. type: integer
  172. format: int32
  173. description: Memory in GiB per worker.
  174. workerReplicas:
  175. type: integer
  176. format: int32
  177. description: Number of worker replicas.
  178. workerReplicasOnline:
  179. type: integer
  180. format: int32
  181. description: Number of worker replicas currently online.
  182. workerAutoResize:
  183. type: boolean
  184. description: If the number of worker replicas is auto scaling.
  185. Cluster:
  186. type: object
  187. description: Information about a cluster.
  188. required:
  189. - clusterName
  190. - crn
  191. - creationDate
  192. - cdhVersion
  193. - workerCpuCores
  194. - workerMemoryInGib
  195. - workerReplicas
  196. - workerReplicasOnline
  197. - workerAutoResize
  198. - status
  199. properties:
  200. clusterName:
  201. type: string
  202. description: The name of the cluster.
  203. crn:
  204. type: string
  205. description: The CRN of the cluster.
  206. creationDate:
  207. type: string
  208. format: date-time
  209. description: The date when the cluster was created.
  210. status:
  211. $ref: '#/definitions/ClusterStatus'
  212. description: The status of the cluster.
  213. cdhVersion:
  214. type: string
  215. description: The CDH version for the cluster.
  216. workerCpuCores:
  217. type: integer
  218. format: int32
  219. description: CPU cores per worker.
  220. workerMemoryInGib:
  221. type: integer
  222. format: int32
  223. description: Memory in GiB per worker.
  224. workerReplicas:
  225. type: integer
  226. format: int32
  227. description: Number of worker replicas.
  228. workerReplicasOnline:
  229. type: integer
  230. format: int32
  231. description: Number of worker replicas currently online.
  232. workerAutoResize:
  233. type: boolean
  234. description: If the number of worker replicas is auto scaling.
  235. coordinatorEndpoint:
  236. $ref: '#/definitions/Endpoint'
  237. description: The connection endpoint for the cluster coordinator.
  238. adminEndpoint:
  239. $ref: '#/definitions/Endpoint'
  240. description: The connection endpoint for the cluster administration UI.
  241. Endpoint:
  242. type: object
  243. description: A network endpoint that has both a public and a private hostname or IP address.
  244. required:
  245. - privateHost
  246. - publicHost
  247. - port
  248. properties:
  249. privateHost:
  250. type: string
  251. description: A private IP address or hostname. This is only accessible from within the pod network.
  252. publicHost:
  253. type: string
  254. description: A public IP address or hostname. This is routable from external services.
  255. port:
  256. type: integer
  257. format: int32
  258. description: A port.
  259. ClusterStatus:
  260. type: string
  261. description: The status of a cluster.
  262. enum:
  263. - STARTING
  264. - ONLINE
  265. - SCALING_UP
  266. - SCALING_DOWN
  267. - TERMINATING
  268. - STOPPED
  269. - FAILED
  270. CreateClusterRequest:
  271. type: object
  272. description: Request object for a create cluster request.
  273. required:
  274. - clusterName
  275. properties:
  276. clusterName:
  277. type: string
  278. description: The name of the cluster. This name must be unique, must have a maximum of 128 characters, and must contain only alphanumeric characters and hyphens. Names are case-sensitive.
  279. cdhVersion:
  280. type: string
  281. description: The CDH version.
  282. workerCpuCores:
  283. type: integer
  284. format: int32
  285. description: CPU cores per worker.
  286. workerMemoryInGib:
  287. type: integer
  288. format: int32
  289. description: Memory in GiB per worker.
  290. workerReplicas:
  291. type: integer
  292. format: int32
  293. description: Number of worker replicas.
  294. CreateClusterResponse:
  295. type: object
  296. description: Response object for a create cluster request.
  297. required:
  298. - cluster
  299. properties:
  300. cluster:
  301. $ref: '#/definitions/Cluster'
  302. description: The cluster that was created.
  303. UpdateClusterRequest:
  304. type: object
  305. description: Request object for an update cluster request.
  306. required:
  307. - clusterName
  308. properties:
  309. clusterName:
  310. type: string
  311. description: The name of the cluster. This name must be unique, must have a maximum of 128 characters, and must contain only alphanumeric characters and hyphens. Names are case-sensitive.
  312. cdhVersion:
  313. type: string
  314. description: The CDH version.
  315. workerCpuCores:
  316. type: integer
  317. format: int32
  318. description: CPU cores per worker.
  319. workerMemoryInGib:
  320. type: integer
  321. format: int32
  322. description: Memory in GiB per worker.
  323. workerReplicas:
  324. type: integer
  325. format: int32
  326. description: Number of worker replicas.
  327. updateClusterAutoResizeChanged:
  328. type: boolean
  329. description: If we change the worker autoscaling policy.
  330. updateClusterAutoResize:
  331. type: boolean
  332. description: If the autoscaling was turned off or on.
  333. updateClusterAutoResizeMax:
  334. type: integer
  335. format: int32
  336. description: Max number of replica when autoscaling if on.
  337. updateClusterAutoResizeMin:
  338. type: integer
  339. format: int32
  340. description: Max number of replica when autoscaling if on (optional).
  341. updateClusterAutoResizeCpu:
  342. type: integer
  343. format: int32
  344. description: CPU integer % (e.g. 80) when autoscaling if on (optional).
  345. UpdateClusterResponse:
  346. type: object
  347. description: Response object for an update cluster request.
  348. required:
  349. - cluster
  350. properties:
  351. cluster:
  352. $ref: '#/definitions/Cluster'
  353. description: The cluster that was updated.
  354. DeleteClusterRequest:
  355. type: object
  356. description: Request object for a delete cluster request.
  357. required:
  358. - clusterName
  359. properties:
  360. clusterName:
  361. type: string
  362. description: The name or CRN of the cluster.
  363. DeleteClusterResponse:
  364. type: object
  365. description: Response object for a delete cluster request.
  366. ListClustersRequest:
  367. type: object
  368. description: Request object for a list clusters request.
  369. properties:
  370. clusterNames:
  371. type: array
  372. items:
  373. type: string
  374. description: The names or CRNs of the clusters.
  375. pageSize:
  376. type: integer
  377. format: int32
  378. minimum: 1
  379. maximum: 100
  380. x-paging-page-size: true
  381. description: The size of each page.
  382. startingToken:
  383. type: string
  384. x-paging-input-token: true
  385. description: A token to specify where to start paginating. This is the nextToken from a previously truncated response.
  386. ListClustersResponse:
  387. type: object
  388. description: Response object for a list clusters request.
  389. required:
  390. - clusters
  391. properties:
  392. clusters:
  393. type: array
  394. items:
  395. $ref: '#/definitions/ClusterSummary'
  396. x-paging-result: true
  397. description: The clusters.
  398. nextToken:
  399. type: string
  400. x-paging-output-token: true
  401. description: The token to use when requesting the next set of results. If not present, there are no additional results.
  402. DescribeClusterRequest:
  403. type: object
  404. description: Request object for a describe cluster request.
  405. required:
  406. - clusterName
  407. properties:
  408. clusterName:
  409. type: string
  410. description: The name or CRN of the cluster.
  411. DescribeClusterResponse:
  412. type: object
  413. description: Response object for a describe cluster request.
  414. required:
  415. - cluster
  416. properties:
  417. cluster:
  418. $ref: '#/definitions/Cluster'
  419. description: The cluster.