ALIYUN::ESA::WaitingRoom

ALIYUN::ESA::WaitingRoom类型用于创建等候室。

语法

{
  "Type": "ALIYUN::ESA::WaitingRoom",
  "Properties": {
    "CookieName": String,
    "HostNameAndPath": List,
    "NewUsersPerMinute": Integer,
    "QueuingStatusCode": Integer,
    "QueuingMethod": String,
    "Status": String,
    "SiteId": Integer,
    "SessionDuration": Integer,
    "TotalActiveUsers": String,
    "WaitingRoomType": String,
    "WaitingRoomName": String,
    "CustomPageHtml": String,
    "Description": String,
    "DisableSessionRenewalEnable": String,
    "JsonResponseEnable": String,
    "Language": String,
    "QueueAllEnable": String
  }
}

属性

属性名称

类型

必须

允许更新

描述

约束

CookieName

String

自定义 Cookie 名称。

HostNameAndPath

List

主机名和路径。

更多信息,请参考HostNameAndPath属性

NewUsersPerMinute

Integer

每分钟新用户数。

QueuingStatusCode

Integer

等候室状态码。

取值:

  • 200

  • 202

  • 429

QueuingMethod

String

排队方式。

取值:

  • random:随机。

  • fifo:先进先出。

  • passthrough:直通。

  • reject-all:拒绝全部。

Status

String

等候室启用状态。

取值:

  • on:开启。

  • off:关闭。

SiteId

Integer

站点 ID。

SessionDuration

Integer

会话持续时间。

单位是分钟。

TotalActiveUsers

String

活跃用户总数。

WaitingRoomType

String

等候室类型。

支持以下类型:

  • default:默认类型。

  • custom:自定义类型。

WaitingRoomName

String

等候室名称。

CustomPageHtml

String

用户自定义等候室页面内容,

当等候室类型为自定义类型时,需要传入。传入的内容需要经过 base64 编码。

Description

String

等候室描述。

DisableSessionRenewalEnable

String

禁用会话续订。

取值:

  • on:开启。

  • off:关闭。

JsonResponseEnable

String

JSON 响应。

开启后 accept 请求头包含"application/json"会返回 JSON 数据。取值:

  • on:开启。

  • off:关闭。

Language

String

等候室页面的语言。

当等候室类型为默认类型时,需要传入。支持以下类型:

  • enus:英文。

  • zhcn:中文简体。

  • zhhk:中文繁体。

QueueAllEnable

String

全部排队。

取值:

  • on:开启。

  • off:关闭。

HostNameAndPath语法

"HostNameAndPath": [
  {
    "Path": String,
    "Subdomain": String,
    "Domain": String
  }
]

HostNameAndPath属性

属性名称

类型

必须

允许更新

描述

约束

Domain

String

域名。

Path

String

路径。

Subdomain

String

子域名。

返回值

Fn::GetAtt

  • HostNameAndPath:主机名和路径。

  • JsonResponseEnable:JSON 响应。

  • Description:等候室描述。

  • WaitingRoomType:等候室类型。

  • DisableSessionRenewalEnable:禁用会话续订。

  • CookieName:自定义 Cookie 名称。

  • WaitingRoomName:等候室名称。

  • CustomPageHtml:用户自定义等候室页面内容

  • QueueAllEnable:全部排队。

  • QueuingStatusCode:等候室状态码。

  • NewUsersPerMinute:每分钟新用户数。

  • SessionDuration:会话持续时间

  • Language:等候室页面的语言

  • TotalActiveUsers:活跃用户总数。

  • WaitingRoomId:等候室 ID。

  • QueuingMethod:排队方式。

示例

