-
Notifications
You must be signed in to change notification settings - Fork 65
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[BUG] Cannot write log via Elastic.Serilog.Sinks #463
Comments
@AndriiDzendzia, I suspect this may be due to changes we've made in Transport, which we have yet to pull into this library. Do you reference Elastic.Transport directly or via Elastic.Clients.Elasticsearch? If so, can you confirm which versions of those packages you have referenced? |
Firstly, it was Elastic.Transport 0.5.2 via Elastic.Clients.Elasticsearch 8.16.0. Then, I updated it to 8.16.1 and 0.5.5, and both are installed directly. |
Ah, okay, thanks for confirming. We'll need to publish an update to this library, taking a dependency on 0.5.5. Until then, can you stick with 8.16.0. |
- Updated Elastic.Clients.Elasticsearch - Updated Elastic.Ingest.Elasticsearch - Updated Microsoft.Extensions.Hosting in examples Closes #463
@AndriiDzendzia Hopefully, 8.12.3 should fix this issue. |
@stevejgordon Yeah, it works. Great thanks) |
ECS integration/library project(s) (e.g. Elastic.CommonSchema.Serilog): Elastic.Serilog.Sinks 8.12.2
ECS schema version (e.g. 1.4.0): 8.12.2
ECS .NET assembly version (e.g. 1.4.2):
Elasticsearch version (if applicable): 8.16.0
.NET framework / OS: 8
Description of the problem, including expected versus actual behavior:
Observed an exception while writing to [data stream]
Steps to reproduce:
SelfLog.Enable(Console.Error);
services.AddSerilog((services, lc) => lc
.WriteTo.Elasticsearch(new ElasticsearchSinkOptions(services.GetService()!.Transport)
{
BootstrapMethod = BootstrapMethod.Failure,
IlmPolicy = "logs-dotnet",
DataStream = new DataStreamName("logs", "dotnet", "quartz")
})
.Enrich.FromLogContext()
.MinimumLevel.Information());
Then in console, you will get the following:
The text was updated successfully, but these errors were encountered: