Exemplo n.º 1
0
        /// <summary>
        /// Use ProtoBuf for event serialization.
        /// </summary>
        /// <param name="cfg"></param>
        /// <returns></returns>
        public static EventStoreConfiguration WithProtoBufEventSerializer(this EventStoreConfiguration cfg)
        {
            ISerializer serializer = new ProtoBufSerializer();

            Xyperico.Agres.EventStore.EventStoreConfigurationExtensions.SetMessageSerializer(cfg, serializer);
            return(cfg);
        }
        /// <summary>
        /// Use ProtoBuf for message serialization.
        /// </summary>
        /// <param name="cfg"></param>
        /// <returns></returns>
        public static MessageBusConfiguration WithProtoBufMessageSerializer(this MessageBusConfiguration cfg)
        {
            ISerializer serializer = new ProtoBufSerializer();

            Xyperico.Agres.MessageBus.MessageBusConfigurationExtensions.SetMessageSerializer(cfg, serializer);
            return(cfg);
        }
 protected override void SetUp()
 {
   base.SetUp();
   AppendOnlyStore = new SQLiteAppendOnlyStore(SetupFixture.SqlConnectionString, false);
   ISerializer serializer = new ProtoBufSerializer();
   Store = new EventStoreDB(AppendOnlyStore, serializer);
   Repository = new GenericRepository<Forum, ForumId>(Store);
   Service = new ForumApplicationService(Store);
 }
 /// <summary>
 /// Use ProtoBuf for event serialization.
 /// </summary>
 /// <param name="cfg"></param>
 /// <returns></returns>
 public static EventStoreConfiguration WithProtoBufEventSerializer(this EventStoreConfiguration cfg)
 {
     ISerializer serializer = new ProtoBufSerializer();
       Xyperico.Agres.EventStore.EventStoreConfigurationExtensions.SetMessageSerializer(cfg, serializer);
       return cfg;
 }
 /// <summary>
 /// Use ProtoBuf for message serialization.
 /// </summary>
 /// <param name="cfg"></param>
 /// <returns></returns>
 public static MessageBusConfiguration WithProtoBufMessageSerializer(this MessageBusConfiguration cfg)
 {
     ISerializer serializer = new ProtoBufSerializer();
       Xyperico.Agres.MessageBus.MessageBusConfigurationExtensions.SetMessageSerializer(cfg, serializer);
       return cfg;
 }