Skip to content
This repository was archived by the owner on Jun 1, 2024. It is now read-only.

Commit 2750db4

Browse files
oscarmorasumivano
authored andcommitted
Format stacktrace as array (#233)
* Github releases added to yaml * Create new release * fix title of changelog (#211) * Added FormatStackTraceAsArray option to write StackTrace as an array * Added unit tests, minor code-style changes * Fix #232 Pass flag formatStackTraceAsArray to base class * Fix propertuy comment
1 parent f9f8077 commit 2750db4

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

src/Serilog.Formatting.Elasticsearch/ElasticsearchJsonFormatter.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -70,8 +70,8 @@ public class ElasticsearchJsonFormatter : DefaultJsonFormatter
7070
/// <param name="serializer">Inject a serializer to force objects to be serialized over being ToString()</param>
7171
/// <param name="inlineFields">When set to true values will be written at the root of the json document</param>
7272
/// <param name="renderMessageTemplate">If true, the message template will be rendered and written to the output as a
73-
/// <param name="formatStackTraceAsArray">If true, splits the StackTrace by new line and writes it as a an array of strings</param>
7473
/// property named RenderedMessageTemplate.</param>
74+
/// <param name="formatStackTraceAsArray">If true, splits the StackTrace by new line and writes it as a an array of strings</param>
7575
public ElasticsearchJsonFormatter(
7676
bool omitEnclosingObject = false,
7777
string closingDelimiter = null,

src/Serilog.Formatting.Elasticsearch/ExceptionAsObjectJsonFormatter.cs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -51,7 +51,7 @@ public ExceptionAsObjectJsonFormatter(bool omitEnclosingObject = false,
5151
IElasticsearchSerializer serializer = null,
5252
bool inlineFields = false,
5353
bool formatStackTraceAsArray = false)
54-
: base(omitEnclosingObject, closingDelimiter, renderMessage, formatProvider, serializer, inlineFields, formatStackTraceAsArray)
54+
: base(omitEnclosingObject, closingDelimiter, renderMessage, formatProvider, serializer, inlineFields, true, formatStackTraceAsArray)
5555
{
5656
}
5757

0 commit comments

Comments
 (0)