-
Notifications
You must be signed in to change notification settings - Fork 6.6k
Add T3CODE_OTLP_PROTOCOL to allow protobuf protocol #11224
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from all commits
30e45c9
5ef68de
7115792
6ceb141
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1,5 +1,5 @@ | ||
| import * as NetService from "@t3tools/shared/Net"; | ||
| import { OtlpHeadersFromString } from "@t3tools/shared/observability"; | ||
| import { OtlpHeadersFromString, OtlpProtocol } from "@t3tools/shared/observability"; | ||
| import { parsePersistedServerObservabilitySettings } from "@t3tools/shared/serverSettings"; | ||
| import { DesktopBackendBootstrap, PortSchema } from "@t3tools/contracts"; | ||
| import * as Config from "effect/Config"; | ||
|
|
@@ -104,6 +104,9 @@ const EnvServerConfig = Config.all({ | |
| Config.option, | ||
| Config.map(Option.getOrUndefined), | ||
| ), | ||
| otlpProtocol: Config.schema(OtlpProtocol, "T3CODE_OTLP_PROTOCOL").pipe( | ||
| Config.withDefault("http/json"), | ||
| ), | ||
| mode: Config.schema(ServerConfig.RuntimeMode, "T3CODE_MODE").pipe( | ||
| Config.option, | ||
| Config.map(Option.getOrUndefined), | ||
|
|
@@ -393,6 +396,7 @@ export const resolveServerConfig = ( | |
| otlpExportIntervalMs: env.otlpExportIntervalMs, | ||
| otlpServiceName: env.otlpServiceName, | ||
| otlpHeaders: env.otlpHeaders, | ||
|
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. 🔒 Security & Privacy | 🛡️ Analyzed with Security Review | 🟠 Major | 🏗️ Heavy lift 🧩 Analysis chain🏁 Script executed: #!/bin/bash
set -eu
printf '%s\n' '--- config.ts relevant range ---'
sed -n '360,430p' apps/server/src/cli/config.ts
printf '%s\n' '--- Observability.ts ---'
cat -n apps/server/src/observability/Layers/Observability.ts | sed -n '1,125p'
printf '%s\n' '--- http.ts relevant range ---'
cat -n apps/server/src/http.ts | sed -n '315,370p'
printf '%s\n' '--- OTLP definitions and consumers ---'
rg -n -C 3 'otlp(TracesUrl|MetricsUrl|Headers)|OTLP|otlp' apps/server/src packages/shared/src --glob '*.ts' | head -n 260Repository: pingdotgg/t3code Length of output: 26355 🏁 Script executed: #!/bin/bash
set -eu
sed -n '360,430p' apps/server/src/cli/config.ts
cat -n apps/server/src/observability/Layers/Observability.ts | sed -n '1,125p'
cat -n apps/server/src/http.ts | sed -n '315,370p'
rg -n -C 3 'otlp(TracesUrl|MetricsUrl|Headers)|OTLP|otlp' apps/server/src packages/shared/src --glob '*.ts' | head -n 260Repository: pingdotgg/t3code Length of output: 26652 Sensitive Data Exposure Reachability: Internal Reject credential-bearing OTLP headers for non-loopback HTTP endpoints. 📍 Affects 3 files
🤖 Prompt for AI Agents |
||
| otlpProtocol: env.otlpProtocol, | ||
|
bahlo marked this conversation as resolved.
|
||
| mode, | ||
| port, | ||
| cwd, | ||
|
|
||
Uh oh!
There was an error while loading. Please reload this page.