-
Notifications
You must be signed in to change notification settings - Fork 156
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] Add notes about drift detection #5120
Conversation
Signed-off-by: t-kikuc <tkikuchi07f@gmail.com>
Signed-off-by: t-kikuc <tkikuchi07f@gmail.com>
@@ -807,7 +807,7 @@ Note: By default, the sum of traffic is rounded to 100. If both `primary` and `c | |||
|
|||
| Field | Type | Description | Required | | |||
|-|-|-|-| | |||
| ignoreFields | []string | List of fields path in manifests, which its diff should be ignored. | No | | |||
| ignoreFields | []string | List of fields path in manifests, which its diff should be ignored. This is available for only `KubernetesApp`.This is available for only `KubernetesApp`. | No | |
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.
This is mistakenly repeated twice.
| ignoreFields | []string | List of fields path in manifests, which its diff should be ignored. This is available for only `KubernetesApp`.This is available for only `KubernetesApp`. | No | | |
| ignoreFields | []string | List of fields path in manifests, which its diff should be ignored. This is available for only `KubernetesApp`. | No | |
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, I fixed
@@ -50,7 +50,7 @@ This status means the application is deploying and the configuration drift detec | |||
|
|||
### How to enable | |||
|
|||
This feature is automatically enabled for all applications. | |||
By default, drift detection is **NOT** enabled. You can enable it for each application by configuring application's [OnOutOfSync.disabled](../configuration-reference/#onoutofsync). |
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.
The "drift detection" feature is the detection feature, not the reconcile feature.
The option you mention in this PR is the reconcile option; the deployment will be triggered when the sync state is OUT_OF_SYNC.
So, I mean, the drift detection is enabled by default.
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.
Yes, the drift detection is enabled by default. The disabled code is disabled the auto trigger new deployment on OUT_OF_SYNC by default @t-kikuc
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 both,
yeah, drift detection is enabled by default, and deployment on OutOfSync is not.
I recovered the previous sentence and added a new explanation. 2f0785b
This feature is automatically enabled for all applications.
If you want to deploy automatically when `OUT_OF_SYNC` occures, configure each application's [OnOutOfSync](../configuration-reference/#onoutofsync).
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.
@t-kikuc There is a long-time story about this spec 😓
ref: #2752
tl;dr: Previously, we didn't support trigger deployment on OUT_OF_SYNC, which someone thinks that it didn't suit the GitOps spec, so we decided to add that feature. The problem is, if we make that trigger by default, our users at that time will be affected (due to a ton of unexpected deployment triggers whenever OUT_OF_SYNC happens). That's why we make this spec - disable trigger deployment on OUT_OF_SYNC by default. 😄
Signed-off-by: t-kikuc <tkikuchi07f@gmail.com>
Signed-off-by: t-kikuc <tkikuchi07f@gmail.com>
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.
LGTM
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## master #5120 +/- ##
==========================================
+ Coverage 22.78% 22.80% +0.01%
==========================================
Files 412 412
Lines 43863 43827 -36
==========================================
Hits 9996 9996
+ Misses 33080 33044 -36
Partials 787 787 ☔ View full report in Codecov by Sentry. |
@@ -52,6 +52,8 @@ This status means the application is deploying and the configuration drift detec | |||
|
|||
This feature is automatically enabled for all applications. | |||
|
|||
If you want to deploy automatically when `OUT_OF_SYNC` occures, configure each application's [OnOutOfSync](../configuration-reference/#onoutofsync). |
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.
If you want to deploy automatically when `OUT_OF_SYNC` occures, configure each application's [OnOutOfSync](../configuration-reference/#onoutofsync). | |
If you want to trigger deployment automatically when `OUT_OF_SYNC` occurs, configure each application's [OnOutOfSync](../configuration-reference/#onoutofsync). |
typo and re-write 👀
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.
Same for the others
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.
On the second thought, I think this note could lead to confusing situation 🤔 We have place explain how to trigger pipecd deployment here: https://pipecd.dev/docs-v0.48.x/user-guide/managing-application/triggering-a-deployment/#trigger-configuration
Merging this note here could lead to confusion between drift detection feature and trigger feature of pipecd. This page is about enable/disable drift detection feature, nothing related to trigger deployment should be placed here. WDYT? @t-kikuc @Warashi
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.
This document is not a document like a dictionary, so we can write the same thing on several pages.
However, we can avoid confusion by the guide having centralized, with only one page at one thing.
I propose that this notation have a link to the page @khanhtc1202 mentioned, not the configuration reference page.
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.
I propose that this notation have a link to the page @khanhtc1202 mentioned, not the configuration reference page.
I agree
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.
I fixed: a25e438
### How to enable
This feature is automatically enabled for all applications.
If you want to trigger deployment automatically when `OUT_OF_SYNC` occurs, see [Trigger configuration](./triggering-a-deployment/#trigger-configuration).
Signed-off-by: t-kikuc <tkikuchi07f@gmail.com>
@@ -52,6 +52,8 @@ This status means the application is deploying and the configuration drift detec | |||
|
|||
This feature is automatically enabled for all applications. | |||
|
|||
If you want to trigger deployment automatically when `OUT_OF_SYNC` occurs, see [Trigger configuration](./triggering-a-deployment/#trigger-configuration). |
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.
This should be a note and place under L57
This feature is automatically enabled for all applications.
You can change the checking interval as well as [configure the notification](../../managing-piped/configuring-notifications/) for these events in `piped` configuration.
Note: If you want to trigger deployment automatically when `OUT_OF_SYNC` occurs, see [Trigger configuration](./triggering-a-deployment/#trigger-configuration).
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.
It's an easier to read flow
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, i fixed 7b6dba3
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
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
What this PR does / why we need it:
Fix: DriftDetection is DISABLED by default.. Add Note: DriftDetection is enabled by default, but automatic deployment is disabled by default.Add Note:
ignoreFields
is supported for only K8sApp.pipecd/pkg/app/piped/driftdetector/kubernetes/detector.go
Line 196 in 7ed87bc