ClusterInstance

A Cluster Instance Resource defines attributes that are specific to a single instance in a Neptune Cluster.

You can simply add neptune instances and Neptune manages the replication. You can use the count meta-parameter to make multiple instances and join them all to the same Neptune Cluster, or you may specify different Cluster Instance resources with various instance_class sizes.

Example Usage

using System.Collections.Generic;
using Pulumi;
using Aws = Pulumi.Aws;

class MyStack : Stack
{
    public MyStack()
    {
        var @default = new Aws.Neptune.Cluster("default", new Aws.Neptune.ClusterArgs
        {
            ApplyImmediately = true,
            BackupRetentionPeriod = 5,
            ClusterIdentifier = "neptune-cluster-demo",
            Engine = "neptune",
            IamDatabaseAuthenticationEnabled = true,
            PreferredBackupWindow = "07:00-09:00",
            SkipFinalSnapshot = true,
        });
        var example = new List<Aws.Neptune.ClusterInstance>();
        for (var rangeIndex = 0; rangeIndex < 2; rangeIndex++)
        {
            var range = new { Value = rangeIndex };
            example.Add(new Aws.Neptune.ClusterInstance($"example-{range.Value}", new Aws.Neptune.ClusterInstanceArgs
            {
                ApplyImmediately = true,
                ClusterIdentifier = @default.Id,
                Engine = "neptune",
                InstanceClass = "db.r4.large",
            }));
        }
    }

}
package main

import (
    "github.com/pulumi/pulumi-aws/sdk/v2/go/aws/neptune"
    "github.com/pulumi/pulumi/sdk/v2/go/pulumi"
)

func main() {
    pulumi.Run(func(ctx *pulumi.Context) error {
        _, err := neptune.NewCluster(ctx, "_default", &neptune.ClusterArgs{
            ApplyImmediately:                 pulumi.Bool(true),
            BackupRetentionPeriod:            pulumi.Int(5),
            ClusterIdentifier:                pulumi.String("neptune-cluster-demo"),
            Engine:                           pulumi.String("neptune"),
            IamDatabaseAuthenticationEnabled: pulumi.Bool(true),
            PreferredBackupWindow:            pulumi.String("07:00-09:00"),
            SkipFinalSnapshot:                pulumi.Bool(true),
        })
        if err != nil {
            return err
        }
        var example []*neptune.ClusterInstance
        for key0, _ := range 2 {
            __res, err := neptune.NewClusterInstance(ctx, fmt.Sprintf("example-%v", key0), &neptune.ClusterInstanceArgs{
                ApplyImmediately:  pulumi.Bool(true),
                ClusterIdentifier: _default.ID(),
                Engine:            pulumi.String("neptune"),
                InstanceClass:     pulumi.String("db.r4.large"),
            })
            if err != nil {
                return err
            }
            example = append(example, __res)
        }
        return nil
    })
}
import pulumi
import pulumi_aws as aws

default = aws.neptune.Cluster("default",
    apply_immediately=True,
    backup_retention_period=5,
    cluster_identifier="neptune-cluster-demo",
    engine="neptune",
    iam_database_authentication_enabled=True,
    preferred_backup_window="07:00-09:00",
    skip_final_snapshot=True)
example = []
for range in [{"value": i} for i in range(0, 2)]:
    example.append(aws.neptune.ClusterInstance(f"example-{range['value']}",
        apply_immediately=True,
        cluster_identifier=default.id,
        engine="neptune",
        instance_class="db.r4.large"))
import * as pulumi from "@pulumi/pulumi";
import * as aws from "@pulumi/aws";

const defaultCluster = new aws.neptune.Cluster("default", {
    applyImmediately: true,
    backupRetentionPeriod: 5,
    clusterIdentifier: "neptune-cluster-demo",
    engine: "neptune",
    iamDatabaseAuthenticationEnabled: true,
    preferredBackupWindow: "07:00-09:00",
    skipFinalSnapshot: true,
});
const example: aws.neptune.ClusterInstance[] = [];
for (let i = 0; i < 2; i++) {
    example.push(new aws.neptune.ClusterInstance(`example-${i}`, {
        applyImmediately: true,
        clusterIdentifier: defaultCluster.id,
        engine: "neptune",
        instanceClass: "db.r4.large",
    }));
}

Create a ClusterInstance Resource

def ClusterInstance(resource_name, opts=None, apply_immediately=None, auto_minor_version_upgrade=None, availability_zone=None, cluster_identifier=None, engine=None, engine_version=None, identifier=None, identifier_prefix=None, instance_class=None, neptune_parameter_group_name=None, neptune_subnet_group_name=None, port=None, preferred_backup_window=None, preferred_maintenance_window=None, promotion_tier=None, publicly_accessible=None, tags=None, __props__=None);
name string
The unique name of the resource.
args ClusterInstanceArgs
The arguments to resource properties.
opts CustomResourceOptions
Bag of options to control resource's behavior.
resource_name str
The unique name of the resource.
opts ResourceOptions
A bag of options that control this resource's behavior.
ctx Context
Context object for the current deployment.
name string
The unique name of the resource.
args ClusterInstanceArgs
The arguments to resource properties.
opts ResourceOption
Bag of options to control resource's behavior.
name string
The unique name of the resource.
args ClusterInstanceArgs
The arguments to resource properties.
opts CustomResourceOptions
Bag of options to control resource's behavior.

ClusterInstance Resource Properties

To learn more about resource properties and how to use them, see Inputs and Outputs in the Programming Model docs.

Inputs

The ClusterInstance resource accepts the following input properties:

ClusterIdentifier string

The identifier of the aws.neptune.Cluster in which to launch this instance.

InstanceClass string

The instance class to use.

ApplyImmediately bool

Specifies whether any instance modifications are applied immediately, or during the next maintenance window. Default isfalse.

AutoMinorVersionUpgrade bool

Indicates that minor engine upgrades will be applied automatically to the instance during the maintenance window. Default is true.

AvailabilityZone string

The EC2 Availability Zone that the neptune instance is created in.

Engine string

The name of the database engine to be used for the neptune instance. Defaults to neptune. Valid Values: neptune.

EngineVersion string

The neptune engine version.

Identifier string

The indentifier for the neptune instance, if omitted, this provider will assign a random, unique identifier.

IdentifierPrefix string

Creates a unique identifier beginning with the specified prefix. Conflicts with identifier.

NeptuneParameterGroupName string

The name of the neptune parameter group to associate with this instance.

NeptuneSubnetGroupName string

A subnet group to associate with this neptune instance. NOTE: This must match the neptune_subnet_group_name of the attached aws.neptune.Cluster.

Port int

The port on which the DB accepts connections. Defaults to 8182.

PreferredBackupWindow string

The daily time range during which automated backups are created if automated backups are enabled. Eg: “04:00-09:00”

PreferredMaintenanceWindow string

The window to perform maintenance in. Syntax: “ddd:hh24:mi-ddd:hh24:mi”. Eg: “Mon:00:00-Mon:03:00”.

PromotionTier int

Default 0. Failover Priority setting on instance level. The reader who has lower tier has higher priority to get promoter to writer.

PubliclyAccessible bool

Bool to control if instance is publicly accessible. Default is false.

Tags Dictionary<string, string>

A map of tags to assign to the instance.

ClusterIdentifier string

The identifier of the aws.neptune.Cluster in which to launch this instance.

InstanceClass string

The instance class to use.

ApplyImmediately bool

Specifies whether any instance modifications are applied immediately, or during the next maintenance window. Default isfalse.

AutoMinorVersionUpgrade bool

Indicates that minor engine upgrades will be applied automatically to the instance during the maintenance window. Default is true.

AvailabilityZone string

The EC2 Availability Zone that the neptune instance is created in.

Engine string

The name of the database engine to be used for the neptune instance. Defaults to neptune. Valid Values: neptune.

EngineVersion string

The neptune engine version.

Identifier string

The indentifier for the neptune instance, if omitted, this provider will assign a random, unique identifier.

IdentifierPrefix string

Creates a unique identifier beginning with the specified prefix. Conflicts with identifier.

NeptuneParameterGroupName string

The name of the neptune parameter group to associate with this instance.

NeptuneSubnetGroupName string

A subnet group to associate with this neptune instance. NOTE: This must match the neptune_subnet_group_name of the attached aws.neptune.Cluster.

Port int

The port on which the DB accepts connections. Defaults to 8182.

PreferredBackupWindow string

The daily time range during which automated backups are created if automated backups are enabled. Eg: “04:00-09:00”

PreferredMaintenanceWindow string

The window to perform maintenance in. Syntax: “ddd:hh24:mi-ddd:hh24:mi”. Eg: “Mon:00:00-Mon:03:00”.

PromotionTier int

Default 0. Failover Priority setting on instance level. The reader who has lower tier has higher priority to get promoter to writer.

PubliclyAccessible bool

Bool to control if instance is publicly accessible. Default is false.

Tags map[string]string

A map of tags to assign to the instance.

clusterIdentifier string

The identifier of the aws.neptune.Cluster in which to launch this instance.

instanceClass string

The instance class to use.

applyImmediately boolean

Specifies whether any instance modifications are applied immediately, or during the next maintenance window. Default isfalse.

autoMinorVersionUpgrade boolean

Indicates that minor engine upgrades will be applied automatically to the instance during the maintenance window. Default is true.

availabilityZone string

The EC2 Availability Zone that the neptune instance is created in.

engine string

The name of the database engine to be used for the neptune instance. Defaults to neptune. Valid Values: neptune.

engineVersion string

The neptune engine version.

identifier string

The indentifier for the neptune instance, if omitted, this provider will assign a random, unique identifier.

identifierPrefix string

Creates a unique identifier beginning with the specified prefix. Conflicts with identifier.

neptuneParameterGroupName string

The name of the neptune parameter group to associate with this instance.

neptuneSubnetGroupName string

A subnet group to associate with this neptune instance. NOTE: This must match the neptune_subnet_group_name of the attached aws.neptune.Cluster.

port number

The port on which the DB accepts connections. Defaults to 8182.

preferredBackupWindow string

The daily time range during which automated backups are created if automated backups are enabled. Eg: “04:00-09:00”

preferredMaintenanceWindow string

The window to perform maintenance in. Syntax: “ddd:hh24:mi-ddd:hh24:mi”. Eg: “Mon:00:00-Mon:03:00”.

promotionTier number

Default 0. Failover Priority setting on instance level. The reader who has lower tier has higher priority to get promoter to writer.

publiclyAccessible boolean

Bool to control if instance is publicly accessible. Default is false.

tags {[key: string]: string}

A map of tags to assign to the instance.

cluster_identifier str

The identifier of the aws.neptune.Cluster in which to launch this instance.

instance_class str

The instance class to use.

apply_immediately bool

Specifies whether any instance modifications are applied immediately, or during the next maintenance window. Default isfalse.

auto_minor_version_upgrade bool

Indicates that minor engine upgrades will be applied automatically to the instance during the maintenance window. Default is true.

availability_zone str

The EC2 Availability Zone that the neptune instance is created in.

engine str

The name of the database engine to be used for the neptune instance. Defaults to neptune. Valid Values: neptune.

engine_version str

The neptune engine version.

identifier str

The indentifier for the neptune instance, if omitted, this provider will assign a random, unique identifier.

identifier_prefix str

Creates a unique identifier beginning with the specified prefix. Conflicts with identifier.

neptune_parameter_group_name str

The name of the neptune parameter group to associate with this instance.

neptune_subnet_group_name str

A subnet group to associate with this neptune instance. NOTE: This must match the neptune_subnet_group_name of the attached aws.neptune.Cluster.

port float

The port on which the DB accepts connections. Defaults to 8182.

preferred_backup_window str

The daily time range during which automated backups are created if automated backups are enabled. Eg: “04:00-09:00”

preferred_maintenance_window str

The window to perform maintenance in. Syntax: “ddd:hh24:mi-ddd:hh24:mi”. Eg: “Mon:00:00-Mon:03:00”.

promotion_tier float

Default 0. Failover Priority setting on instance level. The reader who has lower tier has higher priority to get promoter to writer.

publicly_accessible bool

Bool to control if instance is publicly accessible. Default is false.

tags Dict[str, str]

A map of tags to assign to the instance.

Outputs

All input properties are implicitly available as output properties. Additionally, the ClusterInstance resource produces the following output properties:

Address string

The hostname of the instance. See also endpoint and port.

Arn string

Amazon Resource Name (ARN) of neptune instance

DbiResourceId string

The region-unique, immutable identifier for the neptune instance.

Endpoint string

The connection endpoint in address:port format.

Id string
The provider-assigned unique ID for this managed resource.
KmsKeyArn string

The ARN for the KMS encryption key if one is set to the neptune cluster.

StorageEncrypted bool

Specifies whether the neptune cluster is encrypted.

Writer bool

Boolean indicating if this instance is writable. False indicates this instance is a read replica.

Address string

The hostname of the instance. See also endpoint and port.

Arn string

Amazon Resource Name (ARN) of neptune instance

DbiResourceId string

The region-unique, immutable identifier for the neptune instance.

Endpoint string

The connection endpoint in address:port format.

Id string
The provider-assigned unique ID for this managed resource.
KmsKeyArn string

The ARN for the KMS encryption key if one is set to the neptune cluster.

StorageEncrypted bool

Specifies whether the neptune cluster is encrypted.

Writer bool

Boolean indicating if this instance is writable. False indicates this instance is a read replica.

address string

The hostname of the instance. See also endpoint and port.

arn string

Amazon Resource Name (ARN) of neptune instance

dbiResourceId string

The region-unique, immutable identifier for the neptune instance.

endpoint string

The connection endpoint in address:port format.

id string
The provider-assigned unique ID for this managed resource.
kmsKeyArn string

The ARN for the KMS encryption key if one is set to the neptune cluster.

storageEncrypted boolean

Specifies whether the neptune cluster is encrypted.

writer boolean

Boolean indicating if this instance is writable. False indicates this instance is a read replica.

address str

The hostname of the instance. See also endpoint and port.

arn str

Amazon Resource Name (ARN) of neptune instance

dbi_resource_id str

The region-unique, immutable identifier for the neptune instance.

endpoint str

The connection endpoint in address:port format.

id str
The provider-assigned unique ID for this managed resource.
kms_key_arn str

The ARN for the KMS encryption key if one is set to the neptune cluster.

storage_encrypted bool

Specifies whether the neptune cluster is encrypted.

writer bool

Boolean indicating if this instance is writable. False indicates this instance is a read replica.

Look up an Existing ClusterInstance Resource

Get an existing ClusterInstance resource’s state with the given name, ID, and optional extra properties used to qualify the lookup.

public static get(name: string, id: Input<ID>, state?: ClusterInstanceState, opts?: CustomResourceOptions): ClusterInstance
static get(resource_name, id, opts=None, address=None, apply_immediately=None, arn=None, auto_minor_version_upgrade=None, availability_zone=None, cluster_identifier=None, dbi_resource_id=None, endpoint=None, engine=None, engine_version=None, identifier=None, identifier_prefix=None, instance_class=None, kms_key_arn=None, neptune_parameter_group_name=None, neptune_subnet_group_name=None, port=None, preferred_backup_window=None, preferred_maintenance_window=None, promotion_tier=None, publicly_accessible=None, storage_encrypted=None, tags=None, writer=None, __props__=None);
func GetClusterInstance(ctx *Context, name string, id IDInput, state *ClusterInstanceState, opts ...ResourceOption) (*ClusterInstance, error)
public static ClusterInstance Get(string name, Input<string> id, ClusterInstanceState? state, CustomResourceOptions? opts = null)
name
The unique name of the resulting resource.
id
The unique provider ID of the resource to lookup.
state
Any extra arguments used during the lookup.
opts
A bag of options that control this resource's behavior.
resource_name
The unique name of the resulting resource.
id
The unique provider ID of the resource to lookup.
name
The unique name of the resulting resource.
id
The unique provider ID of the resource to lookup.
state
Any extra arguments used during the lookup.
opts
A bag of options that control this resource's behavior.
name
The unique name of the resulting resource.
id
The unique provider ID of the resource to lookup.
state
Any extra arguments used during the lookup.
opts
A bag of options that control this resource's behavior.

The following state arguments are supported:

Address string

The hostname of the instance. See also endpoint and port.

ApplyImmediately bool

Specifies whether any instance modifications are applied immediately, or during the next maintenance window. Default isfalse.

Arn string

Amazon Resource Name (ARN) of neptune instance

AutoMinorVersionUpgrade bool

Indicates that minor engine upgrades will be applied automatically to the instance during the maintenance window. Default is true.

AvailabilityZone string

The EC2 Availability Zone that the neptune instance is created in.

ClusterIdentifier string

