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

docs: Feature toggles initial draft #133

Merged
merged 3 commits into from Jul 26, 2022

Conversation

davidvc
Copy link
Contributor

@davidvc davidvc commented Mar 29, 2022

Here is an initial draft of a guide for using feature toggles.

I still have an open item for what to do around provider verification, with an open question on Slack about this.

But I thought it would be good to get feedback on the reset of it in the meantime

@davidvc davidvc changed the title docs: Feature toggles initial draft doc: Feature toggles initial draft Mar 29, 2022
@YOU54F YOU54F self-requested a review March 31, 2022 18:02
@davidvc davidvc changed the title doc: Feature toggles initial draft docs: Feature toggles initial draft Mar 31, 2022
@YOU54F
Copy link
Member

YOU54F commented Apr 1, 2022

@davidvc
Copy link
Contributor Author

davidvc commented Apr 1, 2022

That page deploy is nice! I have more details on how to do provider verification when using environments, releases and deploys. I'm not sure you can solve this easily with pure tags; I need to look into this more.

@davidvc
Copy link
Contributor Author

davidvc commented Apr 1, 2022

@bethesque @mefellows I looked at the new webhook, for the content requiring verification published event. It is sooo close but I think it won't work with feature flags. The reason is it verifies the latest version on the main branch. If you have multiple active feature toggles on the main branch, you want to verify all of them.

I'm not sure how we would resolve this. Essentially one code version (the latest version on the branch) has multiple toggle versions. With the current data model, there is no direct way to know which toggle versions are part of the latest code version on the branch.

But maybe for now it's sufficient to verify each version currently deployed to an environment? The risk is that you merge a toggle version into main that's not compatible with a consumer, and you wouldn't find out until you tried to deploy or release to environment and you realize that that version has not yet been verified. So it won't cause failures in environments, but it will cause pipelines to block until you kick off the necessary verifications.

Hopefully I'm missing something?

@YOU54F
Copy link
Member

YOU54F commented Apr 7, 2022

Hey @mefellows , @bethesque , @uglyog

Wondered if we could get a penny for your thoughts, came from a question by our recent doc wizard @davidvc

Hey, good evening. I wanted to let you know I'm kind of stuck with the feature flag work because I don't have good guidance on how someone will ensure that the right provider versions participate in verification. The new webhook will run the verification job for all versions of the provider that are deployed or released, plus the latest version on the main branch. But we actually need to test all versions on the main branch that are current (e.g. the base version, plus all the toggle versions).

@mefellows
Copy link
Member

Hey @mefellows , @bethesque , @uglyog

Wondered if we could get a penny for your thoughts, came from a question by our recent doc wizard @davidvc

Hey, good evening. I wanted to let you know I'm kind of stuck with the feature flag work because I don't have good guidance on how someone will ensure that the right provider versions participate in verification. The new webhook will run the verification job for all versions of the provider that are deployed or released, plus the latest version on the main branch. But we actually need to test all versions on the main branch that are current (e.g. the base version, plus all the toggle versions).

I sadly don't have any additional good advice here team. I think it might be possible to use a tag selector (e.g. toggle) along side a branch selector (e.g. main) with latest set to false. This would validate all pacts for the main branch with tag toggle. The issue is, you would need to remove the toggle from the version afterwards and I could see this getting fiddly. I think we need a conceptual model update that incorporates toggles as a first class thing.

@YOU54F
Copy link
Member

YOU54F commented Jul 26, 2022

Hey hey, going to release this today and see how we get on with feedback.

Will try and build out an example when time permits

@YOU54F YOU54F merged commit 592a7fd into pact-foundation:master Jul 26, 2022
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.

None yet

3 participants