Skip to main content

db_instances

Creates, updates, deletes, gets or lists a db_instances resource.

Overview

Namedb_instances
TypeResource
Idaws.neptune.db_instances

Fields

The following fields are returned by SELECT queries:

NameDatatypeDescription
allocated_storageintegerNot supported by Neptune.
auto_minor_version_upgradebooleanIndicates that minor version patches are applied automatically.
availability_zonestringSpecifies the name of the Availability Zone the DB instance is located in.
backup_retention_periodintegerSpecifies the number of days for which automatic DB snapshots are retained.
ca_certificate_identifierstringThe identifier of the CA certificate for this DB instance.
character_set_namestring(Not supported by Neptune)
copy_tags_to_snapshotbooleanSpecifies whether tags are copied from the DB instance to snapshots of the DB instance.
db_cluster_identifierstringIf the DB instance is a member of a DB cluster, contains the name of the DB cluster that the DB instance is a member of.
db_instance_arnstringThe Amazon Resource Name (ARN) for the DB instance.
db_instance_classstringContains the name of the compute and memory capacity class of the DB instance.
db_instance_identifierstringContains a user-supplied database identifier. This identifier is the unique key that identifies a DB instance.
db_instance_statusstringSpecifies the current state of this database.
db_namestringThe database name.
db_parameter_groupsstringProvides the list of DB parameter groups applied to this DB instance.
db_security_groupsstringProvides List of DB security group elements containing only DBSecurityGroup.Name and DBSecurityGroup.Status subelements.
db_subnet_groupstringSpecifies information on the subnet group associated with the DB instance, including the name, description, and subnets in the subnet group.
db_instance_portintegerSpecifies the port that the DB instance listens on. If the DB instance is part of a DB cluster, this can be a different port than the DB cluster port.
dbi_resource_idstringThe Amazon Region-unique, immutable identifier for the DB instance. This identifier is found in Amazon CloudTrail log entries whenever the Amazon KMS key for the DB instance is accessed.
deletion_protectionbooleanIndicates whether or not the DB instance has deletion protection enabled. The instance can't be deleted when deletion protection is enabled. See Deleting a DB Instance.
domain_membershipsstringNot supported
enabled_cloudwatch_logs_exportsstringA list of log types that this DB instance is configured to export to CloudWatch Logs.
endpointstringSpecifies the connection endpoint.
enginestringProvides the name of the database engine to be used for this DB instance.
engine_versionstringIndicates the database engine version.
enhanced_monitoring_resource_arnstringThe Amazon Resource Name (ARN) of the Amazon CloudWatch Logs log stream that receives the Enhanced Monitoring metrics data for the DB instance.
iam_database_authentication_enabledbooleanTrue if Amazon Identity and Access Management (IAM) authentication is enabled, and otherwise false.
instance_create_timestringProvides the date and time the DB instance was created.
iopsintegerSpecifies the Provisioned IOPS (I/O operations per second) value.
kms_key_idstringNot supported: The encryption for DB instances is managed by the DB cluster.
latest_restorable_timestringSpecifies the latest time to which a database can be restored with point-in-time restore.
license_modelstringLicense model information for this DB instance.
master_usernamestringNot supported by Neptune.
monitoring_intervalintegerThe interval, in seconds, between points when Enhanced Monitoring metrics are collected for the DB instance.
monitoring_role_arnstringThe ARN for the IAM role that permits Neptune to send Enhanced Monitoring metrics to Amazon CloudWatch Logs.
multi_azbooleanSpecifies if the DB instance is a Multi-AZ deployment.
network_typestringThe network type of the DB instance. Inherited from the DB cluster. Valid Values: IPV4, DUAL
option_group_membershipsstring(Not supported by Neptune)
pending_modified_valuesstringSpecifies that changes to the DB instance are pending. This element is only included when changes are pending. Specific changes are identified by subelements.
performance_insights_enabledboolean(Not supported by Neptune)
performance_insights_kms_key_idstring(Not supported by Neptune)
preferred_backup_windowstringSpecifies the daily time range during which automated backups are created if automated backups are enabled, as determined by the BackupRetentionPeriod.
preferred_maintenance_windowstringSpecifies the weekly time range during which system maintenance can occur, in Universal Coordinated Time (UTC).
promotion_tierintegerA value that specifies the order in which a Read Replica is promoted to the primary instance after a failure of the existing primary instance.
publicly_accessiblebooleanIndicates whether the DB instance is publicly accessible. When the DB instance is publicly accessible and you connect from outside of the DB instance's virtual private cloud (VPC), its Domain Name System (DNS) endpoint resolves to the public IP address. When you connect from within the same VPC as the DB instance, the endpoint resolves to the private IP address. Access to the DB instance is ultimately controlled by the security group it uses. That public access isn't permitted if the security group assigned to the DB cluster doesn't permit it. When the DB instance isn't publicly accessible, it is an internal DB instance with a DNS name that resolves to a private IP address.
read_replica_db_cluster_identifiersstringContains one or more identifiers of DB clusters that are Read Replicas of this DB instance.
read_replica_db_instance_identifiersstringContains one or more identifiers of the Read Replicas associated with this DB instance.
read_replica_source_db_instance_identifierstringContains the identifier of the source DB instance if this DB instance is a Read Replica.
secondary_availability_zonestringIf present, specifies the name of the secondary Availability Zone for a DB instance with multi-AZ support.
status_infosstringThe status of a Read Replica. If the instance is not a Read Replica, this is blank.
storage_encryptedbooleanNot supported: The encryption for DB instances is managed by the DB cluster.
storage_typestringSpecifies the storage type associated with the DB instance.
tde_credential_arnstringThe ARN from the key store with which the instance is associated for TDE encryption.
timezonestringNot supported.
vpc_security_groupsstringProvides a list of VPC security group elements that the DB instance belongs to.

