(ctx context.Context, workspace string)
| 76 | } |
| 77 | |
| 78 | func workspaceObservabilityFilter(ctx context.Context, workspace string) (catalogFilter, bool, error) { |
| 79 | workspaceRoot := canonicalWorkspaceRoot(workspace) |
| 80 | if workspaceRoot == "" { |
| 81 | return catalogFilter{}, false, nil |
| 82 | } |
| 83 | identity, err := aghworkspace.EnsureIdentity(ctx, workspaceRoot) |
| 84 | if err != nil { |
| 85 | return catalogFilter{}, false, fmt.Errorf( |
| 86 | "memory: resolve workspace identity for %q: %w", |
| 87 | workspaceRoot, |
| 88 | err, |
| 89 | ) |
| 90 | } |
| 91 | return catalogFilter{ |
| 92 | scope: memcontract.ScopeWorkspace, |
| 93 | workspaceRoot: workspaceRoot, |
| 94 | workspaceID: identity.WorkspaceID, |
| 95 | }, true, nil |
| 96 | } |
| 97 | |
| 98 | func (s *Store) healthSources(ctx context.Context, workspaces []string) ([]observabilitySource, error) { |
| 99 | sources, err := s.observabilitySources(ctx, workspaces) |
no test coverage detected