serialization - Protobuf-net serializer for NEventStore 3+ -


can point me protobuf-net serializer neventstore 3.0?

i'm having trouble think due serialization in event store 3 wrapping event body , headers in eventmessage.

i'm not sure how setup custom serializer correctly.

this entirely untested guesswork based on brief glance @ github, looks want use wire-up api specify custom serializer, example:

var store = wireup.init()     .usingsqlpersistence("name of eventstore connectionstring in config file")         .initializestorageengine()         .usingcustomserialization(myserializer)     ... etc 

where myserializer instance of type implements iserialize interface. looks should work:

class protobufserializer : eventstore.serialization.iserialize {     public void serialize<t>(stream output, t graph)     {         protobuf.serializer.serialize<t>(output, graph);     }      public t deserialize<t>(stream input)     {         return protobuf.serializer.deserialize<t>(input);     } } 

(so myserializer here new protobufserializer())


Comments

Popular posts from this blog

monitor web browser programmatically in Android? -

Shrink a YouTube video to responsive width -

wpf - PdfWriter.GetInstance throws System.NullReferenceException -