Methods

The following methods are available for this resource:

NameAccessible byRequired ParamsOptional ParamsDescription
describe_db_instancesselectregionDBInstanceIdentifier, Filters, MaxRecords, MarkerReturns information about provisioned instances, and supports pagination. This operation can also return information for Amazon RDS instances and Amazon DocDB instances.
create_db_instanceinsertDBInstanceIdentifier, DBInstanceClass, DBClusterIdentifier, regionDBName, AllocatedStorage, Engine, MasterUsername, MasterUserPassword, DBSecurityGroups, VpcSecurityGroupIds, AvailabilityZone, DBSubnetGroupName, PreferredMaintenanceWindow, DBParameterGroupName, BackupRetentionPeriod, PreferredBackupWindow, Port, MultiAZ, EngineVersion, AutoMinorVersionUpgrade, LicenseModel, Iops, OptionGroupName, CharacterSetName, PubliclyAccessible, Tags, StorageType, TdeCredentialArn, TdeCredentialPassword, StorageEncrypted, KmsKeyId, Domain, CopyTagsToSnapshot, MonitoringInterval, MonitoringRoleArn, DomainIAMRoleName, PromotionTier, Timezone, EnableIAMDatabaseAuthentication, EnablePerformanceInsights, PerformanceInsightsKMSKeyId, EnableCloudwatchLogsExports, DeletionProtectionCreates a new DB instance.
modify_db_instanceupdateDBInstanceIdentifier, regionAllocatedStorage, DBInstanceClass, DBSubnetGroupName, DBSecurityGroups, VpcSecurityGroupIds, ApplyImmediately, MasterUserPassword, DBParameterGroupName, BackupRetentionPeriod, PreferredBackupWindow, PreferredMaintenanceWindow, MultiAZ, EngineVersion, AllowMajorVersionUpgrade, AutoMinorVersionUpgrade, LicenseModel, Iops, OptionGroupName, NewDBInstanceIdentifier, StorageType, TdeCredentialArn, TdeCredentialPassword, CACertificateIdentifier, Domain, CopyTagsToSnapshot, MonitoringInterval, DBPortNumber, PubliclyAccessible, MonitoringRoleArn, DomainIAMRoleName, PromotionTier, EnableIAMDatabaseAuthentication, EnablePerformanceInsights, PerformanceInsightsKMSKeyId, CloudwatchLogsExportConfiguration, DeletionProtectionModifies settings for a DB instance. You can change one or more database configuration parameters by specifying these parameters and the new values in the request. To learn what modifications you can make to your DB instance, call DescribeValidDBInstanceModifications before you call ModifyDBInstance.
delete_db_instancedeleteDBInstanceIdentifier, regionSkipFinalSnapshot, FinalDBSnapshotIdentifierThe DeleteDBInstance action deletes a previously provisioned DB instance. When you delete a DB instance, all automated backups for that instance are deleted and can't be recovered. Manual DB snapshots of the DB instance to be deleted by DeleteDBInstance are not deleted. If you request a final DB snapshot the status of the Amazon Neptune DB instance is deleting until the DB snapshot is created. The API action DescribeDBInstance is used to monitor the status of this operation. The action can't be canceled or reverted once submitted. Note that when a DB instance is in a failure state and has a status of failed, incompatible-restore, or incompatible-network, you can only delete it when the SkipFinalSnapshot parameter is set to true. You can't delete a DB instance if it is the only instance in the DB cluster, or if it has deletion protection enabled.
reboot_db_instanceexecDBInstanceIdentifier, regionForceFailoverYou might need to reboot your DB instance, usually for maintenance reasons. For example, if you make certain modifications, or if you change the DB parameter group associated with the DB instance, you must reboot the instance for the changes to take effect. Rebooting a DB instance restarts the database engine service. Rebooting a DB instance results in a momentary outage, during which the DB instance status is set to rebooting.

