← Back to Pull requests

v2.1.0 rc1 #48

Open
unknown opened this pull request with 523 lines diff across 6 files
View on GitHub
unknown unknown commented on Oct 29, 2026 08:13 UTC
Author

Summary

Prepares Open Match Core (om-core) v2.1.0-rc1, improving replicated ticket cache throughput and replication latency, hardening Redis Streams and in-memory state replicators, tightening gRPC/HTTP RPC error and streaming contracts, and aligning Cloud Run / GKE deployment defaults and observability for production workloads.

Key Changes

  • Replicated Ticket Cache & State Replicators (internal/statestore/)

  • - Adds a ActiveTickets index for lock-free pool snapshots and replaces full-map TTL scans with min-heap expiration.
    - Adds a cold-start replication catch-up barrier (WaitForCatchUp) and event-driven watermark notifications (WaitForDeactivation). Replaced 100ms polling sleeps.
    - Supports opt-in request coalescing and Redis Stream packing (OM_CACHE_PACK_TICKET_STATE_UPDATES), faster expiration by moving to XTRIM ... MINID ~, improved Redis socket timeouts, and cleaner Close().
  • RPC Semantics, 4 MiB Chunking & MMF Auth (main.go, internal/mmfauth/)

  • - Improves ChunkedMmfRunRequest message chunking size estimation and correctly closes the client send direction (CloseSend()).
    - All StreamedMmfResponse are now forwarded (including ticketless responses), adds Match.Extensions for error reporting (invalid_ticket_ids, deactivation_failed_ticket_ids, deactivation_timeout, reading all of these is optional so existing matchmakers do not have to adopt them), and surfaces per-MMF failures using google.rpc.ErrorInfo (MMF_FAILURE).
    - Returns per-ticket google.rpc.BadRequest violations on partial ActivateTickets / DeactivateTickets failures so callers can retry only failed ticket updates.
    - Fixes concurrency-safe, per-audience OIDC ID token caching with single-flight refresh on Unauthenticated / PermissionDenied for https:// MMFs. These now work as intended.
  • Server Lifecycle, Config Validation & Filtering (server.go, internal/config/, internal/filter/)

  • - Adds gRPC panic recovery interceptors, HTTP ReadHeaderTimeout, and bounded graceful shutdown across gRPC, HTTP, OTel, and state replicators. These are largely just code hygiene, as 'clean shutdown' of a matchmaking service is largely an academic exercise.
    - Added a few v2.1.0 Viper config vars. Now enforces positive integer bounds on channel capacities, batch limits, and ticker intervals.
    - Fixes CreationTimeFilter handling for nil filters, half-open (Start-only / End-only) bounds, and tickets missing creation_time. These should all work as intended now.
  • Observability & Deployment Hardening (metrics.go, deploy/)

  • - Moved some Core and Cache OpenTelemetry metrics to sub-millisecond histogram buckets to more accurately reflect the metrics being recorded. Fixed a potential unbounded attribute cardinality in one of the metrics.
    - Changes some default Cloud Run configs to better reflect the reality of matchmaking: use Gen2 Cloud Run, --no-cpu-throttling, --min-instances=2, --ingress=internal
    - Added another config path for the OTel Collector sidecar image, used by the latest Google Cloud OTel image.
  • Toolchain, Documentation & Testing

  • - Upgrades Go to 1.26.9 and updates module dependencies.
    - Updates English and Japanese documentation (README, architecture, metrics, FAQ, development, and migration guides), and expands unit, concurrency/race, and benchmark test suites to cover some of the fixes above.

    Compatibility & Rollout Notes

  • Wire Compatibility: proto/api.proto contains documentation comment updates only; existing v2.0.x gRPC and HTTP clients remain wire-compatible. You don't need to re-compile your protocol buffers.

  • Packed Updates backwards compatibility: OM_CACHE_PACK_TICKET_STATE_UPDATES feature flag defaults to false, which is backwards compatible with the state storage format for v2.0.x om-core. Setting OM_CACHE_PACK_TICKET_STATE_UPDATES=true compacts the state storage format and should speed up state replication under load. Make sure to move all om-core replicas in your environment are using a version greater than v2.1.0 when enabling OM_CACHE_PACK_TICKET_STATE_UPDATES=true.
  • Diff: 523 lines (+392 / -131) across 6 files Reviewer: igooch Review duration: 23419m
    All Vouch review confidence checks passed
    Residual risk 0.25 = Change Risk (0.48) × (1 − Review Confidence (0.47)). Review depth and reviewer attention state are adequate.
    Model 1 · Change Risk (XGBoost)
    Score: 0.48 · 523 lines diff across 6 files
    0.48
    Model 2 · Review Depth (DistilBERT)
    Depth Score: 0.02 · 1 substantive comment(s)
    0.02
    Model 3 · Review Timing & Attention
    Session adequacy: 100% · Reviewer familiarity: 35%
    46%
    Bedrock Claude 3 · Risk Narration
    (disconnected)
    Groq
    Groq Risk Narration
    AWS Bedrock is currently disconnected. Generate high-confidence PR triage narration on-demand using Groq.
    Model 1 · Change Risk Attribution
    SHAP Weights
    Diff Size diff_size
    0.375
    Shallow Review Depth shallow_review_depth
    0.344
    Real PR Conversation Timeline
    1 comments
    "Review active on #48"
    general weight: 0.35
    Reviewers
    Assignees
    Unassigned
    Labels
    risk: low confidence: 46.7% reviewed
    Vouch Risk Breakdown
    AI-powered review risk analysis
    Change Risk
    Change Risk · Model 1 (XGBoost)
    Predicted defect probability (0.00–1.00) based on diff churn, modified sensitive files, and author risk history.
    Score: 47.8% (MEDIUM) · Higher = larger blast radius
    47.8%
    Review Confidence
    Review Confidence · Models 2 & 3
    Scrutiny score (0.00–1.00) combining DistilBERT semantic review depth with reviewer familiarity and session dwell time.
    Score: 46.7% · Lower = rushed or shallow review
    46.7%
    Residual Risk
    Residual Risk · Core Equation
    Residual = Change × (1 − Confidence)
    Unmitigated risk surviving review. ≥ 0.65 triggers an automated re-queue to protect production.
    Score: 25.5% · Safe to merge
    25.5%