Class RelationalDatabase

java.lang.Object
software.amazon.awssdk.services.lightsail.model.RelationalDatabase
All Implemented Interfaces:
Serializable, SdkPojo, ToCopyableBuilder<RelationalDatabase.Builder,RelationalDatabase>

@Generated("software.amazon.awssdk:codegen") public final class RelationalDatabase extends Object implements SdkPojo, Serializable, ToCopyableBuilder<RelationalDatabase.Builder,RelationalDatabase>

Describes a database.

See Also:
  • Method Details

    • name

      public final String name()

      The unique name of the database resource in Lightsail.

      Returns:
      The unique name of the database resource in Lightsail.
    • arn

      public final String arn()

      The Amazon Resource Name (ARN) of the database.

      Returns:
      The Amazon Resource Name (ARN) of the database.
    • supportCode

      public final String supportCode()

      The support code for the database. Include this code in your email to support when you have questions about a database in Lightsail. This code enables our support team to look up your Lightsail information more easily.

      Returns:
      The support code for the database. Include this code in your email to support when you have questions about a database in Lightsail. This code enables our support team to look up your Lightsail information more easily.
    • createdAt

      public final Instant createdAt()

      The timestamp when the database was created. Formatted in Unix time.

      Returns:
      The timestamp when the database was created. Formatted in Unix time.
    • location

      public final ResourceLocation location()

      The Region name and Availability Zone where the database is located.

      Returns:
      The Region name and Availability Zone where the database is located.
    • resourceType

      public final ResourceType resourceType()

      The Lightsail resource type for the database (for example, RelationalDatabase).

      If the service returns an enum value that is not available in the current SDK version, resourceType will return ResourceType.UNKNOWN_TO_SDK_VERSION. The raw value returned by the service is available from resourceTypeAsString().

      Returns:
      The Lightsail resource type for the database (for example, RelationalDatabase).
      See Also:
    • resourceTypeAsString

      public final String resourceTypeAsString()

      The Lightsail resource type for the database (for example, RelationalDatabase).

      If the service returns an enum value that is not available in the current SDK version, resourceType will return ResourceType.UNKNOWN_TO_SDK_VERSION. The raw value returned by the service is available from resourceTypeAsString().

      Returns:
      The Lightsail resource type for the database (for example, RelationalDatabase).
      See Also:
    • hasTags

      public final boolean hasTags()
      For responses, this returns true if the service returned a value for the Tags property. This DOES NOT check that the value is non-empty (for which, you should check the isEmpty() method on the property). This is useful because the SDK will never return a null collection or map, but you may need to differentiate between the service returning nothing (or null) and the service returning an empty collection or map. For requests, this returns true if a value for the property was specified in the request builder, and false if a value was not specified.
    • tags

      public final List<Tag> tags()

      The tag keys and optional values for the resource. For more information about tags in Lightsail, see the Amazon Lightsail Developer Guide.

      Attempts to modify the collection returned by this method will result in an UnsupportedOperationException.

      This method will never return null. If you would like to know whether the service returned this field (so that you can differentiate between null and empty), you can use the hasTags() method.

      Returns:
      The tag keys and optional values for the resource. For more information about tags in Lightsail, see the Amazon Lightsail Developer Guide.
    • relationalDatabaseBlueprintId

      public final String relationalDatabaseBlueprintId()

      The blueprint ID for the database. A blueprint describes the major engine version of a database.

      Returns:
      The blueprint ID for the database. A blueprint describes the major engine version of a database.
    • relationalDatabaseBundleId

      public final String relationalDatabaseBundleId()

      The bundle ID for the database. A bundle describes the performance specifications for your database.

      Returns:
      The bundle ID for the database. A bundle describes the performance specifications for your database.
    • masterDatabaseName

      public final String masterDatabaseName()

      The name of the master database created when the Lightsail database resource is created.

      Returns:
      The name of the master database created when the Lightsail database resource is created.
    • hardware

      public final RelationalDatabaseHardware hardware()

      Describes the hardware of the database.

      Returns:
      Describes the hardware of the database.
    • state

      public final String state()

      Describes the current state of the database.

      Returns:
      Describes the current state of the database.
    • secondaryAvailabilityZone

      public final String secondaryAvailabilityZone()

      Describes the secondary Availability Zone of a high availability database.

      The secondary database is used for failover support of a high availability database.

      Returns:
      Describes the secondary Availability Zone of a high availability database.

      The secondary database is used for failover support of a high availability database.

    • backupRetentionEnabled

      public final Boolean backupRetentionEnabled()

      A Boolean value indicating whether automated backup retention is enabled for the database.

      Returns:
      A Boolean value indicating whether automated backup retention is enabled for the database.
    • pendingModifiedValues

      public final PendingModifiedRelationalDatabaseValues pendingModifiedValues()

      Describes pending database value modifications.

      Returns:
      Describes pending database value modifications.
    • engine

      public final String engine()

      The database software (for example, MySQL).

      Returns:
      The database software (for example, MySQL).
    • engineVersion

      public final String engineVersion()

      The database engine version (for example, 5.7.23).

      Returns:
      The database engine version (for example, 5.7.23).
    • latestRestorableTime

      public final Instant latestRestorableTime()

      The latest point in time to which the database can be restored. Formatted in Unix time.

      Returns:
      The latest point in time to which the database can be restored. Formatted in Unix time.
    • masterUsername

      public final String masterUsername()

      The master user name of the database.

      Returns:
      The master user name of the database.
    • parameterApplyStatus

      public final String parameterApplyStatus()

      The status of parameter updates for the database.

      Returns:
      The status of parameter updates for the database.
    • preferredBackupWindow

      public final String preferredBackupWindow()

      The daily time range during which automated backups are created for the database (for example, 16:00-16:30).

      Returns:
      The daily time range during which automated backups are created for the database (for example, 16:00-16:30).
    • preferredMaintenanceWindow

      public final String preferredMaintenanceWindow()

      The weekly time range during which system maintenance can occur on the database.

      In the format ddd:hh24:mi-ddd:hh24:mi. For example, Tue:17:00-Tue:17:30.

      Returns:
      The weekly time range during which system maintenance can occur on the database.

      In the format ddd:hh24:mi-ddd:hh24:mi. For example, Tue:17:00-Tue:17:30.

    • publiclyAccessible

      public final Boolean publiclyAccessible()

      A Boolean value indicating whether the database is publicly accessible.

      Returns:
      A Boolean value indicating whether the database is publicly accessible.
    • masterEndpoint

      public final RelationalDatabaseEndpoint masterEndpoint()

      The master endpoint for the database.

      Returns:
      The master endpoint for the database.
    • hasPendingMaintenanceActions

      public final boolean hasPendingMaintenanceActions()
      For responses, this returns true if the service returned a value for the PendingMaintenanceActions property. This DOES NOT check that the value is non-empty (for which, you should check the isEmpty() method on the property). This is useful because the SDK will never return a null collection or map, but you may need to differentiate between the service returning nothing (or null) and the service returning an empty collection or map. For requests, this returns true if a value for the property was specified in the request builder, and false if a value was not specified.
    • pendingMaintenanceActions

      public final List<PendingMaintenanceAction> pendingMaintenanceActions()

      Describes the pending maintenance actions for the database.

      Attempts to modify the collection returned by this method will result in an UnsupportedOperationException.

      This method will never return null. If you would like to know whether the service returned this field (so that you can differentiate between null and empty), you can use the hasPendingMaintenanceActions() method.

      Returns:
      Describes the pending maintenance actions for the database.
    • caCertificateIdentifier

      public final String caCertificateIdentifier()

      The certificate associated with the database.

      Returns:
      The certificate associated with the database.
    • toBuilder

      public RelationalDatabase.Builder toBuilder()
      Description copied from interface: ToCopyableBuilder
      Take this object and create a builder that contains all of the current property values of this object.
      Specified by:
      toBuilder in interface ToCopyableBuilder<RelationalDatabase.Builder,RelationalDatabase>
      Returns:
      a builder for type T
    • builder

      public static RelationalDatabase.Builder builder()
    • serializableBuilderClass

      public static Class<? extends RelationalDatabase.Builder> serializableBuilderClass()
    • hashCode

      public final int hashCode()
      Overrides:
      hashCode in class Object
    • equals

      public final boolean equals(Object obj)
      Overrides:
      equals in class Object
    • equalsBySdkFields

      public final boolean equalsBySdkFields(Object obj)
      Description copied from interface: SdkPojo
      Indicates whether some other object is "equal to" this one by SDK fields. An SDK field is a modeled, non-inherited field in an SdkPojo class, and is generated based on a service model.

      If an SdkPojo class does not have any inherited fields, equalsBySdkFields and equals are essentially the same.

      Specified by:
      equalsBySdkFields in interface SdkPojo
      Parameters:
      obj - the object to be compared with
      Returns:
      true if the other object equals to this object by sdk fields, false otherwise.
    • toString

      public final String toString()
      Returns a string representation of this object. This is useful for testing and debugging. Sensitive data will be redacted from this string using a placeholder value.
      Overrides:
      toString in class Object
    • getValueForField

      public final <T> Optional<T> getValueForField(String fieldName, Class<T> clazz)
    • sdkFields

      public final List<SdkField<?>> sdkFields()
      Specified by:
      sdkFields in interface SdkPojo
      Returns:
      List of SdkField in this POJO. May be empty list but should never be null.