Skip to content

Commit

Permalink
Remove simple json
Browse files Browse the repository at this point in the history
  • Loading branch information
andreasohlund committed Feb 19, 2024
1 parent 0526ed2 commit 38bdaed
Show file tree
Hide file tree
Showing 3 changed files with 2 additions and 2,171 deletions.
45 changes: 0 additions & 45 deletions src/NServiceBus.Heartbeat/MessageSerializationStrategy.cs

This file was deleted.

7 changes: 2 additions & 5 deletions src/NServiceBus.Heartbeat/ServiceControlBackend.cs
Original file line number Diff line number Diff line change
Expand Up @@ -2,12 +2,11 @@
{
using System;
using System.Collections.Generic;
using System.Text;
using System.Text.Json;
using System.Threading;
using System.Threading.Tasks;
using Performance.TimeToBeReceived;
using Routing;
using SimpleJson;
using Transport;

class ServiceControlBackend
Expand All @@ -26,7 +25,7 @@ public Task Send(object messageToSend, TimeSpan timeToBeReceived, IMessageDispat

internal static byte[] Serialize(object messageToSend)
{
return Encoding.UTF8.GetBytes(SimpleJson.SerializeObject(messageToSend, serializerStrategy));
return JsonSerializer.SerializeToUtf8Bytes(messageToSend);
}

Task Send(byte[] body, string messageType, TimeSpan timeToBeReceived, IMessageDispatcher dispatcher, CancellationToken cancellationToken)
Expand All @@ -52,7 +51,5 @@ Task Send(byte[] body, string messageType, TimeSpan timeToBeReceived, IMessageDi
readonly string sendIntent = MessageIntent.Send.ToString();
string destinationQueue;
readonly ReceiveAddresses receiveAddresses; // note that ReceiveAddresses will be null on send-only endpoints

static IJsonSerializerStrategy serializerStrategy = new MessageSerializationStrategy();
}
}
Loading

0 comments on commit 38bdaed

Please sign in to comment.