[MAINT] migrate github_branch_default to context-aware CRUD functions and tflog#3327
[MAINT] migrate github_branch_default to context-aware CRUD functions and tflog#3327ElenaZvereva wants to merge 3 commits into
Conversation
|
👋 Hi! Thank you for this contribution! Just to let you know, our GitHub SDK team does a round of issue and PR reviews twice a week, every Monday and Friday! We have a process in place for prioritizing and responding to your input. Because you are a part of this community please feel free to comment, add to, or pick up any issues/PRs that are labeled with |
|
Would you be available to rebase this (possibly multiple times) during the next week? We're going to release 6.13.0 and will try to land some of these open PRs |
There was a problem hiding this comment.
Pull request overview
Migrates the github_branch_default Terraform resource to Terraform Plugin SDK v2 context-aware CRUD handlers and switches logging to tflog, aligning this resource with the provider’s ongoing context + structured logging modernization efforts.
Changes:
- Switched resource handlers from legacy
Create/Read/Update/DeletetoCreateContext/ReadContext/UpdateContext/DeleteContext. - Updated CRUD implementations to accept
context.Contextand returndiag.Diagnostics(usingdiag.FromErrfor error propagation). - Replaced
log.Printfwith structuredtflog.Infologging for state-removal on 404s.
|
Yes, I'll do this |
Part of #2996 and #3070
Before the change?
Create,Read,Update,Delete) were used inresource_github_branch_default.go.logpackage was used for logging.After the change?
CreateContext,ReadContext,UpdateContext,DeleteContext).logusage with HashiCorp's structured logging packagetflog.Pull request checklist
Does this introduce a breaking change?
Please see our docs on breaking changes to help!