Parameters

Parameters can be passed in the WHERE clause of a query. Check the Methods section to see which parameters are required or optional for each operation.

NameDatatypeDescription
DBClusterIdentifierstringThe identifier of the DB cluster that the instance will belong to. For information on creating a DB cluster, see CreateDBCluster. Type: String
DBInstanceClassstringThe compute and memory capacity of the DB instance, for example, db.m4.large. Not all DB instance classes are available in all Amazon Regions.
DBInstanceIdentifierstringThe DB instance identifier. This parameter is stored as a lowercase string. Constraints: Must match the identifier of an existing DBInstance.
regionstringAWS region (default: us-east-1)
AllocatedStorageintegerNot supported by Neptune.
AllowMajorVersionUpgradebooleanIndicates that major version upgrades are allowed. Changing this parameter doesn't result in an outage and the change is asynchronously applied as soon as possible.
ApplyImmediatelybooleanSpecifies whether the modifications in this request and any pending modifications are asynchronously applied as soon as possible, regardless of the PreferredMaintenanceWindow setting for the DB instance. If this parameter is set to false, changes to the DB instance are applied during the next maintenance window. Some parameter changes can cause an outage and are applied on the next call to RebootDBInstance, or the next failure reboot. Default: false
AutoMinorVersionUpgradebooleanIndicates that minor version upgrades are applied automatically to the DB instance during the maintenance window. Changing this parameter doesn't result in an outage except in the following case and the change is asynchronously applied as soon as possible. An outage will result if this parameter is set to true during the maintenance window, and a newer minor version is available, and Neptune has enabled auto patching for that engine version.
AvailabilityZonestringThe EC2 Availability Zone that the DB instance is created in Default: A random, system-chosen Availability Zone in the endpoint's Amazon Region. Example: us-east-1d Constraint: The AvailabilityZone parameter can't be specified if the MultiAZ parameter is set to true. The specified Availability Zone must be in the same Amazon Region as the current endpoint.
BackupRetentionPeriodintegerNot applicable. The retention period for automated backups is managed by the DB cluster. For more information, see ModifyDBCluster. Default: Uses existing setting
CACertificateIdentifierstringIndicates the certificate that needs to be associated with the instance.
CharacterSetNamestring(Not supported by Neptune)
CloudwatchLogsExportConfigurationobjectThe configuration setting for the log types to be enabled for export to CloudWatch Logs for a specific DB instance or DB cluster.
CopyTagsToSnapshotbooleanTrue to copy all tags from the DB instance to snapshots of the DB instance, and otherwise false. The default is false.
DBInstanceClassstringThe new compute and memory capacity of the DB instance, for example, db.m4.large. Not all DB instance classes are available in all Amazon Regions. If you modify the DB instance class, an outage occurs during the change. The change is applied during the next maintenance window, unless ApplyImmediately is specified as true for this request. Default: Uses existing setting
DBInstanceIdentifierstringThe user-supplied instance identifier. If this parameter is specified, information from only the specific DB instance is returned. This parameter isn't case-sensitive. Constraints: If supplied, must match the identifier of an existing DBInstance.
DBNamestringNot supported.
DBParameterGroupNamestringThe name of the DB parameter group to apply to the DB instance. Changing this setting doesn't result in an outage. The parameter group name itself is changed immediately, but the actual parameter changes are not applied until you reboot the instance without failover. The db instance will NOT be rebooted automatically and the parameter changes will NOT be applied during the next maintenance window. Default: Uses existing setting Constraints: The DB parameter group must be in the same DB parameter group family as this DB instance.
DBPortNumberintegerThe port number on which the database accepts connections. The value of the DBPortNumber parameter must not match any of the port values specified for options in the option group for the DB instance. Your database will restart when you change the DBPortNumber value regardless of the value of the ApplyImmediately parameter. Default: 8182
DBSecurityGroupsarrayA list of DB security groups to authorize on this DB instance. Changing this setting doesn't result in an outage and the change is asynchronously applied as soon as possible. Constraints: If supplied, must match existing DBSecurityGroups.
DBSubnetGroupNamestringThe new DB subnet group for the DB instance. You can use this parameter to move your DB instance to a different VPC. Changing the subnet group causes an outage during the change. The change is applied during the next maintenance window, unless you specify true for the ApplyImmediately parameter. Constraints: If supplied, must match the name of an existing DBSubnetGroup. Example: mySubnetGroup
DeletionProtectionbooleanA value that indicates whether the DB instance has deletion protection enabled. The database can't be deleted when deletion protection is enabled. By default, deletion protection is disabled. See Deleting a DB Instance.
DomainstringNot supported.
DomainIAMRoleNamestringNot supported
EnableCloudwatchLogsExportsarrayThe list of log types that need to be enabled for exporting to CloudWatch Logs.
EnableIAMDatabaseAuthenticationbooleanTrue to enable mapping of Amazon Identity and Access Management (IAM) accounts to database accounts, and otherwise false. You can enable IAM database authentication for the following database engines Not applicable. Mapping Amazon IAM accounts to database accounts is managed by the DB cluster. For more information, see ModifyDBCluster. Default: false
EnablePerformanceInsightsboolean(Not supported by Neptune)
EnginestringThe name of the database engine to be used for this instance. Valid Values: neptune
EngineVersionstringThe version number of the database engine to upgrade to. Currently, setting this parameter has no effect. To upgrade your database engine to the most recent release, use the ApplyPendingMaintenanceAction API.
FiltersarrayA filter that specifies one or more DB instances to describe. Supported filters: db-cluster-id - Accepts DB cluster identifiers and DB cluster Amazon Resource Names (ARNs). The results list will only include information about the DB instances associated with the DB clusters identified by these ARNs. engine - Accepts an engine name (such as neptune), and restricts the results list to DB instances created by that engine. For example, to invoke this API from the Amazon CLI and filter so that only Neptune DB instances are returned, you could use the following command:
FinalDBSnapshotIdentifierstringThe DBSnapshotIdentifier of the new DBSnapshot created when SkipFinalSnapshot is set to false. Specifying this parameter and also setting the SkipFinalSnapshot parameter to true results in an error. Constraints: Must be 1 to 255 letters or numbers. First character must be a letter Cannot end with a hyphen or contain two consecutive hyphens Cannot be specified when deleting a Read Replica.
ForceFailoverbooleanWhen true, the reboot is conducted through a MultiAZ failover. Constraint: You can't specify true if the instance is not configured for MultiAZ.
IopsintegerThe new Provisioned IOPS (I/O operations per second) value for the instance. Changing this setting doesn't result in an outage and the change is applied during the next maintenance window unless the ApplyImmediately parameter is set to true for this request. Default: Uses existing setting
KmsKeyIdstringThe Amazon KMS key identifier for an encrypted DB instance. The KMS key identifier is the Amazon Resource Name (ARN) for the KMS encryption key. If you are creating a DB instance with the same Amazon account that owns the KMS encryption key used to encrypt the new DB instance, then you can use the KMS key alias instead of the ARN for the KMS encryption key. Not applicable. The KMS key identifier is managed by the DB cluster. For more information, see CreateDBCluster. If the StorageEncrypted parameter is true, and you do not specify a value for the KmsKeyId parameter, then Amazon Neptune will use your default encryption key. Amazon KMS creates the default encryption key for your Amazon account. Your Amazon account has a different default encryption key for each Amazon Region.
LicenseModelstringNot supported by Neptune.
MarkerstringAn optional pagination token provided by a previous DescribeDBInstances request. If this parameter is specified, the response includes only records beyond the marker, up to the value specified by MaxRecords.
MasterUserPasswordstringNot supported by Neptune.
MasterUsernamestringNot supported by Neptune.
MaxRecordsintegerThe maximum number of records to include in the response. If more records exist than the specified MaxRecords value, a pagination token called a marker is included in the response so that the remaining results can be retrieved. Default: 100 Constraints: Minimum 20, maximum 100.
MonitoringIntervalintegerThe interval, in seconds, between points when Enhanced Monitoring metrics are collected for the DB instance. To disable collecting Enhanced Monitoring metrics, specify 0. The default is 0. If MonitoringRoleArn is specified, then you must also set MonitoringInterval to a value other than 0. Valid Values: 0, 1, 5, 10, 15, 30, 60
MonitoringRoleArnstringThe ARN for the IAM role that permits Neptune to send enhanced monitoring metrics to Amazon CloudWatch Logs. For example, arn:aws:iam:123456789012:role/emaccess. If MonitoringInterval is set to a value other than 0, then you must supply a MonitoringRoleArn value.
MultiAZbooleanSpecifies if the DB instance is a Multi-AZ deployment. Changing this parameter doesn't result in an outage and the change is applied during the next maintenance window unless the ApplyImmediately parameter is set to true for this request.
NewDBInstanceIdentifierstringThe new DB instance identifier for the DB instance when renaming a DB instance. When you change the DB instance identifier, an instance reboot will occur immediately if you set Apply Immediately to true, or will occur during the next maintenance window if Apply Immediately to false. This value is stored as a lowercase string. Constraints: Must contain from 1 to 63 letters, numbers, or hyphens. The first character must be a letter. Cannot end with a hyphen or contain two consecutive hyphens. Example: mydbinstance
OptionGroupNamestring(Not supported by Neptune)
PerformanceInsightsKMSKeyIdstring(Not supported by Neptune)
PortintegerThe port number on which the database accepts connections. Not applicable. The port is managed by the DB cluster. For more information, see CreateDBCluster. Default: 8182 Type: Integer
PreferredBackupWindowstringThe daily time range during which automated backups are created if automated backups are enabled. Not applicable. The daily time range for creating automated backups is managed by the DB cluster. For more information, see ModifyDBCluster. Constraints: Must be in the format hh24:mi-hh24:mi Must be in Universal Time Coordinated (UTC) Must not conflict with the preferred maintenance window Must be at least 30 minutes
PreferredMaintenanceWindowstringThe weekly time range (in UTC) during which system maintenance can occur, which might result in an outage. Changing this parameter doesn't result in an outage, except in the following situation, and the change is asynchronously applied as soon as possible. If there are pending actions that cause a reboot, and the maintenance window is changed to include the current time, then changing this parameter will cause a reboot of the DB instance. If moving this window to the current time, there must be at least 30 minutes between the current time and end of the window to ensure pending changes are applied. Default: Uses existing setting Format: ddd:hh24:mi-ddd:hh24:mi Valid Days: Mon | Tue | Wed | Thu | Fri | Sat | Sun Constraints: Must be at least 30 minutes
PromotionTierintegerA value that specifies the order in which a Read Replica is promoted to the primary instance after a failure of the existing primary instance. Default: 1 Valid Values: 0 - 15
PubliclyAccessiblebooleanIndicates whether the DB instance is publicly accessible. When the DB instance is publicly accessible and you connect from outside of the DB instance's virtual private cloud (VPC), its Domain Name System (DNS) endpoint resolves to the public IP address. When you connect from within the same VPC as the DB instance, the endpoint resolves to the private IP address. Access to the DB instance is ultimately controlled by the security group it uses. That public access isn't permitted if the security group assigned to the DB cluster doesn't permit it. When the DB instance isn't publicly accessible, it is an internal DB instance with a DNS name that resolves to a private IP address.
SkipFinalSnapshotbooleanDetermines whether a final DB snapshot is created before the DB instance is deleted. If true is specified, no DBSnapshot is created. If false is specified, a DB snapshot is created before the DB instance is deleted. Note that when a DB instance is in a failure state and has a status of 'failed', 'incompatible-restore', or 'incompatible-network', it can only be deleted when the SkipFinalSnapshot parameter is set to "true". Specify true when deleting a Read Replica. The FinalDBSnapshotIdentifier parameter must be specified if SkipFinalSnapshot is false. Default: false
StorageEncryptedbooleanSpecifies whether the DB instance is encrypted. Not applicable. The encryption for DB instances is managed by the DB cluster. For more information, see CreateDBCluster. Default: false
StorageTypestringNot applicable. In Neptune the storage type is managed at the DB Cluster level.
TagsarrayThe tags to assign to the new instance.
TdeCredentialArnstringThe ARN from the key store with which to associate the instance for TDE encryption.
TdeCredentialPasswordstringThe password for the given ARN from the key store in order to access the device.
TimezonestringThe time zone of the DB instance.
VpcSecurityGroupIdsarrayA list of EC2 VPC security groups to authorize on this DB instance. This change is asynchronously applied as soon as possible. Not applicable. The associated list of EC2 VPC security groups is managed by the DB cluster. For more information, see ModifyDBCluster. Constraints: If supplied, must match existing VpcSecurityGroupIds.

