Skip to content
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

feat: Persist provider configuration in protobuf #1021

Merged
merged 1 commit into from
Sep 26, 2023
Merged

Conversation

JAORMX
Copy link
Contributor

@JAORMX JAORMX commented Sep 26, 2023

This moves the provider configuration from the providers package into the protobuf definitions.

This enables us to be able to configure/create/update providers via protobuf in the future.

For now, we only have the protobuf structure, but in the future we'll have a ProvidersService
API that we'll be able to leverage in order to manage providers.

@JAORMX JAORMX force-pushed the providers-proto branch 3 times, most recently from fecf354 to f9463f1 Compare September 26, 2023 12:03
This moves the provider configuration from the providers package into the protobuf definitions.

This enables us to be able to configure/create/update providers via protobuf in the future.

For now, we only have the protobuf structure, but in the future we'll have a `ProvidersService`
API that we'll be able to leverage in order to manage providers.
Copy link
Contributor

@jhrozek jhrozek left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

two questions, but nothing blocking


// Validate is a utility function which allows for the validation of a struct.
func (_ *GitHubProviderConfig) Validate() error {
// Unfortunately, we don't currently have a way to add custom tags to
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this is currently empty because not even the API endpoint is required right?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

That's right

// - rest
// - github
// - git
repeated string implements = 4;
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Have you considered an enum instead?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm still not quite sure how to make enums user friendly and string (db) friendly 🤔

@JAORMX JAORMX merged commit 163ee4c into main Sep 26, 2023
13 checks passed
@JAORMX JAORMX deleted the providers-proto branch September 26, 2023 19:41
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants