fleet/server/datastore
Magnus Jensen 316adb4cd0
randomize APNS query (#38222)
<!-- Add the related story/sub-task/bug number, like Resolves #123, or
remove if NA -->
**Related issue:** Resolves #36644 

Randomizes the query so we get a new set of 500 every time, and also
improves the index by adding a priority where clause.

It should fine handle up towards 10.000 filtered entries before becoming
slow, and at most we have seen 2k with a customer.

# Checklist for submitter

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

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

## Testing

- [x] Added/updated automated tests
- [x] QA'd all new/changed functionality manually
2026-01-13 13:06:33 -05:00
..
cached_mysql Okta IdP factor (#35143) 2025-11-07 16:19:25 -06:00
failing Cloudfront signing for in-house apps (#37650) 2026-01-05 16:30:31 -05:00
filesystem Cloudfront signing for in-house apps (#37650) 2026-01-05 16:30:31 -05:00
mysql randomize APNS query (#38222) 2026-01-13 13:06:33 -05:00
mysqlredis Add activity feed entries for host deletion and expiration (#34720) 2025-10-31 09:37:31 -07:00
redis New rate limit algorithm for Fleet Desktop endpoints (#33344) 2025-09-26 15:03:50 -03:00
s3 Cloudfront signing for in-house apps (#37650) 2026-01-05 16:30:31 -05:00