From 0a68a9c2786aa1667536d0d6c5e40b6284a0a1ff Mon Sep 17 00:00:00 2001 From: Vasiliy Tolstov Date: Fri, 11 Dec 2020 00:21:53 +0300 Subject: [PATCH] use default codec for store Signed-off-by: Vasiliy Tolstov --- codec/codec.go | 3 ++- store/options.go | 1 + 2 files changed, 3 insertions(+), 1 deletion(-) diff --git a/codec/codec.go b/codec/codec.go index 09caf920..dad14d4a 100644 --- a/codec/codec.go +++ b/codec/codec.go @@ -25,7 +25,8 @@ var ( var ( // DefaultMaxMsgSize specifies how much data codec can handle - DefaultMaxMsgSize = 1024 * 1024 * 4 // 4Mb + DefaultMaxMsgSize = 1024 * 1024 * 4 // 4Mb + DefaultCodec Codec = NewCodec() ) // MessageType diff --git a/store/options.go b/store/options.go index 40ba5af7..b21e4c42 100644 --- a/store/options.go +++ b/store/options.go @@ -32,6 +32,7 @@ func NewOptions(opts ...Option) Options { options := Options{ Logger: logger.DefaultLogger, Context: context.Background(), + Codec: codec.DefaultCodec, } for _, o := range opts { o(&options)