@RestController
@RequestMapping(value="/rest",
produces={"application/xml","application/json"})
public class EmrRestController
extends HerdBaseController
| Constructor and Description |
|---|
EmrRestController() |
| Modifier and Type | Method and Description |
|---|---|
EmrMasterSecurityGroup |
addGroupsToEmrClusterMaster(EmrMasterSecurityGroupAddRequest request)
Adds security groups to the master node of an existing cluster
|
EmrHadoopJarStep |
addHadoopJarStepToEmrCluster(EmrHadoopJarStepAddRequest request)
Adds a Hadoop Jar step to the existing cluster
|
EmrHiveStep |
addHiveStepToEmrCluster(EmrHiveStepAddRequest request)
Adds a hive step to the existing cluster
|
EmrPigStep |
addPigStepToEmrCluster(EmrPigStepAddRequest request)
Adds a Pig step to the existing cluster
|
EmrShellStep |
addShellStepToEmrCluster(EmrShellStepAddRequest request)
Adds a shell step to the existing cluster
|
EmrCluster |
createEmrCluster(EmrClusterCreateRequest request)
Creates a new EMR cluster.
|
EmrCluster |
getEmrCluster(String namespace,
String emrClusterDefinitionName,
String emrClusterName,
String emrClusterId,
String emrStepId,
Boolean verbose,
String accountId,
Boolean retrieveInstanceFleets)
Gets an existing EMR cluster details.
|
EmrCluster |
terminateEmrCluster(String namespace,
String emrClusterDefinitionName,
String emrClusterName,
Boolean overrideTerminationProtection,
String emrClusterId,
String accountId)
Terminates an existing EMR cluster.
|
addPagingHttpHeaders, validateNoDuplicateQueryStringParams@RequestMapping(value="/emrMasterSecurityGroups",
method=POST,
consumes={"application/xml","application/json"})
@Secured(value="FN_EMR_MASTER_SECURITY_GROUPS_POST")
public EmrMasterSecurityGroup addGroupsToEmrClusterMaster(@RequestBody
EmrMasterSecurityGroupAddRequest request)
throws Exception
Requires WRITE permission on namespace
request - the information needed to add security groups to master node of the EMR cluster.Exception@RequestMapping(value="/emrHadoopJarSteps",
method=POST,
consumes={"application/xml","application/json"})
@Secured(value="FN_EMR_HADOOP_JAR_STEPS_POST")
public EmrHadoopJarStep addHadoopJarStepToEmrCluster(@RequestBody
EmrHadoopJarStepAddRequest request)
throws Exception
Requires EXECUTE permission on namespace
request - the information needed to add Hadoop Jar step to the EMR cluster.Exception@RequestMapping(value="/emrHiveSteps",
method=POST,
consumes={"application/xml","application/json"})
@Secured(value="FN_EMR_HIVE_STEPS_POST")
public EmrHiveStep addHiveStepToEmrCluster(@RequestBody
EmrHiveStepAddRequest request)
throws Exception
Requires EXECUTE permission on namespace
request - the information needed to add hive step to the EMR cluster.Exception@RequestMapping(value="/emrPigSteps",
method=POST,
consumes={"application/xml","application/json"})
@Secured(value="FN_EMR_PIG_STEPS_POST")
public EmrPigStep addPigStepToEmrCluster(@RequestBody
EmrPigStepAddRequest request)
throws Exception
Requires EXECUTE permission on namespace
request - the information needed to add Pig step to the EMR cluster.Exception@RequestMapping(value="/emrShellSteps",
method=POST,
consumes={"application/xml","application/json"})
@Secured(value="FN_EMR_SHELL_STEPS_POST")
public EmrShellStep addShellStepToEmrCluster(@RequestBody
EmrShellStepAddRequest request)
throws Exception
Requires EXECUTE permission on namespace
request - the information needed to add shell step to the EMR cluster.Exception - if a shell step couldn't be added to the EMR cluster.@RequestMapping(value="/emrClusters",
method=POST,
consumes={"application/xml","application/json"})
@Secured(value="FN_EMR_CLUSTERS_POST")
public EmrCluster createEmrCluster(@RequestBody
EmrClusterCreateRequest request)
throws Exception
Requires EXECUTE permission on namespace
request - the information needed to create the EMR cluster.Exception@RequestMapping(value="/emrClusters/namespaces/{namespace}/emrClusterDefinitionNames/{emrClusterDefinitionName}/emrClusterNames/{emrClusterName}",
method=GET)
@Secured(value="FN_EMR_CLUSTERS_GET")
public EmrCluster getEmrCluster(@PathVariable(value="namespace")
String namespace,
@PathVariable(value="emrClusterDefinitionName")
String emrClusterDefinitionName,
@PathVariable(value="emrClusterName")
String emrClusterName,
@RequestParam(value="emrClusterId",required=false)
String emrClusterId,
@RequestParam(value="emrStepId",required=false)
String emrStepId,
@RequestParam(value="verbose",required=false,defaultValue="false")
Boolean verbose,
@RequestParam(value="accountId",required=false)
String accountId,
@RequestParam(value="retrieveInstanceFleets",required=false,defaultValue="false")
Boolean retrieveInstanceFleets)
throws Exception
Requires READ permission on namespace
namespace - the namespaceemrClusterDefinitionName - the EMR cluster definition nameemrClusterName - the EMR cluster nameemrClusterId - the cluster id of the cluster to get detailsemrStepId - the step id of the step to get detailsverbose - parameter for whether to return detailed informationaccountId - the account IdretrieveInstanceFleets - parameter for whether to retrieve instance fleetsException - if there was an error getting the EMR cluster.@RequestMapping(value="/emrClusters/namespaces/{namespace}/emrClusterDefinitionNames/{emrClusterDefinitionName}/emrClusterNames/{emrClusterName}",
method=DELETE)
@Secured(value="FN_EMR_CLUSTERS_DELETE")
public EmrCluster terminateEmrCluster(@PathVariable(value="namespace")
String namespace,
@PathVariable(value="emrClusterDefinitionName")
String emrClusterDefinitionName,
@PathVariable(value="emrClusterName")
String emrClusterName,
@RequestParam(value="overrideTerminationProtection",required=false,defaultValue="false")
Boolean overrideTerminationProtection,
@RequestParam(value="emrClusterId",required=false)
String emrClusterId,
@RequestParam(value="accountId",required=false)
String accountId)
throws Exception
Requires EXECUTE permission on namespace
namespace - the namespaceemrClusterDefinitionName - the EMR cluster definition nameemrClusterName - the EMR cluster nameoverrideTerminationProtection - parameter for whether to override termination protectionemrClusterId - EMR cluster IDaccountId - account IdException - if there was an error terminating the EMR cluster.Copyright © 2019. All rights reserved.