diff --git a/ext/src/dll/dllmain.cc b/ext/src/dll/dllmain.cc index 1812377374..c9bb7e2683 100644 --- a/ext/src/dll/dllmain.cc +++ b/ext/src/dll/dllmain.cc @@ -9,6 +9,19 @@ #include #include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include + extern "C" BOOL WINAPI DllMain(HINSTANCE hInstance, DWORD dwReason, LPVOID lpReserved) { UNREFERENCED_PARAMETER(hInstance); @@ -17,3 +30,57 @@ extern "C" BOOL WINAPI DllMain(HINSTANCE hInstance, DWORD dwReason, LPVOID lpRes return TRUE; } + +extern std::unique_ptr test_otlp_http_trace() +{ + opentelemetry::exporter::otlp::OtlpHttpExporterOptions options; + options.url = "your endpoint"; + + auto e = opentelemetry::exporter::otlp::OtlpHttpExporterFactory::Create(options); + return e; +} + +extern std::unique_ptr test_otlp_http_metrics() +{ + opentelemetry::exporter::otlp::OtlpHttpMetricExporterOptions options; + options.url = "your endpoint"; + + auto e = opentelemetry::exporter::otlp::OtlpHttpMetricExporterFactory::Create(options); + return e; +} + +extern std::unique_ptr test_otlp_http_logs() +{ + opentelemetry::exporter::otlp::OtlpHttpLogRecordExporterOptions options; + options.url = "your endpoint"; + + auto e = opentelemetry::exporter::otlp::OtlpHttpLogRecordExporterFactory::Create(options); + return e; +} + +extern std::unique_ptr test_otlp_grpc_trace() +{ + opentelemetry::exporter::otlp::OtlpGrpcExporterOptions options; + options.endpoint = "your endpoint"; + + auto e = opentelemetry::exporter::otlp::OtlpGrpcExporterFactory::Create(options); + return e; +} + +extern std::unique_ptr test_otlp_grpc_metrics() +{ + opentelemetry::exporter::otlp::OtlpGrpcMetricExporterOptions options; + options.endpoint = "your endpoint"; + + auto e = opentelemetry::exporter::otlp::OtlpGrpcMetricExporterFactory::Create(options); + return e; +} + +extern std::unique_ptr test_otlp_grpc_logs() +{ + opentelemetry::exporter::otlp::OtlpGrpcLogRecordExporterOptions options; + options.endpoint = "your endpoint"; + + auto e = opentelemetry::exporter::otlp::OtlpGrpcLogRecordExporterFactory::Create(options); + return e; +}