Serilog.Sinks.AmazonS3 icon indicating copy to clipboard operation
Serilog.Sinks.AmazonS3 copied to clipboard

AmazonS3 is not able to read the formatter parameter.

Open krishamagar opened this issue 2 years ago • 0 comments

var logger = new LoggerConfiguration()
     .WriteTo.AmazonS3(
                formatter:new CompactJsonFormatter(),
                path,
                bucketName,
                Amazon.RegionEndpoint.APSouth1,
                awsAccessKey,
                awsSecretKey,
                LogEventLevel.Information,
                "{Timestamp:yyyy-MM-dd HH:mm:ss.fff zzz} [{Level:u3}] {Message:lj}{NewLine}{Exception}",
                new CultureInfo("en-US"),
                levelSwitch,
                Serilog.Sinks.AmazonS3.RollingInterval.Minute,
                Encoding.Unicode,
                e => Console.WriteLine($"An error occurred in my sink: {e.Message}"),
                bucketPath,
                eagerlyEmitFirstEvent:false
                )

                           .CreateLogger();

krishamagar avatar Sep 07 '23 08:09 krishamagar