SELECT examples

Returns information about provisioned instances, and supports pagination. This operation can also return information for Amazon RDS instances and Amazon DocDB instances.

SELECT
allocated_storage,
auto_minor_version_upgrade,
availability_zone,
backup_retention_period,
ca_certificate_identifier,
character_set_name,
copy_tags_to_snapshot,
db_cluster_identifier,
db_instance_arn,
db_instance_class,
db_instance_identifier,
db_instance_status,
db_name,
db_parameter_groups,
db_security_groups,
db_subnet_group,
db_instance_port,
dbi_resource_id,
deletion_protection,
domain_memberships,
enabled_cloudwatch_logs_exports,
endpoint,
engine,
engine_version,
enhanced_monitoring_resource_arn,
iam_database_authentication_enabled,
instance_create_time,
iops,
kms_key_id,
latest_restorable_time,
license_model,
master_username,
monitoring_interval,
monitoring_role_arn,
multi_az,
network_type,
option_group_memberships,
pending_modified_values,
performance_insights_enabled,
performance_insights_kms_key_id,
preferred_backup_window,
preferred_maintenance_window,
promotion_tier,
publicly_accessible,
read_replica_db_cluster_identifiers,
read_replica_db_instance_identifiers,
read_replica_source_db_instance_identifier,
secondary_availability_zone,
status_infos,
storage_encrypted,
storage_type,
tde_credential_arn,
timezone,
vpc_security_groups
FROM aws.neptune.db_instances
WHERE region = '{{ region }}' -- required
AND DBInstanceIdentifier = '{{ DBInstanceIdentifier }}'
AND Filters = '{{ Filters }}'
AND MaxRecords = '{{ MaxRecords }}'
AND Marker = '{{ Marker }}'
;