ROSTemplateFormatVersion: '2015-09-01'
Parameters:
  Status:
    Type: String
    Description:
      en: |-
        Waiting room enabled status. Value:
        - 'on': Enable waiting room
        - 'off': Disabled waiting room
    AllowedValues:
      - 'on'
      - 'off'
    Required: true
  HostNameAndPath:
    AssociationPropertyMetadata:
      Parameters:
        Path:
          Type: String
          Description:
            en: The path.
          Required: true
        Subdomain:
          Type: String
          Description:
            en: The subdomain.
          Required: true
        Domain:
          Type: String
          Description:
            en: The domain name.
          Required: true
    AssociationProperty: List[Parameters]
    Type: Json
    Description:
      en: The hostname and path.
    Required: true
  SiteId:
    Type: Number
    Description:
      en: The site ID.
    Required: true
  WaitingRoomType:
    Type: String
    Description:
      en: |-
        The type of the waiting room, support:
        - `default`: Indicates the default type.
        - `custom`: indicates a custom type.
    AllowedValues:
      - default
      - custom
    Required: true
  CookieName:
    Type: String
    Description:
      en: The name of the custom cookie.
    Required: true
  WaitingRoomName:
    Type: String
    Description:
      en: The name of the waiting room.
    Required: true
  QueuingStatusCode:
    Type: Number
    Description:
      en: |-
        Waiting room status code. Value:
        - `200`
        - `202`
        - `429`.
    AllowedValues:
      - 200
      - 202
      - 429
    Required: true
  NewUsersPerMinute:
    Type: Number
    Description:
      en: The maximum number of new users per minute.
    Required: true
    MinValue: 200
  SessionDuration:
    Type: Number
    Description:
      en: 'The maximum duration for which a session remains valid after a user leaves the origin. Unit: minutes.'
    Required: true
    MinValue: 1
  Language:
    Type: String
    Description:
      en: |-
        The language of the waiting room page. When the waiting room type is the default type, it needs to be passed in. The following types are supported:
        - `enus`: English.
        - `zhcn`: Simplified Chinese.
        - `zhhk`: Traditional Chinese.
    AllowedValues:
      - enus
      - zhcn
      - zhhk
    Required: false
  QueuingMethod:
    Type: String
    Description:
      en: |-
        The queuing method. Value:
        - `random`: Users gain access to the origin randomly, regardless of the arrival time.
        - `fifo`: Users gain access to the origin in order of arrival.
        - `Passthrough`: Users pass through the waiting room and go straight to the origin.
        - `Reject-all`: Users are blocked from reaching the origin.
    AllowedValues:
      - random
      - fifo
      - Passthrough
      - Reject-all
    Required: true
Resources:
  ExtensionResource:
    Type: ALIYUN::ESA::WaitingRoom
    Properties:
      Status:
        Ref: Status
      HostNameAndPath:
        Ref: HostNameAndPath
      SiteId:
        Ref: SiteId
      WaitingRoomType:
        Ref: WaitingRoomType
      CookieName:
        Ref: CookieName
      QueueAllEnable:
        Ref: QueueAllEnable
      WaitingRoomName:
        Ref: WaitingRoomName
      QueuingStatusCode:
        Ref: QueuingStatusCode
      NewUsersPerMinute:
        Ref: NewUsersPerMinute
      SessionDuration:
        Ref: SessionDuration
      Language:
        Ref: Language
      QueuingMethod:
        Ref: QueuingMethod
Outputs:
  HostNameAndPath:
    Description: Host name and path.
    Value:
      Fn::GetAtt:
        - ExtensionResource
        - HostNameAndPath
  JsonResponseEnable:
    Description: The JSON response. If the accept request header contains "application/json", JSON data is returned.
    Value:
      Fn::GetAtt:
        - ExtensionResource
        - JsonResponseEnable
  Description:
    Description: Waiting room description.
    Value:
      Fn::GetAtt:
        - ExtensionResource
        - Description
  WaitingRoomType:
    Description: Waiting room type, support:.
    Value:
      Fn::GetAtt:
        - ExtensionResource
        - WaitingRoomType
  DisableSessionRenewalEnable:
    Description: Disable session renewal.
    Value:
      Fn::GetAtt:
        - ExtensionResource
        - DisableSessionRenewalEnable
  CookieName:
    Description: Custom Cookie name.
    Value:
      Fn::GetAtt:
        - ExtensionResource
        - CookieName
  WaitingRoomName:
    Description: The name of the waiting room.
    Value:
      Fn::GetAtt:
        - ExtensionResource
        - WaitingRoomName
  CustomPageHtml:
    Description: User-defined waiting room page content, when the waiting room type is custom type, you need to enter. The incoming content needs to be base64 encoded.
    Value:
      Fn::GetAtt:
        - ExtensionResource
        - CustomPageHtml
  QueueAllEnable:
    Description: All in line.
    Value:
      Fn::GetAtt:
        - ExtensionResource
        - QueueAllEnable
  QueuingStatusCode:
    Description: Waiting room status code.
    Value:
      Fn::GetAtt:
        - ExtensionResource
        - QueuingStatusCode
  NewUsersPerMinute:
    Description: Number of new users per minute.
    Value:
      Fn::GetAtt:
        - ExtensionResource
        - NewUsersPerMinute
  SessionDuration:
    Description: Session duration in minutes.
    Value:
      Fn::GetAtt:
        - ExtensionResource
        - SessionDuration
  Language:
    Description: The language of the waiting room page. When the waiting room type is the default type, it needs to be passed in.
    Value:
      Fn::GetAtt:
        - ExtensionResource
        - Language
  TotalActiveUsers:
    Description: Total number of active users.
    Value:
      Fn::GetAtt:
        - ExtensionResource
        - TotalActiveUsers
  WaitingRoomId:
    Description: The waiting room ID.
    Value:
      Fn::GetAtt:
        - ExtensionResource
        - WaitingRoomId
  QueuingMethod:
    Description: Way of queuing.
    Value:
      Fn::GetAtt:
        - ExtensionResource
        - QueuingMethod
{
  "ROSTemplateFormatVersion": "2015-09-01",
  "Parameters": {
    "Status": {
      "Type": "String",
      "Description": {
        "en": "Waiting room enabled status. Value:\n- 'on': Enable waiting room\n- 'off': Disabled waiting room"
      },
      "AllowedValues": [
        "on",
        "off"
      ],
      "Required": true
    },
    "HostNameAndPath": {
      "AssociationPropertyMetadata": {
        "Parameters": {
          "Path": {
            "Type": "String",
            "Description": {
              "en": "The path."
            },
            "Required": true
          },
          "Subdomain": {
            "Type": "String",
            "Description": {
              "en": "The subdomain."
            },
            "Required": true
          },
          "Domain": {
            "Type": "String",
            "Description": {
              "en": "The domain name."
            },
            "Required": true
          }
        }
      },
      "AssociationProperty": "List[Parameters]",
      "Type": "Json",
      "Description": {
        "en": "The hostname and path."
      },
      "Required": true
    },
    "SiteId": {
      "Type": "Number",
      "Description": {
        "en": "The site ID."
      },
      "Required": true
    },
    "WaitingRoomType": {
      "Type": "String",
      "Description": {
        "en": "The type of the waiting room, support:\n- `default`: Indicates the default type.\n- `custom`: indicates a custom type."
      },
      "AllowedValues": [
        "default",
        "custom"
      ],
      "Required": true
    },
    "CookieName": {
      "Type": "String",
      "Description": {
        "en": "The name of the custom cookie."
      },
      "Required": true
    },
    "WaitingRoomName": {
      "Type": "String",
      "Description": {
        "en": "The name of the waiting room."
      },
      "Required": true
    },
    "QueuingStatusCode": {
      "Type": "Number",
      "Description": {
        "en": "Waiting room status code. Value:\n- `200`\n- `202`\n- `429`."
      },
      "AllowedValues": [
        200,
        202,
        429
      ],
      "Required": true
    },
    "NewUsersPerMinute": {
      "Type": "Number",
      "Description": {
        "en": "The maximum number of new users per minute."
      },
      "Required": true,
      "MinValue": 200
    },
    "SessionDuration": {
      "Type": "Number",
      "Description": {
        "en": "The maximum duration for which a session remains valid after a user leaves the origin. Unit: minutes."
      },
      "Required": true,
      "MinValue": 1
    },
    "Language": {
      "Type": "String",
      "Description": {
        "en": "The language of the waiting room page. When the waiting room type is the default type, it needs to be passed in. The following types are supported:\n- `enus`: English.\n- `zhcn`: Simplified Chinese.\n- `zhhk`: Traditional Chinese."
      },
      "AllowedValues": [
        "enus",
        "zhcn",
        "zhhk"
      ],
      "Required": false
    },
    "QueuingMethod": {
      "Type": "String",
      "Description": {
        "en": "The queuing method. Value:\n- `random`: Users gain access to the origin randomly, regardless of the arrival time.\n- `fifo`: Users gain access to the origin in order of arrival.\n- `Passthrough`: Users pass through the waiting room and go straight to the origin.\n- `Reject-all`: Users are blocked from reaching the origin."
      },
      "AllowedValues": [
        "random",
        "fifo",
        "Passthrough",
        "Reject-all"
      ],
      "Required": true
    }
  },
  "Resources": {
    "ExtensionResource": {
      "Type": "ALIYUN::ESA::WaitingRoom",
      "Properties": {
        "Status": {
          "Ref": "Status"
        },
        "HostNameAndPath": {
          "Ref": "HostNameAndPath"
        },
        "SiteId": {
          "Ref": "SiteId"
        },
        "WaitingRoomType": {
          "Ref": "WaitingRoomType"
        },
        "CookieName": {
          "Ref": "CookieName"
        },
        "QueueAllEnable": {
          "Ref": "QueueAllEnable"
        },
        "WaitingRoomName": {
          "Ref": "WaitingRoomName"
        },
        "QueuingStatusCode": {
          "Ref": "QueuingStatusCode"
        },
        "NewUsersPerMinute": {
          "Ref": "NewUsersPerMinute"
        },
        "SessionDuration": {
          "Ref": "SessionDuration"
        },
        "Language": {
          "Ref": "Language"
        },
        "QueuingMethod": {
          "Ref": "QueuingMethod"
        }
      }
    }
  },
  "Outputs": {
    "HostNameAndPath": {
      "Description": "Host name and path.",
      "Value": {
        "Fn::GetAtt": [
          "ExtensionResource",
          "HostNameAndPath"
        ]
      }
    },
    "JsonResponseEnable": {
      "Description": "The JSON response. If the accept request header contains \"application/json\", JSON data is returned.",
      "Value": {
        "Fn::GetAtt": [
          "ExtensionResource",
          "JsonResponseEnable"
        ]
      }
    },
    "Description": {
      "Description": "Waiting room description.",
      "Value": {
        "Fn::GetAtt": [
          "ExtensionResource",
          "Description"
        ]
      }
    },
    "WaitingRoomType": {
      "Description": "Waiting room type, support:.",
      "Value": {
        "Fn::GetAtt": [
          "ExtensionResource",
          "WaitingRoomType"
        ]
      }
    },
    "DisableSessionRenewalEnable": {
      "Description": "Disable session renewal.",
      "Value": {
        "Fn::GetAtt": [
          "ExtensionResource",
          "DisableSessionRenewalEnable"
        ]
      }
    },
    "CookieName": {
      "Description": "Custom Cookie name.",
      "Value": {
        "Fn::GetAtt": [
          "ExtensionResource",
          "CookieName"
        ]
      }
    },
    "WaitingRoomName": {
      "Description": "The name of the waiting room.",
      "Value": {
        "Fn::GetAtt": [
          "ExtensionResource",
          "WaitingRoomName"
        ]
      }
    },
    "CustomPageHtml": {
      "Description": "User-defined waiting room page content, when the waiting room type is custom type, you need to enter. The incoming content needs to be base64 encoded.",
      "Value": {
        "Fn::GetAtt": [
          "ExtensionResource",
          "CustomPageHtml"
        ]
      }
    },
    "QueueAllEnable": {
      "Description": "All in line.",
      "Value": {
        "Fn::GetAtt": [
          "ExtensionResource",
          "QueueAllEnable"
        ]
      }
    },
    "QueuingStatusCode": {
      "Description": "Waiting room status code.",
      "Value": {
        "Fn::GetAtt": [
          "ExtensionResource",
          "QueuingStatusCode"
        ]
      }
    },
    "NewUsersPerMinute": {
      "Description": "Number of new users per minute.",
      "Value": {
        "Fn::GetAtt": [
          "ExtensionResource",
          "NewUsersPerMinute"
        ]
      }
    },
    "SessionDuration": {
      "Description": "Session duration in minutes.",
      "Value": {
        "Fn::GetAtt": [
          "ExtensionResource",
          "SessionDuration"
        ]
      }
    },
    "Language": {
      "Description": "The language of the waiting room page. When the waiting room type is the default type, it needs to be passed in.",
      "Value": {
        "Fn::GetAtt": [
          "ExtensionResource",
          "Language"
        ]
      }
    },
    "TotalActiveUsers": {
      "Description": "Total number of active users.",
      "Value": {
        "Fn::GetAtt": [
          "ExtensionResource",
          "TotalActiveUsers"
        ]
      }
    },
    "WaitingRoomId": {
      "Description": "The waiting room ID.",
      "Value": {
        "Fn::GetAtt": [
          "ExtensionResource",
          "WaitingRoomId"
        ]
      }
    },
    "QueuingMethod": {
      "Description": "Way of queuing.",
      "Value": {
        "Fn::GetAtt": [
          "ExtensionResource",
          "QueuingMethod"
        ]
      }
    }
  }
}