elastic / ecs-dotnet

https://www.elastic.co/guide/en/ecs-logging/dotnet/current/setup.html
Apache License 2.0
114 stars 58 forks source link

[BUG] Cannot send logs to https://server/subpath #334

Open ggercman opened 1 year ago

ggercman commented 1 year ago

ECS integration/library project(s) (e.g. Elastic.CommonSchema.Serilog): Elastic.Serilog.Sinks

ECS .NET assembly version (e.g. 1.4.2): 8.6.1

.NET framework / OS: dotnet 7

Description of the problem, including expected versus actual behavior: Logs are sent to root url, subpath is ignored.

Steps to reproduce:

  1. Set elastic search under reverse proxy with subpath, for example https://server/elastic => http://localhost:9200
  2. Configure serilog to send logs to https://server/elastic (as in documentation https://www.elastic.co/guide/en/ecs-logging/dotnet/current/serilog-data-shipper.html)
  3. observe that logs are sent using POST to https://server/logs-console-example-demo/_bulk?filt... subpath is ignored.