mirror of
https://github.com/jcreek/CosmicClash.git
synced 2026-09-11 08:23:45 +00:00
feat: add authenticated matchmaking event stream
This commit is contained in:
@@ -72,6 +72,8 @@ type Service struct {
|
||||
RankedProfiles map[string]domain.RankedProfile
|
||||
TierPolicy domain.TierPolicy
|
||||
proposalMu sync.Mutex
|
||||
eventsMu sync.Mutex
|
||||
events *eventHub
|
||||
}
|
||||
|
||||
func (s *Service) Handler() http.Handler {
|
||||
@@ -84,6 +86,7 @@ func (s *Service) Handler() http.Handler {
|
||||
mux.HandleFunc("/v1/assignments/", s.assignment)
|
||||
mux.HandleFunc("/v1/profile/ranked", s.rankedProfile)
|
||||
mux.HandleFunc("/v1/probes/", s.probe)
|
||||
mux.HandleFunc("/v1/events", s.controlPlaneEvent)
|
||||
// The public contract is served below /api/v1. Keep the original /v1
|
||||
// routes for the Godot client while exposing the documented names.
|
||||
mux.HandleFunc("/api/v1/session/steam", s.steamSession)
|
||||
@@ -92,6 +95,7 @@ func (s *Service) Handler() http.Handler {
|
||||
mux.HandleFunc("/api/v1/queue/tickets/", s.contractQueueMutation)
|
||||
mux.HandleFunc("/api/v1/proposals/", s.contractProposalMutation)
|
||||
mux.HandleFunc("/api/v1/assignments/", s.contractAssignment)
|
||||
mux.HandleFunc("/api/v1/events", s.controlPlaneEvent)
|
||||
return mux
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user