You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: transports/azure-storage-queues/multi-storageaccount-support.md
+41-4Lines changed: 41 additions & 4 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -33,12 +33,49 @@ For additional guidance on considerations when developing a system using Azure S
33
33
34
34
The preferred way to route when using multiple accounts is to register endpoints with their associated storage accounts.
35
35
36
-
partial: registered-endpoint
36
+
### Aliases instead of connection strings
37
37
38
-
NServiceBus also allows specifying destination addresses using the `<endpoint>@<physicallocation>` notation when messages are dispatched. In this notation, the `physicallocation` element represents the location where the endpoint's infrastructure is hosted, such as a storage account.
38
+
To avoid connection strings leaking, aliases are always used, using an empty string as the default.
39
+
Therefore, when multiple accounts are used, an alias has to be registered for each storage account.
40
+
41
+
To enable sending from `account_A` to `account_B`, the following configuration needs to be applied in the `account_A` endpoint:
Aliases can be provided for both the endpoint's connection strings as well as other accounts' connection strings. This enables using the `@` notation for destination addresses like `queue_name@accountAlias`.
> The examples above use different values for the default account aliases. Using the same name, such as `default`, to represent different storage accounts in different endpoints is highly discouraged as it introduces ambiguity in resolving addresses like `queue@default` and may cause issues when e.g. replying. In that case an address is interpreted as a reply address, the name `default` will point to a different connection string.
51
+
52
+
> [!NOTE]
53
+
> This feature is currently NOT compatible with ServiceControl. A [ServiceControl transport adapter](/servicecontrol/transport-adapter.md) is required in order to leverage both.
54
+
55
+
### Using registered endpoints
56
+
57
+
In order to route message to endpoints without having to specify the destination at all times, it is also possible to register the endpoint for a given command type, assembly or namespace
Similar to sending to an endpoint, the transport can also be configured to subscribe to events published by endpoints in another storage account, using:
NServiceBus also allows specifying destination addresses using the `<endpoint>@<physicallocation>` notation when messages are dispatched. In this notation, the `physicallocation` element represents the location where the endpoint's infrastructure is hosted, such as a storage account alias.
39
74
40
75
Using this notation, it is possible to route messages to any endpoint hosted in any storage account.
The use of send options enables routing messages to any endpoint hosted in another storage account by specifying the storage account using the `@` notation.
78
+
The `@` notation is used to point to a connection string represented by a specified alias.
Copy file name to clipboardExpand all lines: transports/azure-storage-queues/multi-storageaccount-support_routing-send-options-full-connectionstring_asq_[7,8].partial.md
Copy file name to clipboardExpand all lines: transports/azure-storage-queues/multi-storageaccount-support_routing-send-options-full-connectionstring_asqn_[9,).partial.md
0 commit comments