import { literalUnion } from "../../shared/src/valita.js";
import { number } from "@badrap/valita";
const logLevel = literalUnion("debug", "info", "warn", "error");
const logOptions = {
  level: logLevel.default("info"),
  format: {
    type: literalUnion("text", "json").default("text"),
    desc: [
      `Use {bold text} for developer-friendly console logging`,
      `and {bold json} for consumption by structured-logging services`
    ]
  },
  slowRowThreshold: {
    type: number().default(2),
    desc: [
      `The number of ms a row must take to fetch from table-source before it is considered slow.`
    ]
  },
  slowHydrateThreshold: {
    type: number().default(100),
    desc: [
      `The number of milliseconds a query hydration must take to print a slow warning.`
    ]
  },
  ivmSampling: {
    type: number().default(5e3),
    desc: [
      `How often to collect IVM metrics. 1 out of N requests will be sampled where N is this value.`
    ]
  }
};
export {
  logLevel,
  logOptions
};
//# sourceMappingURL=log-options.js.map
