feat: support workflow ownership tags#180
Merged
Merged
Conversation
There was a problem hiding this comment.
Pull request overview
This PR adds support for the workflow IaC ownership provider contract in the DigitalOcean plugin by representing ownership via workflow-owner:<owner> tags and exposing the new Ownership gRPC service/manifest capability.
Changes:
- Implement
interfaces.OwnershipProvideron*DOProviderusing DigitalOcean tags, plus a gRPC server adapter for the ownership RPCs. - Advertise
IaCProviderOwnershipin both plugin manifests and bumpminEngineVersion/ workflow dependency to0.69.1. - Include database/cache
tagsin read outputs so ownership reads remain consistent across resource types.
Reviewed changes
Copilot reviewed 10 out of 11 changed files in this pull request and generated 3 comments.
Show a summary per file
| File | Description |
|---|---|
| plugin.json | Bumps minEngineVersion and advertises Ownership service in iacServices. |
| cmd/plugin/plugin.json | Mirrors manifest changes for the embedded/bundled plugin manifest. |
| internal/ownership.go | Adds ownership provider implementation (tag parsing/encoding, read/set/list). |
| internal/ownership_server.go | Adds gRPC handlers mapping pb Ownership RPCs to provider methods. |
| internal/ownership_test.go | Adds unit tests for provider behavior + service registration + manifest advertising. |
| internal/iacserver.go | Embeds UnimplementedIaCProviderOwnershipServer and asserts interface implementation. |
| internal/iacserver_mapper_test.go | Updates min engine version expectation to 0.69.1. |
| internal/drivers/database.go | Adds tags to database outputs in structpb-compatible form. |
| internal/drivers/cache.go | Adds tags to cache outputs in structpb-compatible form. |
| go.mod | Updates workflow dependency to 0.69.1-... prerelease. |
| go.sum | Updates dependency checksums for the workflow version bump. |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
workflow-owner:<owner>DO tags for droplets, volumes, databases, and cachesIaCProviderOwnershipin plugin manifests and bumpsminEngineVersionto0.69.1Verification
GOWORK=off go test ./... -count=1GOWORK=off golangci-lint run ./internal/... ./cmd/... --new-from-rev origin/maingit diff --checkTDD / regression proof
With implementation absent, the new tests failed to compile as expected:
With the implementation restored, the focused tests pass:
Depends on merged workflow PR GoCodeAlone/workflow#824 (
0072d3221).