From acef17ca6561ab03da299b4ce70535691db5837a Mon Sep 17 00:00:00 2001 From: j0nimost Date: Tue, 17 Oct 2023 06:48:39 +0300 Subject: [PATCH] preconfigure 4kb --- src/Kafa/Kafa.Stream.cs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/Kafa/Kafa.Stream.cs b/src/Kafa/Kafa.Stream.cs index 61f2507..66c1d78 100644 --- a/src/Kafa/Kafa.Stream.cs +++ b/src/Kafa/Kafa.Stream.cs @@ -81,7 +81,7 @@ public static async ValueTask WriteAsync(List entities, KafaOp { ArgumentNullException.ThrowIfNull(entities, nameof(entities)); var reflection = SetupOptions(options); - using var strWriter = new StringWriter(new StringBuilder()); + using var strWriter = new StringWriter(new StringBuilder(4096)); // 4Kb return await reflection.GetProperties(entities, strWriter); }