-
Notifications
You must be signed in to change notification settings - Fork 4.7k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Update Resource: azurerm_eventgrid_event_subscription
#6860
Update Resource: azurerm_eventgrid_event_subscription
#6860
Conversation
azurerm_eventgrid_event_subscription
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for the PR @jrauschenbusch, overallt his looks good with just a couple comments. My main concern is that making each enpoint a block with a single property, while matching the API, doesn't offer and ideal UX and adds complexity to the code. Do you think it would make sense to flatten that out a bit as describe in my comment?
azurerm/internal/services/eventgrid/eventgrid_event_subscription_resource.go
Outdated
Show resolved
Hide resolved
azurerm/internal/services/eventgrid/tests/eventgrid_event_subscription_resource_test.go
Outdated
Show resolved
Hide resolved
azurerm/internal/services/eventgrid/tests/eventgrid_event_subscription_resource_test.go
Outdated
Show resolved
Hide resolved
…cription_resource_test.go fix: rename test resource group Co-authored-by: kt <[email protected]>
…cription_resource_test.go refactor: reformatting Co-authored-by: kt <[email protected]>
azurerm/internal/services/eventgrid/parse/eventgrid_event_subscription.go
Outdated
Show resolved
Hide resolved
@katbyte Can you please review may latest update (Deprecations / ConflictsWith / Constants / Fixes in ExpirationTime expanding / flattening)? |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks @jrauschenbusch! aside from some minor comments on code style this is looking pretty good now 🙂
azurerm/internal/services/eventgrid/eventgrid_event_subscription_resource.go
Outdated
Show resolved
Hide resolved
azurerm/internal/services/eventgrid/eventgrid_event_subscription_resource.go
Outdated
Show resolved
Hide resolved
azurerm/internal/services/eventgrid/eventgrid_event_subscription_resource.go
Outdated
Show resolved
Hide resolved
azurerm/internal/services/eventgrid/eventgrid_event_subscription_resource.go
Outdated
Show resolved
Hide resolved
@katbyte no worries 😄everything should be fixed now. plz check it out. |
…ubscription-update
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks for those changes @jrauschenbusch! Some tests where failing so i hope you don't mind but i pushed some fixes for them. Also it seems functions were not working:
TestAccAzureRMEventGridEventSubscription_azureFunctionID: testing.go:640: Step 0 error: errors during apply:
Error: Error creating/updating EventGrid Event Subscription "acctest-eg-200524142001966081" (Scope "/subscriptions/1a6092a6-137e-4025-9a7c-ef77f76f2c02/resourceGroups/acctestRG-eg-200524142001966081"): eventgrid.EventSubscriptionsClient#CreateOrUpdate: Failure sending request: StatusCode=400 -- Original Error: Code="InvalidRequest" Message="Invalid ARM Id."
on /var/folders/bc/2t9ylvbn4lj1_nzj7bxj2kzc0000gn/T/tf-test720774928/main.tf line 35:
(source code not available)
and it seems like that one should be a block as there are other properties to set:
type AzureFunctionEventSubscriptionDestinationProperties struct {
// ResourceID - The Azure Resource Id that represents the endpoint of the Azure Function destination of an event subscription.
ResourceID *string `json:"resourceId,omitempty"`
// MaxEventsPerBatch - Maximum number of events per batch.
MaxEventsPerBatch *int32 `json:"maxEventsPerBatch,omitempty"`
// PreferredBatchSizeInKilobytes - Preferred batch size in Kilobytes.
PreferredBatchSizeInKilobytes *int32 `json:"preferredBatchSizeInKilobytes,omitempty"`
}
So i've removed it from this PR so we can get this merged and in for 2.12 - it can be added back in as a new PR.
This has been released in version 2.12.0 of the provider. Please see the Terraform documentation on provider versioning or reach out if you need any assistance upgrading. As an example: provider "azurerm" {
version = "~> 2.12.0"
}
# ... other configuration ... |
Updates/extends resource azurerm_eventgrid_event_subscription Additions to resource azurerm_eventgrid_event_subscription: service_bus_queue_endpoint service_bus_topic_endpoint expiration_time_utc Fixes hashicorp#4308 Fixes hashicorp#4857
I'm going to lock this issue because it has been closed for 30 days ⏳. This helps our maintainers find and focus on the active issues. If you feel this issue should be reopened, we encourage creating a new issue linking back to this one for added context. If you feel I made an error 🤖 🙉 , please reach out to my human friends 👉 [email protected]. Thanks! |
Updates/extends resource
azurerm_eventgrid_event_subscription
Additions to resource
azurerm_eventgrid_event_subscription
:Fixes #4308
Fixes #4857