MCPcopy Create free account
hub / github.com/apache/arrow / MakeExporter

Function MakeExporter

cpp/src/arrow/telemetry/logging.cc:128–146  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

126};
127
128std::unique_ptr<otel::sdk::logs::LogRecordExporter> MakeExporter(
129 ExporterKind exporter_kind, std::ostream* ostream = nullptr) {
130 switch (exporter_kind) {
131 case ExporterKind::OSTREAM: {
132 return std::make_unique<otel::exporter::logs::OStreamLogRecordExporter>(*ostream);
133 } break;
134 case ExporterKind::OTLP_HTTP: {
135 namespace otlp = otel::exporter::otlp;
136 otlp::OtlpHttpLogRecordExporterOptions options{};
137 return std::make_unique<otlp::OtlpHttpLogRecordExporter>(options);
138 } break;
139 case ExporterKind::OTLP_OSTREAM: {
140 return std::make_unique<OtlpOStreamLogRecordExporter>(ostream);
141 } break;
142 default:
143 break;
144 }
145 return nullptr;
146}
147
148std::unique_ptr<otel::sdk::logs::LogRecordExporter> MakeExporterFromEnv(
149 const OtelLogExporterOptions& exporter_options) {

Callers 1

MakeExporterFromEnvFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected