-
Notifications
You must be signed in to change notification settings - Fork 503
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
Resend Windows profiles on change #27308
Conversation
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #27308 +/- ##
========================================
Coverage 63.89% 63.89%
========================================
Files 1731 1733 +2
Lines 164610 165049 +439
Branches 4412 4412
========================================
+ Hits 105175 105457 +282
- Misses 51267 51384 +117
- Partials 8168 8208 +40
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
MigrationClient.AddMigration(Up_20250318165922, Down_20250318165922) | ||
} | ||
|
||
func Up_20250318165922(tx *sql.Tx) error { |
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.
Just double-checking as it is already included in the PR checklist, but have you tested if/how this migration will any impact existing time-based comparisons related to profile delivery, reconciliation, verification, etc.?
For example, in the UPDATE
statement should we preserve the hmwp.updated_at
timestamp in line 31?
I don't recall offhand whether ALTER
statements themselves causes ON UPDATE
to fire so it may be worth a quick test to confirm that as well.
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.
ALTER statements don't cause ON UPDATE to fire. I checked this before.
The updated_at
column is new here, and is only here for debug/auditing. It is not used in the code. So, it is OK for it to be updated when setting checksum.
@@ -1127,6 +1127,174 @@ func (s *integrationMDMTestSuite) TestWindowsProfileRetries() { | |||
}) | |||
} | |||
|
|||
// TestWindowsProfileResent verifies that a Windows profile is resend when its contents have been modified. |
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.
Nit:
// TestWindowsProfileResent verifies that a Windows profile is resend when its contents have been modified. | |
// TestWindowsProfileResent verifies that a Windows profile is resent when its contents have been modified. |
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. Will add to next PR.
For fleetdm#25030 This PR includes the bug fix and tests. It also includes the `secrets_updated_at` columns needed for story fleetdm#27351. These columns are currently unused and always NULL. # Checklist for submitter - [x] Changes file added for user-visible changes in `changes/`, `orbit/changes/` or `ee/fleetd-chrome/changes`. See [Changes files](https://github.com/fleetdm/fleet/blob/main/docs/Contributing/Committing-Changes.md#changes-files) for more information. - [x] If database migrations are included, checked table schema to confirm autoupdate - For database migrations: - [x] Checked schema for all modified table for columns that will auto-update timestamps during migration. - [x] Confirmed that updating the timestamps is acceptable, and will not cause unwanted side effects. - [x] Ensured the correct collation is explicitly set for character columns (`COLLATE utf8mb4_unicode_ci`). - [x] Added/updated automated tests - [x] A detailed QA plan exists on the associated ticket (if it isn't there, work with the product group's QA engineer to add it) - [x] Manual QA for all new/changed functionality
For #25030
This PR includes the bug fix and tests.
It also includes the
secrets_updated_at
columns needed for story #27351. These columns are currently unused and always NULL.Checklist for submitter
changes/
,orbit/changes/
oree/fleetd-chrome/changes
.See Changes files for more information.
COLLATE utf8mb4_unicode_ci
).