The identifier of the aws.neptune.Cluster in which to launch this instance.

DbiResourceId string

The region-unique, immutable identifier for the neptune instance.

Endpoint string

The connection endpoint in address:port format.

Engine string

The name of the database engine to be used for the neptune instance. Defaults to neptune. Valid Values: neptune.

EngineVersion string

The neptune engine version.

Identifier string

The indentifier for the neptune instance, if omitted, this provider will assign a random, unique identifier.

IdentifierPrefix string

Creates a unique identifier beginning with the specified prefix. Conflicts with identifier.

InstanceClass string

The instance class to use.

KmsKeyArn string

The ARN for the KMS encryption key if one is set to the neptune cluster.

NeptuneParameterGroupName string

The name of the neptune parameter group to associate with this instance.

NeptuneSubnetGroupName string

A subnet group to associate with this neptune instance. NOTE: This must match the neptune_subnet_group_name of the attached aws.neptune.Cluster.

Port int

The port on which the DB accepts connections. Defaults to 8182.

PreferredBackupWindow string

The daily time range during which automated backups are created if automated backups are enabled. Eg: “04:00-09:00”

PreferredMaintenanceWindow string

The window to perform maintenance in. Syntax: “ddd:hh24:mi-ddd:hh24:mi”. Eg: “Mon:00:00-Mon:03:00”.

PromotionTier int

Default 0. Failover Priority setting on instance level. The reader who has lower tier has higher priority to get promoter to writer.

PubliclyAccessible bool

Bool to control if instance is publicly accessible. Default is false.

StorageEncrypted bool

Specifies whether the neptune cluster is encrypted.

Tags Dictionary<string, string>

A map of tags to assign to the instance.

Writer bool

Boolean indicating if this instance is writable. False indicates this instance is a read replica.

Address string

The hostname of the instance. See also endpoint and port.

ApplyImmediately bool

Specifies whether any instance modifications are applied immediately, or during the next maintenance window. Default isfalse.

Arn string

Amazon Resource Name (ARN) of neptune instance

AutoMinorVersionUpgrade bool

Indicates that minor engine upgrades will be applied automatically to the instance during the maintenance window. Default is true.

AvailabilityZone string

The EC2 Availability Zone that the neptune instance is created in.

ClusterIdentifier string

The identifier of the aws.neptune.Cluster in which to launch this instance.

DbiResourceId string

The region-unique, immutable identifier for the neptune instance.

Endpoint string

The connection endpoint in address:port format.

Engine string

The name of the database engine to be used for the neptune instance. Defaults to neptune. Valid Values: neptune.

EngineVersion string

The neptune engine version.

Identifier string

The indentifier for the neptune instance, if omitted, this provider will assign a random, unique identifier.

IdentifierPrefix string

Creates a unique identifier beginning with the specified prefix. Conflicts with identifier.

InstanceClass string

The instance class to use.

KmsKeyArn string

The ARN for the KMS encryption key if one is set to the neptune cluster.

NeptuneParameterGroupName string

The name of the neptune parameter group to associate with this instance.

NeptuneSubnetGroupName string

A subnet group to associate with this neptune instance. NOTE: This must match the neptune_subnet_group_name of the attached aws.neptune.Cluster.

Port int

The port on which the DB accepts connections. Defaults to 8182.

PreferredBackupWindow string

The daily time range during which automated backups are created if automated backups are enabled. Eg: “04:00-09:00”

PreferredMaintenanceWindow string

The window to perform maintenance in. Syntax: “ddd:hh24:mi-ddd:hh24:mi”. Eg: “Mon:00:00-Mon:03:00”.

PromotionTier int

Default 0. Failover Priority setting on instance level. The reader who has lower tier has higher priority to get promoter to writer.

PubliclyAccessible bool

Bool to control if instance is publicly accessible. Default is false.

StorageEncrypted bool

Specifies whether the neptune cluster is encrypted.

Tags map[string]string

A map of tags to assign to the instance.

Writer bool

Boolean indicating if this instance is writable. False indicates this instance is a read replica.

address string

The hostname of the instance. See also endpoint and port.

applyImmediately boolean

Specifies whether any instance modifications are applied immediately, or during the next maintenance window. Default isfalse.

arn string

Amazon Resource Name (ARN) of neptune instance

autoMinorVersionUpgrade boolean

Indicates that minor engine upgrades will be applied automatically to the instance during the maintenance window. Default is true.

availabilityZone string

The EC2 Availability Zone that the neptune instance is created in.

clusterIdentifier string

The identifier of the aws.neptune.Cluster in which to launch this instance.

dbiResourceId string

The region-unique, immutable identifier for the neptune instance.

endpoint string

The connection endpoint in address:port format.

engine string

The name of the database engine to be used for the neptune instance. Defaults to neptune. Valid Values: neptune.

engineVersion string

The neptune engine version.

identifier string

The indentifier for the neptune instance, if omitted, this provider will assign a random, unique identifier.

identifierPrefix string

Creates a unique identifier beginning with the specified prefix. Conflicts with identifier.

instanceClass string

The instance class to use.

kmsKeyArn string

The ARN for the KMS encryption key if one is set to the neptune cluster.

neptuneParameterGroupName string

The name of the neptune parameter group to associate with this instance.

neptuneSubnetGroupName string

A subnet group to associate with this neptune instance. NOTE: This must match the neptune_subnet_group_name of the attached aws.neptune.Cluster.

port number

The port on which the DB accepts connections. Defaults to 8182.

preferredBackupWindow string

The daily time range during which automated backups are created if automated backups are enabled. Eg: “04:00-09:00”

preferredMaintenanceWindow string

The window to perform maintenance in. Syntax: “ddd:hh24:mi-ddd:hh24:mi”. Eg: “Mon:00:00-Mon:03:00”.

promotionTier number

Default 0. Failover Priority setting on instance level. The reader who has lower tier has higher priority to get promoter to writer.

publiclyAccessible boolean

Bool to control if instance is publicly accessible. Default is false.

storageEncrypted boolean

Specifies whether the neptune cluster is encrypted.

tags {[key: string]: string}

A map of tags to assign to the instance.

writer boolean

Boolean indicating if this instance is writable. False indicates this instance is a read replica.

address str

The hostname of the instance. See also endpoint and port.

apply_immediately bool

Specifies whether any instance modifications are applied immediately, or during the next maintenance window. Default isfalse.

arn str

Amazon Resource Name (ARN) of neptune instance

auto_minor_version_upgrade bool

Indicates that minor engine upgrades will be applied automatically to the instance during the maintenance window. Default is true.

availability_zone str

The EC2 Availability Zone that the neptune instance is created in.

cluster_identifier str

The identifier of the aws.neptune.Cluster in which to launch this instance.

dbi_resource_id str

The region-unique, immutable identifier for the neptune instance.

endpoint str

The connection endpoint in address:port format.

engine str

The name of the database engine to be used for the neptune instance. Defaults to neptune. Valid Values: neptune.

engine_version str

The neptune engine version.

identifier str

The indentifier for the neptune instance, if omitted, this provider will assign a random, unique identifier.

identifier_prefix str

Creates a unique identifier beginning with the specified prefix. Conflicts with identifier.

instance_class str

The instance class to use.

kms_key_arn str

The ARN for the KMS encryption key if one is set to the neptune cluster.

neptune_parameter_group_name str

The name of the neptune parameter group to associate with this instance.

neptune_subnet_group_name str

A subnet group to associate with this neptune instance. NOTE: This must match the neptune_subnet_group_name of the attached aws.neptune.Cluster.

port float

The port on which the DB accepts connections. Defaults to 8182.

preferred_backup_window str

The daily time range during which automated backups are created if automated backups are enabled. Eg: “04:00-09:00”

preferred_maintenance_window str

The window to perform maintenance in. Syntax: “ddd:hh24:mi-ddd:hh24:mi”. Eg: “Mon:00:00-Mon:03:00”.

promotion_tier float

Default 0. Failover Priority setting on instance level. The reader who has lower tier has higher priority to get promoter to writer.

publicly_accessible bool

Bool to control if instance is publicly accessible. Default is false.

storage_encrypted bool

Specifies whether the neptune cluster is encrypted.

tags Dict[str, str]

A map of tags to assign to the instance.

writer bool

Boolean indicating if this instance is writable. False indicates this instance is a read replica.

Package Details

Repository
https://github.com/pulumi/pulumi-aws
License
Apache-2.0
Notes
This Pulumi package is based on the aws Terraform Provider.