Created
May 30, 2014 03:44
-
-
Save randomcodenz/8e9fb8b54c979d9d4cc3 to your computer and use it in GitHub Desktop.
FuturePublishing and Message Versioning
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Current ScheduleMe message creation ... | |
var typeName = typeNameSerializer.Serialize( typeof( T ) ); | |
var messageBody = serializer.MessageToBytes( message ); | |
var scheduleMe = new ScheduleMe | |
{ | |
WakeTime = futurePublishDate, | |
BindingKey = typeName, | |
CancellationKey = cancellationKey, | |
InnerMessage = messageBody | |
}; | |
return scheduleMe; | |
// Possible ScheduleMe message creation ... | |
var serializedMessage = messageSerializationStrategy.SerializeMessage(message); | |
var messageBody = messageSerializationStrategy.SerializeMessage(serializedMessage); | |
var scheduleMe = new ScheduleMe | |
{ | |
WakeTime = futurePublishDate, | |
BindingKey = typeName, | |
CancellationKey = cancellationKey, | |
InnerMessage = messageBody | |
}; | |
return scheduleMe; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment