Skip to content

QueueProps

Properties for defining a Queue.

See https://www.alibabacloud.com/help/ros/developer-reference/aliyun-amqp-queue

Initializer

import com.aliyun.ros.cdk.amqp.QueueProps;
QueueProps.builder()
    .instanceId(java.lang.String)
    .instanceId(IResolvable)
    .queueName(java.lang.String)
    .queueName(IResolvable)
    .virtualHost(java.lang.String)
    .virtualHost(IResolvable)
//  .autoDeleteState(java.lang.Boolean)
//  .autoDeleteState(IResolvable)
//  .autoExpireState(java.lang.Number)
//  .autoExpireState(IResolvable)
//  .deadLetterExchange(java.lang.String)
//  .deadLetterExchange(IResolvable)
//  .deadLetterRoutingKey(java.lang.String)
//  .deadLetterRoutingKey(IResolvable)
//  .exclusiveState(java.lang.Boolean)
//  .exclusiveState(IResolvable)
//  .maximumPriority(java.lang.Number)
//  .maximumPriority(IResolvable)
//  .maxLength(java.lang.Number)
//  .maxLength(IResolvable)
//  .messageTtl(java.lang.Number)
//  .messageTtl(IResolvable)
    .build();

Properties

Name Type Description
instanceId java.lang.String OR com.aliyun.ros.cdk.core.IResolvable Property instanceId: InstanceId.
queueName java.lang.String OR com.aliyun.ros.cdk.core.IResolvable Property queueName: The name of the queue to create.
virtualHost java.lang.String OR com.aliyun.ros.cdk.core.IResolvable Property virtualHost: The name of the vhost to which the queue belongs.
autoDeleteState java.lang.Boolean OR com.aliyun.ros.cdk.core.IResolvable Property autoDeleteState: Specifies whether the Auto Delete attribute is configured.
autoExpireState java.lang.Number OR com.aliyun.ros.cdk.core.IResolvable Property autoExpireState: The auto-expiration time for the queue.
deadLetterExchange java.lang.String OR com.aliyun.ros.cdk.core.IResolvable Property deadLetterExchange: The dead-letter exchange.
deadLetterRoutingKey java.lang.String OR com.aliyun.ros.cdk.core.IResolvable Property deadLetterRoutingKey: The dead-letter routing key.
exclusiveState java.lang.Boolean OR com.aliyun.ros.cdk.core.IResolvable Property exclusiveState: Specifies whether the queue is an exclusive queue.
maximumPriority java.lang.Number OR com.aliyun.ros.cdk.core.IResolvable Property maximumPriority: The priority of the queue.
maxLength java.lang.Number OR com.aliyun.ros.cdk.core.IResolvable Property maxLength: This parameter is not supported in the current version.
messageTtl java.lang.Number OR com.aliyun.ros.cdk.core.IResolvable Property messageTtl: The message TTL of the queue If a message is retained in the Queue longer than the configured message lifetime, the message expires.

instanceIdRequired

public java.lang.Object getInstanceId();
  • Type: java.lang.String OR com.aliyun.ros.cdk.core.IResolvable

Property instanceId: InstanceId.


queueNameRequired

public java.lang.Object getQueueName();
  • Type: java.lang.String OR com.aliyun.ros.cdk.core.IResolvable

Property queueName: The name of the queue to create.

  • The queue name can contain only letters, digits, hyphens (-), underscores (_), periods (.), number signs (#), forward slashes (/), and at signs (@). The name must be 1 to 255 characters in length.
  • After a queue is created, its name cannot be changed. To change the name, delete the queue and create a new one.

virtualHostRequired

public java.lang.Object getVirtualHost();
  • Type: java.lang.String OR com.aliyun.ros.cdk.core.IResolvable

Property virtualHost: The name of the vhost to which the queue belongs.

The name can contain only letters, digits, hyphens (-), underscores (_), periods (.), number signs (#), forward slashes (/), and at signs (@). The name must be 1 to 255 characters in length.


autoDeleteStateOptional

public java.lang.Object getAutoDeleteState();
  • Type: java.lang.Boolean OR com.aliyun.ros.cdk.core.IResolvable

Property autoDeleteState: Specifies whether the Auto Delete attribute is configured.

Valid values: true: The Auto Delete attribute is configured. The queue is automatically deleted after the last subscription from consumers to this queue is canceled. false: The Auto Delete attribute is not configured.


autoExpireStateOptional

public java.lang.Object getAutoExpireState();
  • Type: java.lang.Number OR com.aliyun.ros.cdk.core.IResolvable

Property autoExpireState: The auto-expiration time for the queue.

The queue is automatically deleted if it is not accessed within the specified time period. Unit: milliseconds.

This feature must be enabled before you can use this parameter. To enable the feature, .


deadLetterExchangeOptional

public java.lang.Object getDeadLetterExchange();
  • Type: java.lang.String OR com.aliyun.ros.cdk.core.IResolvable

Property deadLetterExchange: The dead-letter exchange.

A dead-letter exchange is used to receive rejected messages. If a consumer rejects a message that cannot be retried, this message is routed to a specified dead-letter exchange. Then, the dead-letter exchange routes the message to the queue that is bound to the dead-letter exchange.


deadLetterRoutingKeyOptional

public java.lang.Object getDeadLetterRoutingKey();
  • Type: java.lang.String OR com.aliyun.ros.cdk.core.IResolvable

Property deadLetterRoutingKey: The dead-letter routing key.

The key can contain only letters, digits, hyphens (-), underscores (_), periods (.), number signs (#), forward slashes (/), and at signs (@). The key must be 1 to 255 characters in length.


exclusiveStateOptional

public java.lang.Object getExclusiveState();
  • Type: java.lang.Boolean OR com.aliyun.ros.cdk.core.IResolvable

Property exclusiveState: Specifies whether the queue is an exclusive queue.

Valid values:

  • true: The queue is an exclusive queue. An exclusive queue can be used only by the connection that declares it. The queue is automatically deleted after the connection is closed.
  • false: The queue is not an exclusive queue.

maximumPriorityOptional

public java.lang.Object getMaximumPriority();
  • Type: java.lang.Number OR com.aliyun.ros.cdk.core.IResolvable

Property maximumPriority: The priority of the queue.

The recommended value is an integer from 1 to 10.

This parameter is used for message priority. It is supported only by dedicated instances and can be used only after the message priority feature is enabled. To enable the feature, .


maxLengthOptional

public java.lang.Object getMaxLength();
  • Type: java.lang.Number OR com.aliyun.ros.cdk.core.IResolvable

Property maxLength: This parameter is not supported in the current version.

The maximum number of messages that can be stored in the queue. If this limit is exceeded, the earliest messages in the queue are deleted.


messageTtlOptional

public java.lang.Object getMessageTtl();
  • Type: java.lang.Number OR com.aliyun.ros.cdk.core.IResolvable

Property messageTtl: The message TTL of the queue If a message is retained in the Queue longer than the configured message lifetime, the message expires.

The value of message lifetime must be a non-negative integer, up to 1 day. The unit is milliseconds