INSERT examples

Creates a new DB instance.

INSERT INTO aws.neptune.db_instances (
DBInstanceIdentifier,
DBInstanceClass,
DBClusterIdentifier,
region,
DBName,
AllocatedStorage,
Engine,
MasterUsername,
MasterUserPassword,
DBSecurityGroups,
VpcSecurityGroupIds,
AvailabilityZone,
DBSubnetGroupName,
PreferredMaintenanceWindow,
DBParameterGroupName,
BackupRetentionPeriod,
PreferredBackupWindow,
Port,
MultiAZ,
EngineVersion,
AutoMinorVersionUpgrade,
LicenseModel,
Iops,
OptionGroupName,
CharacterSetName,
PubliclyAccessible,
Tags,
StorageType,
TdeCredentialArn,
TdeCredentialPassword,
StorageEncrypted,
KmsKeyId,
Domain,
CopyTagsToSnapshot,
MonitoringInterval,
MonitoringRoleArn,
DomainIAMRoleName,
PromotionTier,
Timezone,
EnableIAMDatabaseAuthentication,
EnablePerformanceInsights,
PerformanceInsightsKMSKeyId,
EnableCloudwatchLogsExports,
DeletionProtection
)
SELECT
'{{ DBInstanceIdentifier }}',
'{{ DBInstanceClass }}',
'{{ DBClusterIdentifier }}',
'{{ region }}',
'{{ DBName }}',
'{{ AllocatedStorage }}',
'{{ Engine }}',
'{{ MasterUsername }}',
'{{ MasterUserPassword }}',
'{{ DBSecurityGroups }}',
'{{ VpcSecurityGroupIds }}',
'{{ AvailabilityZone }}',
'{{ DBSubnetGroupName }}',
'{{ PreferredMaintenanceWindow }}',
'{{ DBParameterGroupName }}',
'{{ BackupRetentionPeriod }}',
'{{ PreferredBackupWindow }}',
'{{ Port }}',
'{{ MultiAZ }}',
'{{ EngineVersion }}',
'{{ AutoMinorVersionUpgrade }}',
'{{ LicenseModel }}',
'{{ Iops }}',
'{{ OptionGroupName }}',
'{{ CharacterSetName }}',
'{{ PubliclyAccessible }}',
'{{ Tags }}',
'{{ StorageType }}',
'{{ TdeCredentialArn }}',
'{{ TdeCredentialPassword }}',
'{{ StorageEncrypted }}',
'{{ KmsKeyId }}',
'{{ Domain }}',
'{{ CopyTagsToSnapshot }}',
'{{ MonitoringInterval }}',
'{{ MonitoringRoleArn }}',
'{{ DomainIAMRoleName }}',
'{{ PromotionTier }}',
'{{ Timezone }}',
'{{ EnableIAMDatabaseAuthentication }}',
'{{ EnablePerformanceInsights }}',
'{{ PerformanceInsightsKMSKeyId }}',
'{{ EnableCloudwatchLogsExports }}',
'{{ DeletionProtection }}'
RETURNING
allocated_storage,
auto_minor_version_upgrade,
availability_zone,
backup_retention_period,
ca_certificate_identifier,
character_set_name,
copy_tags_to_snapshot,
db_cluster_identifier,
db_instance_arn,
db_instance_class,
db_instance_identifier,
db_instance_status,
db_name,
db_parameter_groups,
db_security_groups,
db_subnet_group,
db_instance_port,
dbi_resource_id,
deletion_protection,
domain_memberships,
enabled_cloudwatch_logs_exports,
endpoint,
engine,
engine_version,
enhanced_monitoring_resource_arn,
iam_database_authentication_enabled,
instance_create_time,
iops,
kms_key_id,
latest_restorable_time,
license_model,
master_username,
monitoring_interval,
monitoring_role_arn,
multi_az,
network_type,
option_group_memberships,
pending_modified_values,
performance_insights_enabled,
performance_insights_kms_key_id,
preferred_backup_window,
preferred_maintenance_window,
promotion_tier,
publicly_accessible,
read_replica_db_cluster_identifiers,
read_replica_db_instance_identifiers,
read_replica_source_db_instance_identifier,
secondary_availability_zone,
status_infos,
storage_encrypted,
storage_type,
tde_credential_arn,
timezone,
vpc_security_groups
;

UPDATE examples

Modifies settings for a DB instance. You can change one or more database configuration parameters by specifying these parameters and the new values in the request. To learn what modifications you can make to your DB instance, call DescribeValidDBInstanceModifications before you call ModifyDBInstance.

UPDATE aws.neptune.db_instances
SET
-- No updatable properties
WHERE
DBInstanceIdentifier = '{{ DBInstanceIdentifier }}' --required
AND region = '{{ region }}' --required
AND AllocatedStorage = '{{ AllocatedStorage}}'
AND DBInstanceClass = '{{ DBInstanceClass}}'
AND DBSubnetGroupName = '{{ DBSubnetGroupName}}'
AND DBSecurityGroups = '{{ DBSecurityGroups}}'
AND VpcSecurityGroupIds = '{{ VpcSecurityGroupIds}}'
AND ApplyImmediately = {{ ApplyImmediately}}
AND MasterUserPassword = '{{ MasterUserPassword}}'
AND DBParameterGroupName = '{{ DBParameterGroupName}}'
AND BackupRetentionPeriod = '{{ BackupRetentionPeriod}}'
AND PreferredBackupWindow = '{{ PreferredBackupWindow}}'
AND PreferredMaintenanceWindow = '{{ PreferredMaintenanceWindow}}'
AND MultiAZ = {{ MultiAZ}}
AND EngineVersion = '{{ EngineVersion}}'
AND AllowMajorVersionUpgrade = {{ AllowMajorVersionUpgrade}}
AND AutoMinorVersionUpgrade = {{ AutoMinorVersionUpgrade}}
AND LicenseModel = '{{ LicenseModel}}'
AND Iops = '{{ Iops}}'
AND OptionGroupName = '{{ OptionGroupName}}'
AND NewDBInstanceIdentifier = '{{ NewDBInstanceIdentifier}}'
AND StorageType = '{{ StorageType}}'
AND TdeCredentialArn = '{{ TdeCredentialArn}}'
AND TdeCredentialPassword = '{{ TdeCredentialPassword}}'
AND CACertificateIdentifier = '{{ CACertificateIdentifier}}'
AND Domain = '{{ Domain}}'
AND CopyTagsToSnapshot = {{ CopyTagsToSnapshot}}
AND MonitoringInterval = '{{ MonitoringInterval}}'
AND DBPortNumber = '{{ DBPortNumber}}'
AND PubliclyAccessible = {{ PubliclyAccessible}}
AND MonitoringRoleArn = '{{ MonitoringRoleArn}}'
AND DomainIAMRoleName = '{{ DomainIAMRoleName}}'
AND PromotionTier = '{{ PromotionTier}}'
AND EnableIAMDatabaseAuthentication = {{ EnableIAMDatabaseAuthentication}}
AND EnablePerformanceInsights = {{ EnablePerformanceInsights}}
AND PerformanceInsightsKMSKeyId = '{{ PerformanceInsightsKMSKeyId}}'
AND CloudwatchLogsExportConfiguration = '{{ CloudwatchLogsExportConfiguration}}'
AND DeletionProtection = {{ DeletionProtection}}
RETURNING
allocated_storage,
auto_minor_version_upgrade,
availability_zone,
backup_retention_period,
ca_certificate_identifier,
character_set_name,
copy_tags_to_snapshot,
db_cluster_identifier,
db_instance_arn,
db_instance_class,
db_instance_identifier,
db_instance_status,
db_name,
db_parameter_groups,
db_security_groups,
db_subnet_group,
db_instance_port,
dbi_resource_id,
deletion_protection,
domain_memberships,
enabled_cloudwatch_logs_exports,
endpoint,
engine,
engine_version,
enhanced_monitoring_resource_arn,
iam_database_authentication_enabled,
instance_create_time,
iops,
kms_key_id,
latest_restorable_time,
license_model,
master_username,
monitoring_interval,
monitoring_role_arn,
multi_az,
network_type,
option_group_memberships,
pending_modified_values,
performance_insights_enabled,
performance_insights_kms_key_id,
preferred_backup_window,
preferred_maintenance_window,
promotion_tier,
publicly_accessible,
read_replica_db_cluster_identifiers,
read_replica_db_instance_identifiers,
read_replica_source_db_instance_identifier,
secondary_availability_zone,
status_infos,
storage_encrypted,
storage_type,
tde_credential_arn,
timezone,
vpc_security_groups;

DELETE examples

The DeleteDBInstance action deletes a previously provisioned DB instance. When you delete a DB instance, all automated backups for that instance are deleted and can't be recovered. Manual DB snapshots of the DB instance to be deleted by DeleteDBInstance are not deleted. If you request a final DB snapshot the status of the Amazon Neptune DB instance is deleting until the DB snapshot is created. The API action DescribeDBInstance is used to monitor the status of this operation. The action can't be canceled or reverted once submitted. Note that when a DB instance is in a failure state and has a status of failed, incompatible-restore, or incompatible-network, you can only delete it when the SkipFinalSnapshot parameter is set to true. You can't delete a DB instance if it is the only instance in the DB cluster, or if it has deletion protection enabled.

DELETE FROM aws.neptune.db_instances
WHERE DBInstanceIdentifier = '{{ DBInstanceIdentifier }}' --required
AND region = '{{ region }}' --required
AND SkipFinalSnapshot = '{{ SkipFinalSnapshot }}'
AND FinalDBSnapshotIdentifier = '{{ FinalDBSnapshotIdentifier }}'
;

Lifecycle Methods

You might need to reboot your DB instance, usually for maintenance reasons. For example, if you make certain modifications, or if you change the DB parameter group associated with the DB instance, you must reboot the instance for the changes to take effect. Rebooting a DB instance restarts the database engine service. Rebooting a DB instance results in a momentary outage, during which the DB instance status is set to rebooting.

EXEC aws.neptune.db_instances.reboot_db_instance
@DBInstanceIdentifier='{{ DBInstanceIdentifier }}' --required,
@region='{{ region }}' --required,
@ForceFailover={{ ForceFailover }}
;