Skip to content

Commit b347da7

Browse files
authored
Docs: show how to retrieve EventHub connection string as template output (#1250)
1 parent d71d106 commit b347da7

1 file changed

Lines changed: 11 additions & 3 deletions

File tree

docs/content/api-overview/resources/event-hub.md

Lines changed: 11 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -35,8 +35,8 @@ The Event Hub builder creates event hub namespaces, event hubs, consumer groups
3535
#### Configuration Members
3636
| Member | Purpose |
3737
|-|-|
38-
| DefaultKey | Gets an ARM expression for the root namespace key of the Event Hub namespace. |
39-
| GetKey | Gets an ARM expression for a named key on this event hub. |
38+
| DefaultKey | Gets an ARM expression for the default namespace connection string of the Event Hub namespace. |
39+
| GetKey | Gets an ARM expression for the connection string of a named authorization rule on this event hub. |
4040

4141
#### Example
4242

@@ -67,6 +67,14 @@ let secondHub = eventHub {
6767
link_to_namespace "allmyevents"
6868
partitions 1
6969
message_retention_days 1
70-
capture_to_storage myStorageAccount "mycontainer"
70+
capture_to_storage storage "mycontainer"
71+
}
72+
73+
let deployment = arm {
74+
location Location.NorthEurope
75+
add_resource primaryHub
76+
add_resource secondHub
77+
output "EventHubDefaultConnectionString" primaryHub.DefaultKey
78+
output "EventHubFirstRuleConnectionString" (primaryHub.GetKey "FirstRule")
7179
}
7280
```

0 commit comments

Comments
 (0)