From a9b8175d34504056160724371857ebeecd555a4f Mon Sep 17 00:00:00 2001 From: Rachel Hagerman <110480692+rlhagerm@users.noreply.github.com> Date: Fri, 18 Aug 2023 09:14:53 -0500 Subject: [PATCH] Adding additional action to Topics and Queues --- .doc_gen/metadata/sns_metadata.yaml | 11 +++++++++++ dotnetv3/SNS/README.md | 5 +++-- .../TopicsAndQueuesScenario/TopicsAndQueues.cs | 2 ++ 3 files changed, 16 insertions(+), 2 deletions(-) diff --git a/.doc_gen/metadata/sns_metadata.yaml b/.doc_gen/metadata/sns_metadata.yaml index a1785c30af9..6e58dbe0188 100644 --- a/.doc_gen/metadata/sns_metadata.yaml +++ b/.doc_gen/metadata/sns_metadata.yaml @@ -515,6 +515,17 @@ sns_Publish_WithAttribute: synopsis: publish a message with an attribute using &SNS;. category: languages: + .NET: + versions: + - sdk_version: 3 + github: dotnetv3/cross-service/TopicsAndQueues + excerpts: + - description: Publish a message to a topic with group, duplication, and attribute options. + snippet_tags: + - TopicsAndQueues.dotnetv3.PublishWithOptions + - description: Apply the user's selections to the publish action. + snippet_tags: + - TopicsAndQueues.dotnetv3.Publish C++: versions: - sdk_version: 1 diff --git a/dotnetv3/SNS/README.md b/dotnetv3/SNS/README.md index cc84236c161..b0f43aa02d4 100644 --- a/dotnetv3/SNS/README.md +++ b/dotnetv3/SNS/README.md @@ -1,4 +1,4 @@ - + # Amazon SNS code examples for the SDK for .NET ## Overview @@ -46,9 +46,10 @@ Code excerpts that show you how to call individual service functions. * [Get the properties of a topic](GetTopicAttributesExample/GetTopicAttributesExample/GetTopicAttributes.cs#L6) (`GetTopicAttributes`) * [List the subscribers of a topic](ListSNSSubscriptionsExample/ListSNSSubscriptionsExample/ListSubscriptions.cs#L6) (`ListSubscriptions`) * [List topics](ListSNSTopicsExample/ListSNSTopicsExample/ListSNSTopics.cs#L6) (`ListTopics`) +* [Publish a message with an attribute](../cross-service/TopicsAndQueues/Scenarios/TopicsAndQueuesScenario/TopicsAndQueues.cs#L334) (`Publish`) * [Publish an SMS text message](SNSMessageExample/SNSMessageExample/SNSMessage.cs#L4) (`Publish`) * [Publish to a topic](PublishToSNSTopicExample/PublishToSNSTopicExample/PublishToSNSTopic.cs#L6) (`Publish`) -* [Subscribe an SQS queue to a topic](../cross-service/TopicsAndQueues/Actions/SNSActions/SNSWrapper.cs#L94) (`Subscribe`) +* [Subscribe an SQS queue to a topic](../cross-service/TopicsAndQueues/Actions/SNSActions/SNSWrapper.cs#L67) (`Subscribe`) * [Subscribe an email address to a topic](ManageTopicSubscriptionExample/ManageTopicSubscriptionExample/ManageTopicSubscription.cs#L38) (`Subscribe`) * [Subscribe with a filter to a topic](../cross-service/TopicsAndQueues/Actions/SNSActions/SNSWrapper.cs#L94) (`Subscribe`) diff --git a/dotnetv3/cross-service/TopicsAndQueues/Scenarios/TopicsAndQueuesScenario/TopicsAndQueues.cs b/dotnetv3/cross-service/TopicsAndQueues/Scenarios/TopicsAndQueuesScenario/TopicsAndQueues.cs index 93e29664d62..a9090a5bba0 100644 --- a/dotnetv3/cross-service/TopicsAndQueues/Scenarios/TopicsAndQueuesScenario/TopicsAndQueues.cs +++ b/dotnetv3/cross-service/TopicsAndQueues/Scenarios/TopicsAndQueuesScenario/TopicsAndQueues.cs @@ -331,6 +331,7 @@ public static string CreateFilterPolicy() return filterPolicy; } + // snippet-start:[TopicsAndQueues.dotnetv3.PublishWithOptions] /// /// Publish messages using user settings. /// @@ -391,6 +392,7 @@ public static async Task PublishMessages() keepSendingMessages = GetYesNoResponse("Send another message?", false); } } + // snippet-end:[TopicsAndQueues.dotnetv3.PublishWithOptions] /// /// Poll for the published messages to see the results of the user's choices.