Scope the opportunities read, and give the relay client timeouts

FixSecurityService
Shipped
August 7, 2026 at 2:49 AM UTC
Author
Kamo
Commit
a8bb666

/me/opportunities called reservationRepository.findAll() and filtered org and member in Java. That pulls every reservation on the platform — every tenant's — into one heap, on a page any member can refresh at will, and it gets slower for everybody as any single organization grows. Replaced with an org-and-agent-scoped finder in the repository. CommissionServiceClient used a bare RestTemplate, which has NO connect or read timeout. A downstream that accepts the connection and then stalls would hold the request thread indefinitely — and SecurityService issues every session on the platform from that pool. Read timeout sits above the downstream's own Stripe budget so a slow-but-working payout is not cut off by the hop in front of it.

All changes

Like what you see shipping?

Every one of these updates lands in your workspace automatically. Start free and watch it grow week after week.

Start Free ForeverView Pricing