AWS::Greengrass::SubscriptionDefinition Subscription - AWS CloudFormation
Services or capabilities described in AWS documentation might vary by Region. To see the differences applicable to the AWS European Sovereign Cloud Region, see the AWS European Sovereign Cloud User Guide.

This is the new CloudFormation Template Reference Guide. Please update your bookmarks and links. For help getting started with CloudFormation, see the AWS CloudFormation User Guide.

AWS::Greengrass::SubscriptionDefinition Subscription

Subscriptions define how MQTT messages can be exchanged between devices, functions, and connectors in the group, and with AWS IoT or the local shadow service. A subscription defines a message source, message target, and a topic (or subject) that's used to route messages from the source to the target. A subscription defines the message flow in one direction, from the source to the target. For two-way communication, you must set up two subscriptions, one for each direction.

In an CloudFormation template, the Subscriptions property of the SubscriptionDefinitionVersion property type contains a list of Subscription property types.

Syntax

To declare this entity in your CloudFormation template, use the following syntax:

JSON

{ "Id" : String, "Source" : String, "Subject" : String, "Target" : String }

YAML

Id: String Source: String Subject: String Target: String

Properties

Id

A descriptive or arbitrary ID for the subscription. This value must be unique within the subscription definition version. Maximum length is 128 characters with pattern [a-zA-Z0-9:_-]+.

Required: Yes

Type: String

Update requires: Replacement

Source

The originator of the message. The value can be a thing ARN, the ARN of a Lambda function alias (recommended) or version, a connector ARN, cloud (which represents the AWS IoT cloud), or GGShadowService.

Required: Yes

Type: String

Update requires: Replacement

Subject

The MQTT topic used to route the message.

Required: Yes

Type: String

Update requires: Replacement

Target

The destination of the message. The value can be a thing ARN, the ARN of a Lambda function alias (recommended) or version, a connector ARN, cloud (which represents the AWS IoT cloud), or GGShadowService.

Required: Yes

Type: String

Update requires: Replacement

See also