diff --git a/src/ServiceControl.Audit.Persistence.RavenDB/UnitOfWork/RavenAuditIngestionUnitOfWork.cs b/src/ServiceControl.Audit.Persistence.RavenDB/UnitOfWork/RavenAuditIngestionUnitOfWork.cs index 9dfd2bace8..1fd20c31d3 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); } diff --git a/src/ServiceControl.Audit.Persistence.Tests/AuditTests.cs b/src/ServiceControl.Audit.Persistence.Tests/AuditTests.cs index eac4e83e87..697da89190 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 e5a3f57ebf..b2c108dd18 100644 --- a/src/ServiceControl.Audit.Persistence/BodyStorageEnricher.cs +++ b/src/ServiceControl.Audit.Persistence/BodyStorageEnricher.cs @@ -20,7 +20,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); diff --git a/src/ServiceControl.Audit.UnitTests/BodyStorage/BodyStorageEnricherTests.cs b/src/ServiceControl.Audit.UnitTests/BodyStorage/BodyStorageEnricherTests.cs index 85fbf642a5..88c2b09fa1 100644 --- a/src/ServiceControl.Audit.UnitTests/BodyStorage/BodyStorageEnricherTests.cs +++ b/src/ServiceControl.Audit.UnitTests/BodyStorage/BodyStorageEnricherTests.cs @@ -90,7 +90,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);