Device reliability
Device Control When the Result Is Uncertain
A timed-out unlock can still be in flight. I separated requested authorization, vendor acceptance and active permission so retries and background locking would not contradict each other.
Senior AI Engineer · M.S. Computer Science, Tsinghua University · See the products I built
In this article · 5 sections
The engineering decisions
- Persist pending authorization before dispatch and activate it only after the required confirmation.
- Coordinate manual control, booking control and idle locking through the same lease boundary.
- Retry explicit authentication rejection narrowly, and treat a timeout as an uncertain outcome.
Persist intent before claiming success
The first authorization wrote pending state, dispatched the command and became active only after the vendor success and final persistence step. A failed renewal retained the previous expiry instead of extending it or revoking a still-valid authorization. Failures in the final write could not create a valid idle-lock exemption.
Manual Lock revoked authorization before contacting the vendor, allowing a later idle inspection to retry if that command failed. A normal booking enable consumed the old manual authorization atomically with device ownership. Ending the booking could not revive an earlier administrative permission.
Protect the physical target, not just a row
The authorization was bound to organization, store, bay, physical control identity, stable venue identity and server region. Rebinding equipment or moving it between regions could not carry the old permission along. Manual control, booking enable and idle inspection shared a short device lease.
A timeout has a different meaning from a rejected request. The command may still arrive late. The implementation retained short isolation for an unknown result to reduce the chance that a late unlock collided with a new session. It did not label the authorization active merely because a network call had started.
Handle the vendor’s two rejection envelopes
One production failure returned HTTP 200 while the business response contained an authentication rejection. The old client refreshed only after HTTP 401 or 403. I recognized both envelopes and allowed at most one reauthentication and resend after an explicit rejection.
That resend still rechecked device ownership and lease authority. Timeouts, invalid JSON, general business failures and server errors did not gain a blanket retry. Later September records identified additional lease-release failure paths and kept those follow-up changes separately scoped rather than treating a merged fix as already deployed.
Separate service evidence from a screen observation
The September authorization work included SQL and simulated-provider tests for expiry, failed renewals, scope changes, lease loss and booking takeover. The recorded vendor contract covered business-level rejection and bounded retry. Production reads confirmed that an existing authorization suppressed idle locking while other devices continued to be inspected.
That is evidence about server-side behavior. The release notes retained physical simulator restart and display behavior as field observations to be checked separately. A reliable account of device engineering keeps those two kinds of evidence distinct.
Project context and evidence
Written from my September 2026 administrator screen-authorization and vendor-authentication repair records. Public links below support the product and attribution context. Internal project records are summarized, with customer records, credentials, and employer source code omitted.
- GolfJoy Play ↗
Public platform context. Acceptance and release scope are stated in the article.
- GolfJoy engineering case study ↗
Public product interfaces and attribution for the delivered projects.


