Skip to content

Commit

Permalink
[azsystemevents] Updating to release commit for April ca560e400087f54…
Browse files Browse the repository at this point in the history
…b306f3a21df582c8a5bbd0abc (#22683)

Updating to release commit for April: ca560e400087f54b306f3a21df582c8a5bbd0abc

As part of this some existing types were renamed, all of which is documented in the changelog.
  • Loading branch information
richardpark-msft authored Apr 3, 2024
1 parent a742404 commit 45b7241
Show file tree
Hide file tree
Showing 8 changed files with 126 additions and 69 deletions.
8 changes: 7 additions & 1 deletion sdk/messaging/eventgrid/azsystemevents/CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,14 +1,20 @@
# Release History

## 0.3.0 (TBD)
## 0.3.0 (2024-04-03)

### Features Added

- Added events ACSRouterWorkerUpdatedEventData and ACSAdvancedMessageDeliveryStatusUpdatedEventData. (PR#22638)

### Breaking Changes

Field and type renames:
- Globally, types and fields named ChannelType has been renamed to ChannelKind
- ACS events and constants have been changed to use an all-caps name (ex: AcsEmailDeliveryReportStatusDetails -> ACSEmailDeliveryReportStatusDetails).
- ACSAdvancedMessageContext.ID -> MessageID
- ACSAdvancedMessageReceivedEventData
- .Media -> MediaContent
- .Interactive -> InteractiveContent

## 0.2.0 (2024-03-14)

Expand Down
2 changes: 1 addition & 1 deletion sdk/messaging/eventgrid/azsystemevents/autorest.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ description: Azure Event Grid system events
generated-metadata: false
clear-output-folder: false
go: true
require: https://github.com/Azure/azure-rest-api-specs/blob/c25006263b7c15ad5da755a5ef864e4301e56b54/specification/eventgrid/data-plane/readme.md
require: https://github.com/Azure/azure-rest-api-specs/blob/ca560e400087f54b306f3a21df582c8a5bbd0abc/specification/eventgrid/data-plane/readme.md
license-header: MICROSOFT_MIT_NO_VERSION
openapi-type: "data-plane"
output-folder: ../azsystemevents
Expand Down
88 changes: 55 additions & 33 deletions sdk/messaging/eventgrid/azsystemevents/constants.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Original file line number Diff line number Diff line change
Expand Up @@ -262,6 +262,27 @@ func getConstantsReplacements(syms *gopls.SymbolMap) []rename {
}
}

// TODO: it'd be nice to make this a bit more general
renames = append(renames, rename{
Orig: syms.Get("RecordingChannelType"),
New: "RecordingChannelKind",
})

renames = append(renames, rename{
Orig: syms.Get("PossibleRecordingChannelTypeValues"),
New: "PossibleRecordingChannelKindValues",
})

renames = append(renames, rename{
Orig: syms.Get("RecordingChannelTypeMixed"),
New: "RecordingChannelKindMixed",
})

renames = append(renames, rename{
Orig: syms.Get("RecordingChannelTypeUnmixed"),
New: "RecordingChannelKindUnmixed",
})

sort.Slice(renames, func(i, j int) bool {
return renames[i].New < renames[j].New
})
Expand All @@ -274,6 +295,14 @@ func getModelsReplacements(syms *gopls.SymbolMap) []rename {
var renames []rename

for _, sym := range syms.All() {
if strings.EqualFold("AcsRecordingFileStatusUpdatedEventData.RecordingChannelType", sym.Name) {
renames = append(renames, rename{
Orig: sym,
New: "RecordingChannelKind",
})
continue
}

matches := typeRE.FindStringSubmatch(sym.Name)

if matches != nil {
Expand Down
24 changes: 12 additions & 12 deletions sdk/messaging/eventgrid/azsystemevents/models.go

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

Loading

0 comments on commit 45b7241

Please sign in to comment.