Langfuse production readiness checklist and verification.
Use when preparing to deploy Langfuse to production,
validating production configuration, or auditing existing setup.
Trigger with phrases like "langfuse production", "langfuse prod ready",
"deploy langfuse", "langfuse checklist", "langfuse go live".
Comprehensive checklist for deploying Langfuse observability to production with verified configuration, error handling, graceful shutdown, monitoring, and a pre-deployment verification script.
Prerequisites
Development and staging testing completed
Production Langfuse project created with separate API keys
Secret management solution in place
Production Configuration
Recommended SDK Settings
// v4+ Production Config
import { LangfuseSpanProcessor } from "@langfuse/otel";
import { NodeSDK } from "@opentelemetry/sdk-node";
const processor = new LangfuseSpanProcessor({
exportIntervalMillis: 5000, // Flush every 5s
maxExportBatchSize: 50, // Batch size
maxQueueSize: 2048, // Buffer limit
});
const sdk = new NodeSDK({ spanProcessors: [processor] });
sdk.start();
// Graceful shutdown on all signals
for (const signal of ["SIGTERM", "SIGINT", "SIGUSR2"]) {
process.on(signal, async () => {
await sdk.shutdown();
process.exit(0);
});
}
// v3 Legacy Production Config
import { Langfuse } from "langfuse";
const langfuse = new Langfuse({
flushAt: 25, // Balance between latency and efficiency
flushInterval: 5000, // 5 second flush interval
requestTimeout: 15000, // 15s timeout
enabled: true, // Explicitly enable
});
process.on("beforeExit", () => langfuse.shutdownAsync());
process.on("SIGTERM", () => langfuse.shutdownAsync().then(() => process.exit(0)));