Repository navigation
release: Fleet-Ops v0.6.67 - #326
Merged
Merged
Conversation
…c work AFAQY reliability and incident corrections: - Recover unreadable disposable cached tokens under the account lock and authenticate again without resetting stored credentials or unrelated secrets. - Share an aggregate request deadline across authentication, refresh, and Units List retrieval; expose bounded request and ingestion batch settings. - Add an idempotent device_events UUID lookup index to avoid full-table scans during model refresh and activity logging. - Persist discovery phases and progress counters while ingestion is running, and isolate inventory records without valid positions from valid neighbors. - Shorten telemetry scheduler overlap leases and keep dispatch recoverable after broker failures and interrupted scheduler processes. Provider-neutral polling and ingestion: - Let opted-in providers use the shared durable telemetry path for manual synchronization, including previously queued discovery jobs. - Bound polling attempts below the baseline Redis reservation interval, retain a fixed retry deadline, and distinguish ingestion waits from failed attempts. - Associate manual progress and completion with the matching ingestion run so an older run cannot finalize a newer synchronization request. - Checkpoint encrypted delivery tails and accumulated item outcomes, yielding long batches for continuation through the existing inbox drain/default queue. - Keep transiently failing enabled integrations eligible for scheduled recovery. Safee / DSCO implementation in progress: - Replace routine per-vehicle last-info, positions, and events enrichment with cached inventory and live last-state batches of at most 1,000 vehicle IDs. - Validate successful response envelopes and canonical unit identities; retain missing individual states as explicit invalid-position results. - Add encrypted credential-scoped OAuth caching, expiry-aware refresh, bounded transport deadlines, a shared 50-request-per-second budget, and Retry-After. - Normalize source timestamps and available telemetry through the shared ingestion contract; keep explicit enrichment/history APIs separate. - Register Safee durable polling configuration and document the API contract, measured read-only request timings, rollout considerations, and limitations. Interface and test support: - Place live telemetry inside the details-page spacing and use a compact responsive label/value grid, smaller actions, and collapsible setup/failures. - Resolve the radar link correctly in both host and mounted-engine contexts. - Add Laravel encryption test support and regression fixtures for token recovery, migration behavior, mixed fleets, manual polling, and delivery continuation. Validation and unfinished work: - Latest recorded Safee contract tests: 26 tests / 118 assertions passed. - Latest recorded Safee provider tests: 6 tests / 126 assertions passed. - Latest recorded manual polling tests: 14 tests / 73 assertions passed. - Safee database ingestion: 6 tests / 31 assertions, with one known failure: an omitted internal_id still overwrites the existing device identity. - Final checkpoint tests, broader shared-provider regressions, and live Safee execution on the single default worker remain unfinished. Read-only API timings and fewer requests do not establish end-to-end throughput. - This commit preserves the requested work for continuation and review; the unfinished Safee path must not be represented as fully validated for release.
Safee / DSCO polling - Pausing a batch-only provider (SAFEE_POLLING_ENABLED=false) no longer queues legacy discovery jobs that fail every minute. - Legacy discovery jobs redirected to batch polling exit quietly when polling is paused or already queued, instead of marking the connection as errored. - Scheduled poll retries back off 15/30/60/60 seconds so a transient login or TLS timeout cannot suppress minute polling; manual syncs keep 15/60/180/300. - Polled units without a valid fix are counted in invalid_count but no longer quarantine the delivery or mark the run partial. Pushed deliveries still do. - Partial messages no longer replace an existing device internal_id with the external ID fallback. Dedicated telematics queues (opt-in, per instance) - TELEMATICS_BROADCAST_QUEUE routes device, vehicle and trailer location broadcasts created by telematics ingestion. Unset keeps the default queue. - SyncTelematicDevicesJob and TestTelematicConnectionJob follow TELEMATICS_POLL_QUEUE like polling already did. - docs/TELEMATICS_QUEUES.md covers worker setup, rollout, sizing and rollback. Tests - Regression tests for paused providers, redirect handling, scheduled backoff, no-fix accounting and queue routing; outdated Safee and AFAQY assertions updated to the new contracts. - Local run on the single default worker: 5 Safee sweeps of 93 units used 7 API requests, each run completed with 91 applied and 2 without a fix.
- Replace the Safee token-retry loop with an explicit single refresh so the unreachable "rejected the refreshed access token" throw is removed; a second 401 still fails as an unsuccessful response. - Cover Safee cursor/filter validation, data and token connection failures, static tokens without refresh credentials, and missing credentials. - Cover expired scheduled polls, manual polls releasing on a held poll lock, superseded manual jobs, stale connections in queueTelemetrySync, and malformed delivery checkpoints.
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #326 +/- ##
============================================
Coverage 100.00% 100.00%
- Complexity 11709 11887 +178
============================================
Files 581 582 +1
Lines 44307 44715 +408
============================================
+ Hits 44307 44715 +408
Flags with carried forward coverage won't be shown. Click here to find out more. ☔ View full report in Codecov by Harness. 🚀 New features to boost your workflow:
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Release work
last-staterequests (up to 1,000 vehicles each) through the shared durable ingestion pipeline, replacing three sequential enrichment requests per vehicleRetry-AfterhandlingSyncTelematicDevicesJobruns hand off to bounded pollinginvalid_countwithout quarantining deliveries or marking runs partialinternal_iddevice_eventsUUID lookup indexTELEMATICS_BROADCAST_QUEUE, andSyncTelematicDevicesJob/TestTelematicConnectionJobfollowingTELEMATICS_POLL_QUEUE; setup indocs/TELEMATICS_QUEUES.mdCommits
Validation
list-info, 5last-state), and each run completed with 91 applied and 2 vehicles without a fix.Deployment notes
device_eventsUUID lookup index).php artisan queue:restart) and reload Octane.docs/TELEMATICS_QUEUES.mdand start the workers before setting the queue variables.