Enum QueueEncryption

java.lang.Object
java.lang.Enum<QueueEncryption>
software.amazon.awscdk.services.sqs.QueueEncryption
All Implemented Interfaces:
Serializable, Comparable<QueueEncryption>, java.lang.constant.Constable

@Generated(value="jsii-pacmak/1.97.0 (build 729de35)", date="2024-04-24T21:00:37.760Z") @Stability(Stable) public enum QueueEncryption extends Enum<QueueEncryption>
What kind of encryption to apply to this queue.

Example:

 // Use managed key
 // Use managed key
 Queue.Builder.create(this, "Queue")
         .encryption(QueueEncryption.KMS_MANAGED)
         .build();
 // Use custom key
 Key myKey = new Key(this, "Key");
 Queue.Builder.create(this, "Queue")
         .encryption(QueueEncryption.KMS)
         .encryptionMasterKey(myKey)
         .build();
 // Use SQS managed server side encryption (SSE-SQS)
 // Use SQS managed server side encryption (SSE-SQS)
 Queue.Builder.create(this, "Queue")
         .encryption(QueueEncryption.SQS_MANAGED)
         .build();
 // Unencrypted queue
 // Unencrypted queue
 Queue.Builder.create(this, "Queue")
         .encryption(QueueEncryption.UNENCRYPTED)
         .build();
 
  • Enum Constant Details

    • UNENCRYPTED

      @Stability(Stable) public static final QueueEncryption UNENCRYPTED
      Messages in the queue are not encrypted.
    • KMS_MANAGED

      @Stability(Stable) public static final QueueEncryption KMS_MANAGED
      Server-side KMS encryption with a KMS key managed by SQS.
    • KMS

      @Stability(Stable) public static final QueueEncryption KMS
      Server-side encryption with a KMS key managed by the user.

      If encryptionKey is specified, this key will be used, otherwise, one will be defined.

    • SQS_MANAGED

      @Stability(Stable) public static final QueueEncryption SQS_MANAGED
      Server-side encryption key managed by SQS (SSE-SQS).

      To learn more about SSE-SQS on Amazon SQS, please visit the Amazon SQS documentation.

  • Method Details

    • values

      public static QueueEncryption[] values()
      Returns an array containing the constants of this enum type, in the order they are declared.
      Returns:
      an array containing the constants of this enum type, in the order they are declared
    • valueOf

      public static QueueEncryption valueOf(String name)
      Returns the enum constant of this type with the specified name. The string must match exactly an identifier used to declare an enum constant in this type. (Extraneous whitespace characters are not permitted.)
      Parameters:
      name - the name of the enum constant to be returned.
      Returns:
      the enum constant with the specified name
      Throws:
      IllegalArgumentException - if this enum type has no constant with the specified name
      NullPointerException - if the argument is null