MCPcopy Index your code
hub / github.com/coder/coder / GetWorkspaceAgentUsageStatsAndLabels

Method GetWorkspaceAgentUsageStatsAndLabels

coderd/database/querier.go:859–859  ·  view source on GitHub ↗
(ctx context.Context, createdAt time.Time)

Source from the content-addressed store, hash-verified

857 // `minute_buckets` could return 0 rows if there are no usage stats since `created_at`.
858 GetWorkspaceAgentUsageStats(ctx context.Context, createdAt time.Time) ([]GetWorkspaceAgentUsageStatsRow, error)
859 GetWorkspaceAgentUsageStatsAndLabels(ctx context.Context, createdAt time.Time) ([]GetWorkspaceAgentUsageStatsAndLabelsRow, error)
860 GetWorkspaceAgentsByInstanceID(ctx context.Context, authInstanceID string) ([]WorkspaceAgent, error)
861 GetWorkspaceAgentsByParentID(ctx context.Context, parentID uuid.UUID) ([]WorkspaceAgent, error)
862 GetWorkspaceAgentsByResourceIDs(ctx context.Context, ids []uuid.UUID) ([]WorkspaceAgent, error)

Implementers 5

sqlQueriercoderd/database/db.go
queryMetricsStorecoderd/database/dbmetrics/querymetrics
queriercoderd/database/dbauthz/dbauthz.go
MockStorecoderd/database/dbmock/dbmock.go
MockStoreMockRecordercoderd/database/dbmock/dbmock.go

Calls

no outgoing calls

Tested by 2

TestSystemFunctionsMethod · 0.52