Commit Graph

4469 Commits

Author SHA1 Message Date
6b1ed63b48 guard agains not fully configured config sources
Signed-off-by: Vasiliy Tolstov <v.tolstov@unistack.org>
2020-12-20 01:00:52 +03:00
b50855855b config: export method to init new empty struct
Signed-off-by: Vasiliy Tolstov <v.tolstov@unistack.org>
2020-12-20 00:15:29 +03:00
150e8ad698 config: improve and export helper func
Signed-off-by: Vasiliy Tolstov <v.tolstov@unistack.org>
2020-12-19 23:22:05 +03:00
035a84e696 config: fix tests
Signed-off-by: Vasiliy Tolstov <v.tolstov@unistack.org>
2020-12-18 03:50:52 +03:00
565082f515 before/after config stuff handled by implementations
Signed-off-by: Vasiliy Tolstov <v.tolstov@unistack.org>
2020-12-18 03:38:09 +03:00
8c504bd029 handle before/after inside config implementations
Signed-off-by: Vasiliy Tolstov <v.tolstov@unistack.org>
2020-12-18 03:37:18 +03:00
f6c0728a59 fix context usage across codebase
Signed-off-by: Vasiliy Tolstov <v.tolstov@unistack.org>
2020-12-17 22:52:00 +03:00
70a17dc10a client: allow to create new client with predefined call options
Signed-off-by: Vasiliy Tolstov <v.tolstov@unistack.org>
2020-12-15 23:09:51 +03:00
f14efa64f0 server: add MaxConn and Listener options
Signed-off-by: Vasiliy Tolstov <v.tolstov@unistack.org>
2020-12-15 11:52:05 +03:00
42f4d26fe4 server: add MaxConn option
Signed-off-by: Vasiliy Tolstov <v.tolstov@unistack.org>
2020-12-15 11:46:30 +03:00
06c3cd6637 config: fix default config loader
Signed-off-by: Vasiliy Tolstov <v.tolstov@unistack.org>
2020-12-13 19:28:29 +03:00
99738096ac fix configs options
Signed-off-by: Vasiliy Tolstov <v.tolstov@unistack.org>
2020-12-13 18:56:54 +03:00
c6dfc8acaa load config on service init
Signed-off-by: Vasiliy Tolstov <v.tolstov@unistack.org>
2020-12-13 14:36:31 +03:00
762f20d179 registry: adopt micro/micro 69b0ac2e9140fee1cde043f5ecdab438a41898ee
Signed-off-by: Vasiliy Tolstov <v.tolstov@unistack.org>
2020-12-13 13:51:09 +03:00
92aec349c3 config: add missing codec error
Signed-off-by: Vasiliy Tolstov <v.tolstov@unistack.org>
2020-12-13 13:26:44 +03:00
2dcd30b21c add defaut config parser
Signed-off-by: Vasiliy Tolstov <v.tolstov@unistack.org>
2020-12-13 13:17:38 +03:00
a7a3c679d1 config: load defaults
Signed-off-by: Vasiliy Tolstov <v.tolstov@unistack.org>
2020-12-13 13:10:04 +03:00
5c6eba20e7 codec: fix noop codec
Signed-off-by: Vasiliy Tolstov <v.tolstov@unistack.org>
2020-12-11 00:32:29 +03:00
0a68a9c278 use default codec for store
Signed-off-by: Vasiliy Tolstov <v.tolstov@unistack.org>
2020-12-11 00:21:53 +03:00
a13cb01005 store: create options helpers
Signed-off-by: Vasiliy Tolstov <v.tolstov@unistack.org>
2020-12-10 22:37:40 +03:00
9fc0b5f88b store: remove unneded options
Signed-off-by: Vasiliy Tolstov <v.tolstov@unistack.org>
2020-12-10 22:31:36 +03:00
6a7433ba2a
store: refactor interface (#11)
Signed-off-by: Vasiliy Tolstov <v.tolstov@unistack.org>
2020-12-10 22:08:56 +03:00
a754ff7c0c more lint fixes
Signed-off-by: Vasiliy Tolstov <v.tolstov@unistack.org>
2020-12-09 12:10:25 +03:00
e08276c2e2 gofmt
Signed-off-by: Vasiliy Tolstov <v.tolstov@unistack.org>
2020-12-08 00:41:14 +03:00
b7b28f6b9a lint
Signed-off-by: Vasiliy Tolstov <v.tolstov@unistack.org>
2020-12-08 00:38:37 +03:00
f63ff80d46 backport micro 820f59869617dee18c9a699c8e01d7a6b080f854
Signed-off-by: Vasiliy Tolstov <v.tolstov@unistack.org>
2020-12-07 21:54:45 +03:00
8fd745eab0 config: add logger to options
Signed-off-by: Vasiliy Tolstov <v.tolstov@unistack.org>
2020-12-07 19:27:08 +03:00
c7ed807129 default retries is always 0
Signed-off-by: Vasiliy Tolstov <v.tolstov@unistack.org>
2020-12-07 19:26:22 +03:00
c6fd9c1c23 add context helpers
Signed-off-by: Vasiliy Tolstov <v.tolstov@unistack.org>
2020-12-07 16:10:20 +03:00
b5d3b699cf fixup
Signed-off-by: Vasiliy Tolstov <v.tolstov@unistack.org>
2020-12-04 02:34:20 +03:00
5279c2aa0f
config package rework (#9)
* change config interface
* reuse codec
* allow to modify next config based on values in current config via BeforeLoad

Signed-off-by: Vasiliy Tolstov <v.tolstov@unistack.org>
2020-12-04 02:28:45 +03:00
0ddc8de00b apply micro commit 2eb19c2e97d9316438bc66cd2cda896e8c99d026
Signed-off-by: Vasiliy Tolstov <v.tolstov@unistack.org>
2020-11-30 22:48:00 +03:00
8d6eb34aee fix random selector
Signed-off-by: Vasiliy Tolstov <v.tolstov@unistack.org>
2020-11-29 17:30:54 +03:00
0d93b2c31c add some defaults
Signed-off-by: Vasiliy Tolstov <v.tolstov@unistack.org>
2020-11-26 01:13:05 +03:00
3f6852030f expose codec options
Signed-off-by: Vasiliy Tolstov <v.tolstov@unistack.org>
2020-11-25 10:43:13 +03:00
458388359a add string support to noop codec
Signed-off-by: Vasiliy Tolstov <v.tolstov@unistack.org>
2020-11-25 10:04:11 +03:00
2101e994d9 add Frame support in noop codec
Signed-off-by: Vasiliy Tolstov <v.tolstov@unistack.org>
2020-11-25 09:59:28 +03:00
8a50a2d0b8 receives only body of the message
Signed-off-by: Vasiliy Tolstov <v.tolstov@unistack.org>
2020-11-25 08:33:29 +03:00
71d82e9d5b add codec NewMessage helper
Signed-off-by: Vasiliy Tolstov <v.tolstov@unistack.org>
2020-11-24 15:14:47 +03:00
c9049c3845 major codec upgrade
Signed-off-by: Vasiliy Tolstov <v.tolstov@unistack.org>
2020-11-23 16:21:07 +03:00
daffa9e548
use metadata.Metadata (#8)
Signed-off-by: Vasiliy Tolstov <v.tolstov@unistack.org>
2020-11-18 16:50:41 +03:00
e0ef8b2953 merics: add Init func to interface
Signed-off-by: Vasiliy Tolstov <v.tolstov@unistack.org>
2020-11-15 00:53:40 +03:00
f6c914c1e4 metrics: minor changes to interface and set default
Signed-off-by: Vasiliy Tolstov <v.tolstov@unistack.org>
2020-11-15 00:38:38 +03:00
b38484d18e go mod tidy
Signed-off-by: Vasiliy Tolstov <v.tolstov@unistack.org>
2020-11-13 15:06:12 +03:00
75222e07cb exttract protoc plugin to dedicated repo
Signed-off-by: Vasiliy Tolstov <v.tolstov@unistack.org>
2020-11-13 14:59:14 +03:00
4233a4b673 init cmd and logger options on service init
Signed-off-by: Vasiliy Tolstov <v.tolstov@unistack.org>
2020-11-13 14:52:19 +03:00
c44a82a8cb registry/noop: implement noop watcher
Signed-off-by: Vasiliy Tolstov <v.tolstov@unistack.org>
2020-11-13 14:50:57 +03:00
37f7960f4a logger: add WithContext option
Signed-off-by: Vasiliy Tolstov <v.tolstov@unistack.org>
2020-11-13 14:50:29 +03:00
6dc7e792c8 logger improvements
Signed-off-by: Vasiliy Tolstov <v.tolstov@unistack.org>
2020-11-10 22:18:16 +03:00
81649d51e1 Merge branch 'master' of https://github.com/unistack-org/micro 2020-11-10 11:01:14 +03:00