Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
14 commits
Select commit Hold shift + click to select a range
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -307,8 +307,8 @@ public interface IOrderBenchmarkProtocol
{
}

[AkkaSerializer(Name = "order-benchmark", SerializerId = 120001)]
public sealed partial class OrderBenchmarkSerializer : MessagePackSerializer<IOrderBenchmarkProtocol>
[AkkaSerializer<IOrderBenchmarkProtocol>("order-benchmark", 120001)]
public sealed partial class OrderBenchmarkSerializer : AkkaSerializer
{
public static partial SerializerRegistration CreateRegistration();
}
Expand All @@ -317,8 +317,8 @@ public interface IEnvelopeBenchmarkProtocol
{
}

[AkkaSerializer(Name = "envelope-benchmark", SerializerId = 120002)]
public sealed partial class EnvelopeBenchmarkSerializer : MessagePackSerializer<IEnvelopeBenchmarkProtocol>
[AkkaSerializer<IEnvelopeBenchmarkProtocol>("envelope-benchmark", 120002)]
public sealed partial class EnvelopeBenchmarkSerializer : AkkaSerializer
{
public static partial SerializerRegistration CreateRegistration();
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ namespace RemotePingPong.RealPayload.V2
{
/// <summary>
/// Protocol marker for the "real payload" (`--payload real`) benchmark message, MessagePack/V2 arm.
/// Only used to satisfy <see cref="MessagePackSerializer{TProtocol}"/>'s generic parameter and
/// Only used to satisfy <see cref="AkkaSerializerAttribute{TProtocol}"/>'s generic parameter and
/// <see cref="RealBenchmarkSerializer.CreateRegistration"/>'s protocol-type registration -- the
/// harness's actual HOCON wiring binds directly on <see cref="RealBenchmarkMessage"/> (see
/// RemotePingPong.Program.RealPayloadSerializationConfig), so this interface has no runtime
Expand Down Expand Up @@ -121,8 +121,8 @@ public sealed record Reading(
/// range (0-40, see akka.conf) and the ids used elsewhere in this repo (e.g. Artery control's 23,
/// the V2 test suite's ~120101-120202) to avoid any collision with a real Akka.NET serializer.
/// </remarks>
[AkkaSerializer(Name = "real-benchmark-v2", SerializerId = 987001)]
internal sealed partial class RealBenchmarkSerializer : MessagePackSerializer<IRealBenchmarkMessage>
[AkkaSerializer<IRealBenchmarkMessage>("real-benchmark-v2", 987001)]
internal sealed partial class RealBenchmarkSerializer : AkkaSerializer
{
/// <summary>
/// Generated by <c>Akka.Serialization.V2.Generators.AkkaSerializerGenerator</c>. Not used by
Expand Down
11 changes: 6 additions & 5 deletions src/core/Akka.Remote/Artery/ArteryControlMessageSerializer.cs
Original file line number Diff line number Diff line change
Expand Up @@ -42,18 +42,19 @@ namespace Akka.Remote.Artery
/// <para>
/// <see cref="Address"/> is a core <c>Akka.Actor</c> type this change may not annotate with
/// <c>[AkkaSerializable]</c>; it is instead handled via the built-in <see cref="AddressFormatter"/>
/// escape hatch (<see cref="AkkaSerializerFormatterAttribute"/>), which produces the identical
/// 4-element-array wire format the old hand-rolled <c>WriteAddress</c>/<c>ReadAddress</c> used.
/// escape hatch (<c>[AkkaSerializerFormatter&lt;Address, AddressFormatter&gt;]</c>), which
/// produces the identical 4-element-array wire format the old hand-rolled
/// <c>WriteAddress</c>/<c>ReadAddress</c> used.
/// </para>
/// <para>
/// Class name and serializer identifier (23) are unchanged from the hand-rolled version, so the
/// existing <c>Remote.conf</c> registration (<c>artery-control</c> alias, <c>serialization-bindings</c>
/// on <see cref="IArteryControlMessage"/>, <c>serialization-identifiers</c> entry) requires no edits.
/// </para>
/// </summary>
[AkkaSerializer(Name = "artery-control", SerializerId = 23)]
[AkkaSerializerFormatter(typeof(Address), typeof(AddressFormatter))]
internal sealed partial class ArteryControlMessageSerializer : MessagePackSerializer<IArteryControlMessage>
[AkkaSerializer<IArteryControlMessage>("artery-control", 23)]
[AkkaSerializerFormatter<Address, AddressFormatter>]
internal sealed partial class ArteryControlMessageSerializer : AkkaSerializer
{
/// <summary>
/// The manifest for <see cref="HandshakeReq"/>.
Expand Down
4 changes: 2 additions & 2 deletions src/core/Akka.Remote/Artery/SystemMessageDeliveryMessages.cs
Original file line number Diff line number Diff line change
Expand Up @@ -95,7 +95,7 @@ internal sealed record Nack(
///
/// <para>
/// <b>How the inner message is nested (documented per the task).</b> <see cref="Message"/> is
/// encoded via <see cref="Akka.Serialization.V2.MessagePackSerializer{TProtocol}.WriteEnvelopePayload"/>
/// encoded via <see cref="Akka.Serialization.V2.AkkaSerializer.WriteEnvelopePayload"/>
/// / decoded via <c>ReadEnvelopePayload</c> -- an EXISTING helper on the V2 MessagePack serializer
/// base class that already implements exactly "nest a serializer id + manifest + raw bytes,
/// recursively through <c>Serialization.FindSerializerFor</c>/<c>Deserialize</c>" for wrapping an
Expand All @@ -120,7 +120,7 @@ internal sealed record Nack(
/// <b>Sourcegen swap field-id note.</b> <see cref="Message"/> is marked
/// <see cref="AkkaEnvelopePayloadAttribute"/>, routing it through the generated serializer's
/// <c>WriteEnvelopePayload</c>/<c>ReadEnvelopePayload</c> calls -- the SAME
/// <see cref="Akka.Serialization.V2.MessagePackSerializer{TProtocol}"/> base-class helpers the
/// <see cref="Akka.Serialization.V2.AkkaSerializer"/> base-class helpers the
/// prior hand-rolled <see cref="ArteryControlMessageSerializer"/> used, confirming the generator
/// has no gap here. The generator emits the record's constructor call positionally by ASCENDING
/// <see cref="AkkaFieldAttribute"/> index (not by declared parameter order), so field indices
Expand Down
Loading
Loading