Interface IDatabaseInstance

All Superinterfaces:
IConnectable, IConstruct, software.constructs.IConstruct, IDependable, IResource, ISecretAttachmentTarget, software.amazon.jsii.JsiiSerializable
All Known Subinterfaces:
IDatabaseInstance.Jsii$Default
All Known Implementing Classes:
DatabaseInstance, DatabaseInstanceBase, DatabaseInstanceFromSnapshot, DatabaseInstanceReadReplica, IDatabaseInstance.Jsii$Proxy

@Generated(value="jsii-pacmak/1.84.0 (build 5404dcf)", date="2023-06-19T16:30:49.180Z") @Stability(Stable) public interface IDatabaseInstance extends software.amazon.jsii.JsiiSerializable, IResource, IConnectable, ISecretAttachmentTarget
A database instance.
  • Method Details

    • getDbInstanceEndpointAddress

      @Stability(Stable) @NotNull String getDbInstanceEndpointAddress()
      The instance endpoint address.
    • getDbInstanceEndpointPort

      @Stability(Stable) @NotNull String getDbInstanceEndpointPort()
      The instance endpoint port.
    • getInstanceArn

      @Stability(Stable) @NotNull String getInstanceArn()
      The instance arn.
    • getInstanceEndpoint

      @Stability(Stable) @NotNull Endpoint getInstanceEndpoint()
      The instance endpoint.
    • getInstanceIdentifier

      @Stability(Stable) @NotNull String getInstanceIdentifier()
      The instance identifier.
    • getEngine

      @Stability(Stable) @Nullable default IInstanceEngine getEngine()
      The engine of this database Instance.

      May be not known for imported Instances if it wasn't provided explicitly, or for read replicas.

    • addProxy

      @Stability(Stable) @NotNull DatabaseProxy addProxy(@NotNull String id, @NotNull DatabaseProxyOptions options)
      Add a new db proxy to this instance.

      Parameters:
      id - This parameter is required.
      options - This parameter is required.
    • grantConnect

      @Stability(Stable) @NotNull Grant grantConnect(@NotNull IGrantable grantee)
      Grant the given identity connection access to the database.

      Note: this method does not currently work, see https://github.com/aws/aws-cdk/issues/11851 for details.

      Parameters:
      grantee - This parameter is required.
      See Also:
    • metric

      @Stability(Stable) @NotNull Metric metric(@NotNull String metricName, @Nullable MetricOptions props)
      Return the given named metric for this DBInstance.

      Parameters:
      metricName - This parameter is required.
      props -
    • metric

      @Stability(Stable) @NotNull Metric metric(@NotNull String metricName)
      Return the given named metric for this DBInstance.

      Parameters:
      metricName - This parameter is required.
    • metricCPUUtilization

      @Stability(Stable) @NotNull Metric metricCPUUtilization(@Nullable MetricOptions props)
      The percentage of CPU utilization.

      Average over 5 minutes

      Parameters:
      props -
    • metricCPUUtilization

      @Stability(Stable) @NotNull Metric metricCPUUtilization()
      The percentage of CPU utilization.

      Average over 5 minutes

    • metricDatabaseConnections

      @Stability(Stable) @NotNull Metric metricDatabaseConnections(@Nullable MetricOptions props)
      The number of database connections in use.

      Average over 5 minutes

      Parameters:
      props -
    • metricDatabaseConnections

      @Stability(Stable) @NotNull Metric metricDatabaseConnections()
      The number of database connections in use.

      Average over 5 minutes

    • metricFreeableMemory

      @Stability(Stable) @NotNull Metric metricFreeableMemory(@Nullable MetricOptions props)
      The amount of available random access memory.

      Average over 5 minutes

      Parameters:
      props -
    • metricFreeableMemory

      @Stability(Stable) @NotNull Metric metricFreeableMemory()
      The amount of available random access memory.

      Average over 5 minutes

    • metricFreeStorageSpace

      @Stability(Stable) @NotNull Metric metricFreeStorageSpace(@Nullable MetricOptions props)
      The amount of available storage space.

      Average over 5 minutes

      Parameters:
      props -
    • metricFreeStorageSpace

      @Stability(Stable) @NotNull Metric metricFreeStorageSpace()
      The amount of available storage space.

      Average over 5 minutes

    • metricReadIOPS

      @Stability(Stable) @NotNull Metric metricReadIOPS(@Nullable MetricOptions props)
      The average number of disk write I/O operations per second.

      Average over 5 minutes

      Parameters:
      props -
    • metricReadIOPS

      @Stability(Stable) @NotNull Metric metricReadIOPS()
      The average number of disk write I/O operations per second.

      Average over 5 minutes

    • metricWriteIOPS

      @Stability(Stable) @NotNull Metric metricWriteIOPS(@Nullable MetricOptions props)
      The average number of disk read I/O operations per second.

      Average over 5 minutes

      Parameters:
      props -
    • metricWriteIOPS

      @Stability(Stable) @NotNull Metric metricWriteIOPS()
      The average number of disk read I/O operations per second.

      Average over 5 minutes

    • onEvent

      @Stability(Stable) @NotNull Rule onEvent(@NotNull String id, @Nullable OnEventOptions options)
      Defines a CloudWatch event rule which triggers for instance events.

      Use rule.addEventPattern(pattern) to specify a filter.

      Parameters:
      id - This parameter is required.
      options -
    • onEvent

      @Stability(Stable) @NotNull Rule onEvent(@NotNull String id)
      Defines a CloudWatch event rule which triggers for instance events.

      Use rule.addEventPattern(pattern) to specify a filter.

      Parameters:
      id - This parameter is required.