File tree Expand file tree Collapse file tree
apps/backend/src/bootstrap
infra/observability/templates Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -3,8 +3,7 @@ import http from "http";
33
44import { Config } from "../../../../packages/common/src/utils/config" ;
55import log from "../lib/logger" ;
6- import cacheRoutes from "../modules/cache/routes" ;
7- import loaders , { loadCacheWarmingDependencies } from "./loaders" ;
6+ import loaders from "./loaders" ;
87
98export default async ( config : Config ) => {
109 const app = express ( ) ;
@@ -56,6 +55,7 @@ export default async (config: Config) => {
5655 ) ;
5756} ;
5857
58+ /**
5959// Cache warming server bootstrap
6060export async function bootstrapCacheWarmingServer(config: Config) {
6161 const app = express();
@@ -72,3 +72,4 @@ export async function bootstrapCacheWarmingServer(config: Config) {
7272 "Cache warming server ready"
7373 );
7474}
75+ **/
Original file line number Diff line number Diff line change @@ -183,6 +183,24 @@ function createOtelPlugin(): ApolloServerPlugin {
183183 } ;
184184}
185185
186+ /**
187+
188+ * Extracts the first query name from a GraphQL operation.
189+ * For example, if the query is "query { catalog(...) { ... } }", this returns "catalog".
190+ *
191+ * @param operation - The parsed GraphQL operation from the request context
192+ * @returns The name of the first query field, or null if not found
193+
194+ function getOperationName(
195+ operation: OperationDefinitionNode | undefined
196+ ): string | null {
197+ const firstSelection = operation?.selectionSet?.selections?.[0];
198+ if (firstSelection && "name" in firstSelection)
199+ return firstSelection.name.value;
200+ return null;
201+ }
202+ */
203+
186204const SESSION_COOKIE_NAME = "bt.sid" ;
187205
188206function getSessionCacheIdFromCookie (
Original file line number Diff line number Diff line change @@ -57,6 +57,7 @@ metadata:
5757 labels :
5858 {{- include "bt-observability.grafanaLabels" . | nindent 4 }}
5959spec :
60+ storageClassName : manual
6061 accessModes :
6162 - ReadWriteOnce
6263 resources :
Original file line number Diff line number Diff line change @@ -63,6 +63,7 @@ metadata:
6363 labels :
6464 {{- include "bt-observability.lokiLabels" . | nindent 4 }}
6565spec :
66+ storageClassName : manual
6667 accessModes :
6768 - ReadWriteOnce
6869 resources :
Original file line number Diff line number Diff line change @@ -31,6 +31,7 @@ metadata:
3131 labels :
3232 {{- include "bt-observability.prometheusLabels" . | nindent 4 }}
3333spec :
34+ storageClassName : manual
3435 accessModes :
3536 - ReadWriteOnce
3637 resources :
Original file line number Diff line number Diff line change 1+ apiVersion : v1
2+ kind : PersistentVolume
3+ metadata :
4+ name : prometheus-pv
5+ spec :
6+ storageClassName : manual
7+ claimRef :
8+ name : prometheus-data
9+ namespace : bt
10+ capacity :
11+ storage : {{.Values.prometheus.storage.size}}
12+ accessModes :
13+ - ReadWriteOnce
14+ hostPath :
15+ path : /data/prometheus
16+
17+ ---
18+
19+ apiVersion : v1
20+ kind : PersistentVolume
21+ metadata :
22+ name : tempo-pv
23+ spec :
24+ storageClassName : manual
25+ claimRef :
26+ name : tempo-data
27+ namespace : bt
28+ capacity :
29+ storage : {{.Values.tempo.storage.size}}
30+ accessModes :
31+ - ReadWriteOnce
32+ hostPath :
33+ path : /data/tempo
34+
35+ ---
36+
37+ apiVersion : v1
38+ kind : PersistentVolume
39+ metadata :
40+ name : loki-pv
41+ spec :
42+ storageClassName : manual
43+ claimRef :
44+ name : loki-data
45+ namespace : bt
46+ capacity :
47+ storage : {{.Values.loki.storage.size}}
48+ accessModes :
49+ - ReadWriteOnce
50+ hostPath :
51+ path : /data/loki
52+
53+
54+ ---
55+
56+ apiVersion : v1
57+ kind : PersistentVolume
58+ metadata :
59+ name : grafana-pv
60+ spec :
61+ storageClassName : manual
62+ claimRef :
63+ name : grafana-data
64+ namespace : bt
65+ capacity :
66+ storage : {{.Values.grafana.storage.size}}
67+ accessModes :
68+ - ReadWriteOnce
69+ hostPath :
70+ path : /data/grafana
Original file line number Diff line number Diff line change @@ -60,6 +60,7 @@ metadata:
6060 labels :
6161 {{- include "bt-observability.tempoLabels" . | nindent 4 }}
6262spec :
63+ storageClassName : manual
6364 accessModes :
6465 - ReadWriteOnce
6566 resources :
You can’t perform that action at this time.
0 commit comments