# Databricks::Clusters::Cluster An example resource schema demonstrating some basic constructs and validation rules. ## Syntax To declare this entity in your AWS CloudFormation template, use the following syntax: ### JSON
{ "Type" : "Databricks::Clusters::Cluster", "Properties" : { "NumWorkers" : Integer, "Autoscale" : Autoscale, "ClusterName" : String, "SparkVersion" : String, "SparkConf" : Map, "AwsAttributes" : AwsAttributes, "NodeTypeId" : String, "DriverNodeTypeId" : String, "SshPublicKeys" : [ String, ... ], "CustomTags" : Map, "ClusterLogConf" : ClusterLogConf, "InitScripts" : [ InitScriptsListItem, ... ], "DockerImage" : DockerImage, "SparkEnvVars" : Map, "AutoterminationMinutes" : Integer, "EnableElasticDisk" : Boolean, "DriverInstancePoolId" : String, "InstancePoolId" : String, "IdempotencyToken" : String, "ApplyPolicyDefaultValues" : Boolean, "EnableLocalDiskEncryption" : Boolean, "RuntimeEngine" : String, } }### YAML
Type: Databricks::Clusters::Cluster Properties: NumWorkers: Integer Autoscale: Autoscale ClusterName: String SparkVersion: String SparkConf: Map AwsAttributes: AwsAttributes NodeTypeId: String DriverNodeTypeId: String SshPublicKeys: - String CustomTags: Map ClusterLogConf: ClusterLogConf InitScripts: - InitScriptsListItem DockerImage: DockerImage SparkEnvVars: Map AutoterminationMinutes: Integer EnableElasticDisk: Boolean DriverInstancePoolId: String InstancePoolId: String IdempotencyToken: String ApplyPolicyDefaultValues: Boolean EnableLocalDiskEncryption: Boolean RuntimeEngine: String## Properties #### NumWorkers If num_workers, number of worker nodes that this cluster should have. A cluster has one Spark driver and num_workers executors for a total of num_workers + 1 Spark nodes. _Required_: No _Type_: Integer _Update requires_: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt) #### Autoscale Range defining the min and max number of cluster workers _Required_: No _Type_: Autoscale _Update requires_: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt) #### ClusterName Cluster name requested by the user. This doesn't have to be unique. If not specified at creation, the cluster name will be an empty string. _Required_: No _Type_: String _Update requires_: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt) #### SparkVersion The runtime version of the cluster. You can retrieve a list of available runtime versions by using the Runtime versions API call. This field is required. _Required_: No _Type_: String _Update requires_: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt) #### SparkConf An object containing a set of optional, user-specified Spark configuration key-value pairs. You can also pass in a string of extra JVM options to the driver and the executors via spark.driver.extraJavaOptions and spark.executor.extraJavaOptions respectively. Example Spark confs: {"spark.speculation": true, "spark.streaming.ui.retainedBatches": 5} or {"spark.driver.extraJavaOptions": "-verbose:gc -XX:+PrintGCDetails"} _Required_: No _Type_: Map _Update requires_: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt) #### AwsAttributes Attributes set during cluster creation related to Amazon Web Services. _Required_: No _Type_: AwsAttributes _Update requires_: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt) #### NodeTypeId This field encodes, through a single value, the resources available to each of the Spark nodes in this cluster. For example, the Spark nodes can be provisioned and optimized for memory or compute intensive workloads A list of available node types can be retrieved by using the List node types API call. This field is required. _Required_: No _Type_: String _Update requires_: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt) #### DriverNodeTypeId The node type of the Spark driver. This field is optional; if unset, the driver node type will be set as the same value as node_type_id defined above. _Required_: No _Type_: String _Update requires_: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt) #### SshPublicKeys SSH public key contents that will be added to each Spark node in this cluster. The corresponding private keys can be used to login with the user name ubuntu on port 2200. Up to 10 keys can be specified. _Required_: No _Type_: List of String _Update requires_: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt) #### CustomTags An object containing a set of tags for cluster resources. Databricks tags all cluster resources (such as AWS instances and EBS volumes) with these tags in addition to default_tags. _Required_: No _Type_: Map _Update requires_: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt) #### ClusterLogConf Path to cluster log. _Required_: No _Type_: ClusterLogConf _Update requires_: [No interruption](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/using-cfn-updating-stacks-update-behaviors.html#update-no-interrupt) #### InitScripts The configuration for storing init scripts. Any number of destinations can be specified. The scripts are executed sequentially in the order provided. If cluster_log_conf is specified, init script logs are sent to
LastStateLossTime
value.
#### LastActivityTime
Returns the LastActivityTime
value.
#### LastRestartedTime
Returns the LastRestartedTime
value.
#### ClusterMemoryMb
Returns the ClusterMemoryMb
value.
#### ClusterCores
Returns the ClusterCores
value.