Skip to content

Support categories for in-house apps - #35542

Merged
jkatz01 merged 10 commits into
mainfrom
35464-iha-categories
Nov 11, 2025
Merged

Support categories for in-house apps#35542
jkatz01 merged 10 commits into
mainfrom
35464-iha-categories

Conversation

@jkatz01

@jkatz01 jkatz01 commented Nov 11, 2025

Copy link
Copy Markdown
Member

Related issue: Resolves #35464
Also allows #35531 to be merged
Adds self-service categories for #32247

Changes:

  • Move category insertion up in update installer so in house apps can use it
  • Add migration for in_house_app_software_categories table
  • Fix some overly wrapped errors
  • Add new tests for categories
  • Fix unused param in another test

Checklist for submitter

If some of the following don't apply, delete the relevant line.

  • Changes file added for user-visible changes in changes/, orbit/changes/ or ee/fleetd-chrome/changes.
    See Changes files for more information.

  • Input data is properly validated, SELECT * is avoided, SQL injection is prevented (using placeholders for values in statements)

  • If paths of existing endpoints are modified without backwards compatibility, checked the frontend/CLI for any necessary changes

Testing

Database migrations

  • Checked schema for all modified table for columns that will auto-update timestamps during migration.
  • Confirmed that updating the timestamps is acceptable, and will not cause unwanted side effects.
  • Ensured the correct collation is explicitly set for character columns (COLLATE utf8mb4_unicode_ci).

@jkatz01
jkatz01 marked this pull request as ready for review November 11, 2025 19:12
@jkatz01
jkatz01 requested a review from a team as a code owner November 11, 2025 19:12
@codecov

codecov Bot commented Nov 11, 2025

Copy link
Copy Markdown

Codecov Report

❌ Patch coverage is 77.04918% with 14 lines in your changes missing coverage. Please review.
✅ Project coverage is 66.14%. Comparing base (0471b8c) to head (df9edf2).
⚠️ Report is 26 commits behind head on main.

Files with missing lines Patch % Lines
server/datastore/mysql/in_house_apps.go 50.00% 5 Missing and 3 partials ⚠️
...ions/tables/20251110172137_InHouseAppCategories.go 80.00% 3 Missing and 1 partial ⚠️
ee/server/service/software_installers.go 81.81% 1 Missing and 1 partial ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main   #35542      +/-   ##
==========================================
+ Coverage   66.13%   66.14%   +0.01%     
==========================================
  Files        2100     2101       +1     
  Lines      177469   177514      +45     
  Branches     7260     7260              
==========================================
+ Hits       117370   117419      +49     
+ Misses      49338    49329       -9     
- Partials    10761    10766       +5     
Flag Coverage Δ
backend 67.79% <77.04%> (+0.01%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.
  • 📦 JS Bundle Analysis: Save yourself from yourself by tracking and limiting bundle sizes in JS merges.

@mna mna left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Looks great! Just a small DB migration comment.

Comment thread server/datastore/mysql/migrations/tables/20251110172137_InHouseAppCategories.go Outdated
@jkatz01
jkatz01 merged commit 9b36abc into main Nov 11, 2025
42 checks passed
@jkatz01
jkatz01 deleted the 35464-iha-categories branch November 11, 2025 20:13
jkatz01 added a commit that referenced this pull request Nov 12, 2025
<!-- Add the related story/sub-task/bug number, like Resolves #123, or
remove if NA -->
**Related issue:** Resolves #35464 
Also allows #35531 to be merged
Adds self-service categories for #32247

Changes:
- Move category insertion up in update installer so in house apps can
use it
- Add migration for in_house_app_software_categories table
- Fix some overly wrapped errors
- Add new tests for categories
- Fix unused param in another test

# Checklist for submitter

If some of the following don't apply, delete the relevant line.

- [ ] 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/guides/committing-changes.md#changes-files)
for more information.

- [ ] Input data is properly validated, `SELECT *` is avoided, SQL
injection is prevented (using placeholders for values in statements)
- [ ] If paths of existing endpoints are modified without backwards
compatibility, checked the frontend/CLI for any necessary changes

## Testing

- [x] Added/updated automated tests
- [ ] Where appropriate, [automated tests simulate multiple hosts and
test for host
isolation](https://github.com/fleetdm/fleet/blob/main/docs/Contributing/reference/patterns-backend.md#unit-testing)
(updates to one hosts's records do not affect another)

- [x] QA'd all new/changed functionality manually

## Database migrations

- [ ] Checked schema for all modified table for columns that will
auto-update timestamps during migration.
- [ ] Confirmed that updating the timestamps is acceptable, and will not
cause unwanted side effects.
- [ ] Ensured the correct collation is explicitly set for character
columns (`COLLATE utf8mb4_unicode_ci`).
jkatz01 added a commit that referenced this pull request Nov 12, 2025
Merged into main in #35542
Adds categories support for in-house apps and minor bug fixes.
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.

Support categories for in-house apps self-service

2 participants