diff --git a/src/ServiceControl.Audit.Persistence.RavenDB/UnitOfWork/RavenAuditIngestionUnitOfWork.cs b/src/ServiceControl.Audit.Persistence.RavenDB/UnitOfWork/RavenAuditIngestionUnitOfWork.cs index abc554152a..eb19562dbc 100644 --- a/src/ServiceControl.Audit.Persistence.RavenDB/UnitOfWork/RavenAuditIngestionUnitOfWork.cs +++ b/src/ServiceControl.Audit.Persistence.RavenDB/UnitOfWork/RavenAuditIngestionUnitOfWork.cs @@ -35,7 +35,7 @@ public async Task RecordProcessedMessage(ProcessedMessage processedMessage, Read if (!body.IsEmpty) { await using var stream = new ReadOnlyStream(body); - var contentType = processedMessage.Headers.GetValueOrDefault(Headers.ContentType, "text/xml"); + var contentType = processedMessage.Headers.GetValueOrDefault(Headers.ContentType, "text/plain"); await bodyStorage.Store(processedMessage.Id, contentType, body.Length, stream, cancellationToken); } diff --git a/src/ServiceControl.Audit.Persistence.Tests/AuditTests.cs b/src/ServiceControl.Audit.Persistence.Tests/AuditTests.cs index 4d89044420..9dcffaee85 100644 --- a/src/ServiceControl.Audit.Persistence.Tests/AuditTests.cs +++ b/src/ServiceControl.Audit.Persistence.Tests/AuditTests.cs @@ -80,7 +80,7 @@ await IngestProcessedMessagesAudits( [Test] public async Task Can_roundtrip_message_body() { - string expectedContentType = "text/xml"; + string expectedContentType = "text/plain"; var unitOfWork = await StartAuditUnitOfWork(1); var body = new byte[100]; diff --git a/src/ServiceControl.Audit.Persistence/BodyStorageEnricher.cs b/src/ServiceControl.Audit.Persistence/BodyStorageEnricher.cs index c7794e30ba..be9e133bf8 100644 --- a/src/ServiceControl.Audit.Persistence/BodyStorageEnricher.cs +++ b/src/ServiceControl.Audit.Persistence/BodyStorageEnricher.cs @@ -21,7 +21,7 @@ public async ValueTask StoreAuditMessageBody(ReadOnlyMemory body, Processe return; } - var contentType = GetContentType(processedMessage.Headers, "text/xml"); + var contentType = GetContentType(processedMessage.Headers, "text/plain"); processedMessage.MessageMetadata.Add("ContentType", contentType); var stored = await TryStoreBody(body, processedMessage, bodySize, contentType, cancellationToken); diff --git a/src/ServiceControl.Audit.UnitTests/BodyStorage/BodyStorageEnricherTests.cs b/src/ServiceControl.Audit.UnitTests/BodyStorage/BodyStorageEnricherTests.cs index 87e1bbe9db..273b4f80fb 100644 --- a/src/ServiceControl.Audit.UnitTests/BodyStorage/BodyStorageEnricherTests.cs +++ b/src/ServiceControl.Audit.UnitTests/BodyStorage/BodyStorageEnricherTests.cs @@ -92,7 +92,7 @@ public async Task Should_store_body_in_metadata_when_below_large_object_heap_and [Headers.MessageId] = "someid", ["ServiceControl.Retry.UniqueMessageId"] = "someid", [Headers.ProcessingEndpoint] = "someendpoint", - [Headers.ContentType] = "text/xml" + [Headers.ContentType] = "text/plain" }; var message = new ProcessedMessage(headers, metadata); diff --git a/src/ServiceControl.Persistence.RavenDB/UnitOfWork/RavenRecoverabilityIngestionUnitOfWork.cs b/src/ServiceControl.Persistence.RavenDB/UnitOfWork/RavenRecoverabilityIngestionUnitOfWork.cs index cf6ee57a13..2351e78e3e 100644 --- a/src/ServiceControl.Persistence.RavenDB/UnitOfWork/RavenRecoverabilityIngestionUnitOfWork.cs +++ b/src/ServiceControl.Persistence.RavenDB/UnitOfWork/RavenRecoverabilityIngestionUnitOfWork.cs @@ -33,7 +33,7 @@ public Task RecordFailedProcessingAttempt( List groups) { var uniqueMessageId = context.Headers.UniqueId(); - var contentType = GetContentType(context.Headers, "text/xml"); + var contentType = GetContentType(context.Headers, "text/plain"); var bodySize = context.Body.Length; processingAttempt.MessageMetadata.Add("ContentType", contentType);