This repository has been archived by the owner on Jan 8, 2024. It is now read-only.
forked from hortonworks/cloudbreak
-
Notifications
You must be signed in to change notification settings - Fork 0
/
apiary.apib
1305 lines (1047 loc) · 39.3 KB
/
apiary.apib
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
FORMAT: 1A
# Cloudbreak
![SequenceIQ](https://raw.githubusercontent.com/sequenceiq/sequenceiq.github.io/master/img/logo.png)
*Cloudbreak is a powerful left surf that breaks over a coral reef, a mile off southwest the island of Tavarua, Fiji.*
*Cloudbreak is a cloud agnostic Hadoop as a Service API. Abstracts the provisioning and ease management and monitoring of on-demand clusters.*
SequenceIQ's Cloudbreak is a RESTful application development platform with the goal of helping developers to build solutions for deploying Hadoop YARN clusters in different environments. Once it is deployed in your favourite servlet container it exposes a REST API allowing to span up Hadoop clusters of arbitary sizes and cloud providers. Provisioning Hadoop has never been easier.
Cloudbreak is built on the foundation of cloud providers API (Amazon AWS, Microsoft Azure), Apache Ambari, Docker lightweight containers, Serf and dnsmasq. For further product documentation follow the link: http://sequenceiq.com/cloudbreak/
##Benefits
###Secure
Supports a token based and OAuth2 authentication model. The cluster is provisioned in a logically isolated network (Virtual Private Cloud) of your cloud favourite cloud provider. If the cluster is launched in a VPC network, the framework configure firewall settings that control the network access of your launched instances. For example a Hadoop Resource Manager can be accessed from the internet, whereas none of the other nodes are available. Cloudbreak does not store or manages your cloud credentials - it is the end user's responsibility to link Cloudbreak with her/his cloud account. We provide utilities to ease this process (IAM on Amazon, certificates on Azure).
###Elastic
Cloudbreak API can provision an arbitrary number of Hadoop nodes - the API does the hard work and span up the cluster, configure the networks and the selected Hadoop services without any interaction. POST once and use it anytime after.
###Scalable
As the workload changes, the API allows you to add or remove nodes on the fly. Cloudbreak does the hard work of reconfiguring the infrastructure, provision or decommission Hadoop nodes and let the cluster be continuously operational. Once provisioned, new nodes will take up the load and increase the cluster throughput.
###Declarative Hadoop clusters
Supports different Hadoop cluster blueprints. Hostgroups defined in blueprints can be associated to different VPC subnets and availability zones, thus you can span up a cluster for deploying highly available applications.
###Flexible
Allows the option to choose the favourite cloud provider and different pricing models. The API translated the calls towards different cloud vendors - uses one common API, no need to rewrite the code when changing between cloud providers.
# Group User authentication
*Note:* The **Cloudbreak API** no longer contains user authentication and user management endpoints as these became part of our OAuth2 based central identity management service.
All operations against the API must contain a valid access token obtained from our identity server.
The access token must travel in a standard **Authorization** header like `Authorization: Bearer some.valid.access.token`
Examples of getting an access token:
- with the **authorization_code** flow from a web application: [Uluwatu](https://github.com/sequenceiq/uluwatu/blob/master/server.js)
- with the **implicit** flow from a command line shell application: [Cloudbreak shell](https://github.com/sequenceiq/cloudbreak-shell/blob/master/src/main/java/com/sequenceiq/cloudbreak/shell/configuration/ShellConfiguration.java)
A token can only be obtained by a client that's registered at our identity server. Registering custom clients is currently not supported but planned in a later release.
If you'd like to create a custom client for our deployed Cloudbreak API and use our identity server, please contact us.
# Group Cloud authentication
Cloud Authentication related resources of the **Cloudbreak API**.
Adds an AWS IAM role ARN or Azure JKS to user's account.
## Add cloud credentials for a user [/user/credentials]
### Add credentials [POST]
Adds an AWS IAM role ARN with the user's account.
+ Request
+ Headers
x-auth-token: user:c45sdfdsfo234jgkhsdgf324
+ Body
{
"name": "sqiq-0002",
"cloudPlatform": "AWS",
"description": "My aws credential",
"publicKey": "ssh-rsa AAAAB3NzaC1yc2EAAAADAQABAAABAQCasJyap4swb4Hk4xOlnF3OmKVwzmv2e053yrtvcUPaxCeboSltOBReuTQxX+kYCgKCdtEwpIvEDXk16T6nCI4tSptAalFgpUWn+JOysCuLuWnwrk6mSKOzEiPYCrB54444mDY6rbBDSRuE/VUYQ/yi0imocARlOiFdPRlZGTN0XGE1V8LSo+m0oIzTwBKn58I4v5iB4ZUL/6adGXo7dgdBh/Fmm4uYbgrCZnL1kldjfksjdfkskdjlfEaKpMxSG76XWhuzFpHjLkRndz88ha0rB6davag6nZGdno5IepLAWg9oB4jTApHwhN2j1rWLN2y1c+pTxsF6LxBiN5rsYKR495VFmuOepLYz5I8Dn sequence-eu",
"parameters": {
"roleArn": "arn:aws:iam::755047402263:role/seq-self-cf"
}
}
+ Response 201 (application/json)
{
"id":51
}
## Add cloud credentials for the user [/user/credentials]
### Add credential [POST]
Adds an Azure JKS the user's account.
Use `openssl` to generate an X509 certificate with a 2048-bit RSA keypair. Please answer the few questions that the openssl prompts for (or you may leave them blank). The content in these fields is not used by the platform:
openssl req -x509 -nodes -days 365 -newkey rsa:2048 -keyout myPrivateKey.key -out myCert.pem
The content of the myCert.pem file is the publicKey in the request
+ Request
+ Headers
x-auth-token: user:c45sdfdsfo234jgkhsdgf324
+ Body
{
"name": "sqiq-0001",
"cloudPlatform": "AZURE",
"description": "My azure credential",
"publicKey": "-----BEGIN CERTIFICATE-----MIICsDCCAhmgAwIBAgIJAPtq+czPZYU/MA0GCSqGSIb3DQEBBQUAMEUxCzAJBgNVBAYTAkFVMRMwEQYDVQQIEwpTb21lLVN0YXRlMSEwHw-----END CERTIFICATE-----",
"parameters": {
"subscriptionId": "1234-5678-1234-5678",
"jksPassword": "pw123"
}
}
+ Response 201 (application/json)
{
"id":50
}
## Retrieve cloud credentials for the user [/user/credentials]
### Retrieve credentials [GET]
Retrieves registered cloud credentials for a user
+ Request
+ Headers
x-auth-token: user:c45sdfdsfo234jgkhsdgf324
+ Response 200 (application/json)
[
{
"id": 50,
"description": "my sample description1",
"parameters": {
"roleArn": "arn:aws:iam::755047402263:role/seq-self-cf",
"instanceProfileRoleArn": "arn:aws:iam::755047402263:instance-profile/readonly-role"
},
"cloudPlatform": "AWS",
"name": "aws_credential"
},
{
"id": 51,
"description": "my sample description2",
"parameters": {
"roleArn": "arn:aws:iam::755047402263:role/seq-self-cf"
},
"cloudPlatform": "AWS",
"name": "lp-0002"
}
]
## Retrieve a specific cloud credential for the user [/credentials/{id}]
### Retrieve credential [GET]
Retrieves the cloud credential (AWS or Azure) associated with the user account
+ Parameters
+ id (required String `id`) ... The identifier of the user cloud `credential` entry
+ Request
+ Headers
x-auth-token: user:c45sdfdsfo234jgkhsdgf324
+ Response 200 (application/json)
{
"id": 50,
"description": "my sample description1",
"parameters": {
"roleArn": "arn:aws:iam::755047402263:role/seq-self-cf"
},
"cloudPlatform": "AWS",
"name": "aws_credential"
}
## Delete the specified cloud credentials from the user account [/credentials/{id}]
### Deletes the specified cloud credentials [DELETE]
+ Parameters
+ id (required String `id`) ... The identifier of cloud `credential`.
+ Request
+ Headers
x-auth-token: user:c45sdfdsfo234jgkhsdgf324
+ Response 200 (application/json)
{
}
# Group Templates
Template related resources of the **Cloudbreak API**.
AWS or Azure cloud templates allow configuration of VPC, subnet, internet gateway, route table, securityGroups, ACLs, instances.
Templates describe cloud infrastructures and are used for creating cloud stacks - such as running cloud infrastructures.
#### Our default AMIs on amazon:
+ eu-west-1: ami-7778af00
+ us-east-1: ami-d89955b0
+ us-west-2: ami-17b0c927
+ us-west-1: ami-314a4974
+ ap-southeast-1: ami-468bd214
+ ap-northeast-1: ami-0bcd9d0a
+ ap-southeast-2: ami-678bec5d
+ sa-east-1: ami-1b0ca206
#### Our default Image name on Azure:
+ ambari-docker-v1
#### Amazon instance types:
+ T2Micro
+ T2Small
+ T2Medium
+ M3Medium
+ M3Large
+ M3Xlarge
+ M32xlarge
#### Azure vm types:
+ EXTRA_SMALL
+ SMALL
+ MEDIUM
+ LARGE
+ EXTRA_LARGE
## Create cloud template [/user/templates]
### Create AWS template [POST]
Creates an AWS template (vpc, subnet, internetGateway, routeTable, securityGroups, ACLs, instances). The template internally is using an Amazon AWS Cloudformation template.
+ Request
+ Headers
x-auth-token: user:c45sdfdsfo234jgkhsdgf324
+ Body
{
"cloudPlatform": "AWS",
"name": "my-template-1",
"description": "My aws template"
"parameters": {
"sshLocation": "0.0.0.0/0"
"region": "eu-west-1",
"instanceType": "M3Xlarge",
"amiId": "ami-12345678"
}
}
+ Response 200 (application/json)
{
"id": "1"
}
### Create Azure template [POST]
Creates an Azure cloud template. (vpc, subnet, instances)
+ Request
+ Headers
x-auth-token: user:c45sdfdsfo234jgkhsdgf324
+ Body
{
"cloudPlatform": "AZURE",
"name": "my-azure-cluster",
"description": "my azure template"
"parameters": {
"location": "NORTH_EUROPE",
"imageName": "sequnceiq-ambari-docker-v1",
"password": "Password!@#$",
"vmType": "SMALL",
}
}
+ Response 200 (application/json)
{
"id": "2"
}
## Retrieve templates for a user [/user/templates]
### List templates [GET]
Retrieves a list with the cloud templates belonging to the user
+ Request
+ Headers
x-auth-token: user:c45sdfdsfo234jgkhsdgf324
+ Body
{
}
+ Response 200 (application/json)
[
{
"cloudPlatform": "AWS",
"name": "my-template-1",
"description": "My azure template",
"parameters": {
"sshLocation": "0.0.0.0/0"
"region": "eu-west-1",
"keyName": "sequence-eu",
"instanceType": "m3.xlarge"
"amiId": "ami-12345678"
}
},
{
"cloudPlatform": "AZURE",
"name": "my-azure-cluster",
"description": "my azure template"
"parameters": {
"location": "NORTH_EUROPE",
"imageName": "sequnceiq-ambari-docker-v1",
"password": "Password!@#$",
"vmType": "SMALL",
}
}
]
## Retrieve the given template for the user [/templates/{id}]
### Retrieve a particular AWS or Azure template by id [GET]
Retrieves the AWS or Azure template by submitting the template ID
+ Parameters
+ id (required String `id`) ... The identifier of the `template`.
+ Request
+ Headers
x-auth-token: user:c45sdfdsfo234jgkhsdgf324
+ Response 200 (application/json)
{
"id":"stack-123",
{
"cloudPlatform": "AWS",
"name": "my-template-1",
"description": "My azure template",
"parameters": {
"sshLocation": "0.0.0.0/0"
"region": "eu-west-1",
"keyName": "sequence-eu",
"instanceType": "m3.xlarge"
"amiId": "ami-12345678"
}
}
}
## Delete the specified template from the database [/templates/{id}]
### Delete the specified template [DELETE]
Deletes the specified template from the database, unless there is a cloud instance created from this template.
+ Parameters
+ id (required String `id`) ... The identifier of the `template`.
+ Request
+ Headers
x-auth-token: user:c45sdfdsfo234jgkhsdgf324
+ Response 200 (application/json)
{
}
# Group Blueprints
Hadoop blueprint related resources of the **Cloudbreak API**.
Allows configurations of different blueprints to be used later to create Hadoop cluster instances.
## Adding Hadoop blueprints [/user/blueprints]
### Create blueprint [POST]
Creates a Hadoop blueprint. The blueprint specifies Hadoop services and other Hadoop specific configuration.
The cardinality specifies the desired number of nodes for the hostgroup. When the cluster is created this number can be overridden.
+ Request
+ Headers
x-auth-token: user:c45sdfdsfo234jgkhsdgf324
+ Body
{
"name": "multi-node-hdfs-yarn",
"description": "My multinode blueprint",
"ambariBlueprint": {
"Blueprints": {
"blueprint_name": "multi-node-hdfs-yarn",
"stack_name": "HDP",
"stack_version": "2.0"
},
"hostGroups": [
{
"name": "master",
"components": [
{
"name": "NAMENODE"
},
{
"name": "SECONDARY_NAMENODE"
},
{
"name": "RESOURCEMANAGER"
},
{
"name": "HISTORYSERVER"
},
{
"name": "NAGIOS_SERVER"
},
{
"name": "ZOOKEEPER_SERVER"
}
],
"cardinality": "1"
},
{
"name": "slaves",
"components": [
{
"name": "DATANODE"
},
{
"name": "HDFS_CLIENT"
},
{
"name": "NODEMANAGER"
},
{
"name": "YARN_CLIENT"
},
{
"name": "MAPREDUCE2_CLIENT"
},
{
"name": "ZOOKEEPER_CLIENT"
}
],
"cardinality": "2"
}
]
}
}
+ Response 200 (application/json)
{
}
## Create Hadoop blueprints [/user/blueprints]
### Create a blueprint [POST]
Creates a Hadoop blueprint using the provided `url`
+ Request
+ Headers
x-auth-token: user:c45sdfdsfo234jgkhsdgf324
+ Body
{
"name": "multi-node-hdfs-yarn",
"description": "My multinode blueprint",
"url": "http://url.com/blueprint.json"
}
+ Response 200 (application/json)
{
}
## Retrieve Hadoop blueprints [/user/blueprints]
### List blueprints for the user [GET]
Retrieve blueprints for the user
+ Request
+ Headers
x-auth-token: user:c45sdfdsfo234jgkhsdgf324
+ Body
{
}
+ Response 200 (application/json)
{
"id": "51"
"name": "my-ambari-cluster-1",
"description": "My multinode blueprint",
"blueprintName": "multi-node-hdfs-yarn",
"ambariBlueprint": {
"host_groups" : [
{
"name" : "master",
"components" : [
{
"name" : "NAMENODE"
},
{
"name" : "SECONDARY_NAMENODE"
},
{
"name" : "RESOURCEMANAGER"
},
{
"name" : "HISTORYSERVER"
},
{
"name" : "NAGIOS_SERVER"
},
{
"name" : "ZOOKEEPER_SERVER"
}
],
"cardinality" : "1"
},
{
"name" : "slaves",
"components" : [
{
"name" : "DATANODE"
},
{
"name" : "HDFS_CLIENT"
},
{
"name" : "NODEMANAGER"
},
{
"name" : "YARN_CLIENT"
},
{
"name" : "MAPREDUCE2_CLIENT"
},
{
"name" : "ZOOKEEPER_CLIENT"
}
],
"cardinality" : "2"
}
],
"Blueprints" : {
"blueprint_name" : "multi-node-hdfs-yarn",
"stack_name" : "HDP",
"stack_version" : "2.0"
}
}
}
## Retrieve blueprints [/blueprints/{id}]
### Retrieve a particular blueprint for the user [GET]
+ Parameters
+ id (required String `id`) ... The identifier of the `blueprint`
+ Request
+ Headers
x-auth-token: user:c45sdfdsfo234jgkhsdgf324
+ Response 200 (application/json)
{
"id": "51"
"name": "my-ambari-cluster-1",
"description": "My multinode blueprint",
"blueprintName": "multi-node-hdfs-yarn",
"ambariBlueprint": {
"host_groups" : [
{
"name" : "master",
"components" : [
{
"name" : "NAMENODE"
},
{
"name" : "SECONDARY_NAMENODE"
},
{
"name" : "RESOURCEMANAGER"
},
{
"name" : "HISTORYSERVER"
},
{
"name" : "NAGIOS_SERVER"
},
{
"name" : "ZOOKEEPER_SERVER"
}
],
"cardinality" : "1"
},
{
"name" : "slaves",
"components" : [
{
"name" : "DATANODE"
},
{
"name" : "HDFS_CLIENT"
},
{
"name" : "NODEMANAGER"
},
{
"name" : "YARN_CLIENT"
},
{
"name" : "MAPREDUCE2_CLIENT"
},
{
"name" : "ZOOKEEPER_CLIENT"
}
],
"cardinality" : "2"
}
],
"Blueprints" : {
"blueprint_name" : "multi-node-hdfs-yarn",
"stack_name" : "HDP",
"stack_version" : "2.0"
}
}
}
## Delete blueprint [/blueprints/{id}]
### Deletes the specified blueprint [DELETE]
WARNING: Deletes the specified blueprint from the database.
+ Parameters
+ id (required String `id`) ... The identifier of the `blueprint`
+ Request
+ Headers
x-auth-token: user:c45sdfdsfo234jgkhsdgf324
+ Response 200 (application/json)
{
}
# Group Stacks
Stacks related resources of the **Cloudbreak API**.
Manages AWS or Azure clouds based on templates. Creates, launches, stops, deletes the specified number of instances in the selected template (infrastructure).
## Create cloud [/user/stacks]
### Create stack [POST]
Creates an AWS or Azure cloud from a template.
+ Request
+ Headers
x-auth-token: user:c45sdfdsfo234jgkhsdgf324
+ Body
{
"name": "my-cloud-1",
"description": "my testing cloud",
"clusterSize": 3,
"templateId": "1"
}
+ Response 200 (application/json)
{
"id": "1"
}
## Retrieve stacks for the user [/user/stacks]
### List stacks [GET]
Retrieves the cloud stacks belonging to the user
+ Request
+ Headers
x-auth-token: user:c45sdfdsfo234jgkhsdgf324
+ Body
{
}
+ Response 200 (application/json)
{
[
"metadata": [
{
"dockerSubnet": "172.17.10",
"ambariServer": true,
"instanceIndex": 0,
"instanceId": "i-fab627b8",
"publicIp": "54.77.43.59",
"privateIp": "10.0.0.136"
},
{
"dockerSubnet": "172.17.11",
"ambariServer": false,
"instanceIndex": 1,
"instanceId": "i-1bb92859",
"publicIp": "54.77.43.60",
"privateIp": "10.0.0.135"
},
{
"dockerSubnet": "172.17.12",
"ambariServer": false,
"instanceIndex": 2,
"instanceId": "i-1ab92858",
"publicIp": "54.77.43.61",
"privateIp": "10.0.0.137"
}
],
"cluster": {
"description": "",
"blueprintId": 50,
"cluster": {},
"minutesUp": 8,
"hoursUp": 0,
"status": "CREATE_COMPLETED",
"id": 2
},
"hash": "208d3dd389fad2221311792106cde53d",
"ambariServerIp": "54.77.43.59",
"nodeCount": 3,
"name": "awstest",
"templateId": 50,
"credentialId": 50,
"id": 50,
"cloudPlatform": "AWS",
"description": {
--AWS DESCRIPTION--
},
"status": "CREATE_COMPLETED"
]
}
## Retrieve a stack [/stacks/{id}]
### Retrieve a particular stack [GET]
Retrieves a (AWS or Azure) stack definition.
+ Parameters
+ id (required String `id`) ... The identifier of the `stack`.
+ Request
+ Headers
x-auth-token: user:c45sdfdsfo234jgkhsdgf324
+ Response 200 (application/json)
{
"metadata": [
{
"dockerSubnet": "172.17.10",
"ambariServer": true,
"instanceIndex": 0,
"instanceId": "i-fab627b8",
"publicIp": "54.77.43.59",
"privateIp": "10.0.0.136"
},
{
"dockerSubnet": "172.17.11",
"ambariServer": false,
"instanceIndex": 1,
"instanceId": "i-1bb92859",
"publicIp": "54.77.43.60",
"privateIp": "10.0.0.135"
},
{
"dockerSubnet": "172.17.12",
"ambariServer": false,
"instanceIndex": 2,
"instanceId": "i-1ab92858",
"publicIp": "54.77.43.61",
"privateIp": "10.0.0.137"
}
],
"cluster": {
"description": "",
"blueprintId": 50,
"cluster": {},
"minutesUp": 8,
"hoursUp": 0,
"status": "CREATE_COMPLETED",
"id": 2
},
"hash": "208d3dd389fad2221311792106cde53d",
"ambariServerIp": "54.77.43.59",
"nodeCount": 3,
"name": "awstest",
"templateId": 50,
"credentialId": 50,
"id": 50,
"cloudPlatform": "AWS",
"description": {
--AWS DESCRIPTION--
},
"status": "CREATE_COMPLETED"
}
## Delete cloud stacks [/stacks/{id}]
### Deletes the specified cloud stack [DELETE]
Deletes the specified stack from the (AWS or Azure) cloud
WARNING: All data will be lost - unless there was no storage configured. It is the user's responsibility to backup data or take snapshots using the cloud interface.
+ Parameters
+ id (required String `aws-cloud-id`) ... The identifier of the `stack`.
+ Request
+ Headers
x-auth-token: user:c45sdfdsfo234jgkhsdgf324
+ Response 200 (application/json)
{
}
## Retrieve a stack [/stacks/metadata/{hash}]
### Retrieve a particular stack metadata [GET]
Retrieves a (AWS or Azure) stack metadata.
+ Parameters
+ hash (required String `hash`) ... The identifier of the `metadata`.
+ Response 200 (application/json)
{
[
{
"dockerSubnet": "172.17.12",
"ambariServer": false,
"instanceIndex": 2,
"instanceId": "i-1ab92858",
"publicIp": "54.77.43.61",
"privateIp": "10.0.0.137"
},
{
"dockerSubnet": "172.17.10",
"ambariServer": true,
"instanceIndex": 0,
"instanceId": "i-fab627b8",
"publicIp": "54.77.43.59",
"privateIp": "10.0.0.136"
},
{
"dockerSubnet": "172.17.11",
"ambariServer": false,
"instanceIndex": 1,
"instanceId": "i-1bb92859",
"publicIp": "54.77.43.60",
"privateIp": "10.0.0.135"
}
]
}
# Group Clusters
Hadoop cluster related resources of the **Cloudbreak API**.
## Adding Hadoop clusters [/stacks/{stackId}/cluster]
### Create cluster [POST]
Creates a Hadoop cluster based on a blueprint.
+ Parameters
+ id (required String `id`) ... The identifier of the `stack`
+ Request
+ Headers
x-auth-token: user:c45sdfdsfo234jgkhsdgf324
+ Body
{
"clusterName": "my-cluster",
"blueprintId": "1",
"description": "My multinode cluster"
}
+ Response 200 (application/json)
{
}
## Retrieve Hadoop clusters [/stacks/{stackId}/cluster]
### Retrieve a particular cluster [GET]
Retrieves a particular cluster configuration for the user
+ Parameters
+ id (required String `id`) ... The identifier of the `stack`
+ Request
+ Headers
x-auth-token: user:c45sdfdsfo234jgkhsdgf324
+ Body
{
}
+ Response 200 (application/json)
{
{
"description": "",
"blueprintId": 50,
"cluster": {
"configurations": [
{
"Config": {
"cluster_name": "awstest"
},
"type": "capacity-scheduler",
"tag": "1",
"href": "http://54.77.43.59:8080/api/v1/clusters/awstest/configurations?type=capacity-scheduler&tag=1"
},
{
"Config": {
"cluster_name": "awstest"
},
"type": "core-site",
"tag": "1",
"href": "http://54.77.43.59:8080/api/v1/clusters/awstest/configurations?type=core-site&tag=1"
},
{
"Config": {
"cluster_name": "awstest"
},
"type": "global",
"tag": "1",
"href": "http://54.77.43.59:8080/api/v1/clusters/awstest/configurations?type=global&tag=1"
},
{
"Config": {
"cluster_name": "awstest"
},
"type": "hadoop-policy",
"tag": "1",
"href": "http://54.77.43.59:8080/api/v1/clusters/awstest/configurations?type=hadoop-policy&tag=1"
},
{
"Config": {
"cluster_name": "awstest"
},
"type": "hdfs-log4j",
"tag": "1",
"href": "http://54.77.43.59:8080/api/v1/clusters/awstest/configurations?type=hdfs-log4j&tag=1"
},
{