feat: API skeleton, SSE, staffing and tests
This commit is contained in:
1 parent
907164f972
commit
f284969a4b
14 files changed
+1355
-54
No files matched your search
@@ -15,7 +15,6 @@ import (
|
||||
"pulsecast/api/internal/model"
|
||||
"pulsecast/api/internal/scenario"
|
||||
"pulsecast/api/internal/sse"
|
||||
"pulsecast/api/internal/staffing"
|
||||
"pulsecast/api/internal/store"
|
||||
)
|
||||
|
||||
@@ -36,11 +35,11 @@ type Server struct {
|
||||
loc *time.Location
|
||||
now func() time.Time
|
||||
|
||||
mu sync.RWMutex
|
||||
sim map[string]map[string][]model.ForecastPoint // sensor -> horizon -> points
|
||||
simFor string // scenario the sim belongs to
|
||||
simGen int // invalidates staffing cache
|
||||
staffing map[string]model.StaffingResponse
|
||||
mu sync.RWMutex
|
||||
sim map[string]map[string][]model.ForecastPoint // sensor -> horizon -> points
|
||||
simFor string // scenario the sim belongs to
|
||||
simGen int // invalidates staffing cache
|
||||
staffing map[string]model.StaffingResponse
|
||||
}
|
||||
|
||||
// New builds a server. hub must be non-nil; main runs hub.Run.
|
||||
|
||||
Reference in new issue
Block a user