bbbcb22565
fieldalignment of all structs to save memory
...
Signed-off-by: Vasiliy Tolstov <v.tolstov@unistack.org>
2021-03-06 19:45:13 +03:00
4ec4c277b7
lint: fix all major issues
...
Signed-off-by: Vasiliy Tolstov <v.tolstov@unistack.org>
2021-02-14 16:16:01 +03:00
82248eb3b0
many lint fixes and optimizations ( #17 )
...
* util/kubernetes: drop stale files
* debug/log/kubernetes: drop stale files
* util/scope: remove stale files
* util/mdns: drop stale files
* lint fixes
Signed-off-by: Vasiliy Tolstov <v.tolstov@unistack.org>
2021-02-13 15:35:56 +03:00
abb9937787
fix lint issues ( #16 )
...
Signed-off-by: Vasiliy Tolstov <v.tolstov@unistack.org>
2021-02-13 01:46:16 +03:00
827d467077
micro: rewrite options to support multiple building blocks
...
Signed-off-by: Vasiliy Tolstov <v.tolstov@unistack.org>
2021-01-29 13:17:32 +03:00
c9049c3845
major codec upgrade
...
Signed-off-by: Vasiliy Tolstov <v.tolstov@unistack.org>
2020-11-23 16:21:07 +03:00
e3f235acc1
api/handler/rpc: fix corner cases
...
Signed-off-by: Vasiliy Tolstov <v.tolstov@unistack.org>
2020-11-10 11:00:06 +03:00
e41bb5ebc5
rewrite logger
...
Signed-off-by: Vasiliy Tolstov <v.tolstov@unistack.org>
2020-11-05 00:23:05 +03:00
8a2b122015
many fixes for lint and context.Context usage ( #5 )
...
Signed-off-by: Vasiliy Tolstov <v.tolstov@unistack.org>
2020-11-03 02:02:32 +03:00
c576749b57
noop impl ( #32 )
...
* improve logger usage
* add noop client and server
Signed-off-by: Vasiliy Tolstov <v.tolstov@unistack.org>
2020-09-05 02:11:29 +03:00
6aa857dfa1
fixup deps
...
Signed-off-by: Vasiliy Tolstov <v.tolstov@unistack.org>
2020-08-28 11:27:45 +03:00
0f4b1435d9
move implementations to external repos ( #17 )
...
Signed-off-by: Vasiliy Tolstov <v.tolstov@unistack.org>
2020-08-25 13:44:41 +03:00
c4a303190a
lint fixes ( #14 )
...
* lint fixes
Signed-off-by: Vasiliy Tolstov <v.tolstov@unistack.org>
2020-08-21 14:53:21 +03:00
199ff66bd4
enable cache for build, closes #8 ( #12 )
...
* enable cache for build, closes #8
* goimports
* lint fixes
Signed-off-by: Vasiliy Tolstov <v.tolstov@unistack.org>
2020-08-20 15:23:41 +03:00
06136312bb
regen files with never protoc ( #6 )
...
* regen files with never protoc
* rewrite import path
Signed-off-by: Vasiliy Tolstov <v.tolstov@unistack.org>
2020-08-19 17:47:17 +03:00
Asim Aslam
8ee31b94a1
remove handler/util package in favour of util/router ( #1908 )
2020-08-07 12:47:20 +01:00
Asim Aslam
563768b58a
v3 refactor ( #1868 )
...
* Move to v3
Co-authored-by: Ben Toogood <bentoogood@gmail.com>
2020-07-27 13:22:00 +01:00
Di Wu
f9bf562393
fix typo in comments ( #1840 )
...
* remove global error tracking
* rpc_server: fix invalid register err
* fix typo
Co-authored-by: Asim Aslam <asim@aslam.me>
2020-07-16 16:33:11 +01:00
97ae2979ad
pass request context from request rpc endpoints ( #1799 )
...
http middleware can add additional metadata to context,
for example tracing wrappers, pass down it to underlining
services
Signed-off-by: Vasiliy Tolstov <v.tolstov@unistack.org>
2020-07-06 13:55:17 +01:00
ben-toogood
174e44b846
Deprecate client/selector ( #1767 )
...
* client/{grpc,rpc}: depricate selector (wip)
* {client,cmd}: remove client/selector
* deprecate client/selector
* router/static: fix lookup
* config/cmd: add support for legacy static selector flag
* config/cmd: add support for legacy dns selector flag
2020-07-01 17:06:59 +01:00
ben-toogood
104b7d8f8d
api/resolver: update resolver to enable subdomain routing ( #1747 )
...
* api/resolver: update domain / service prefix usage
* api/resolver/subdomain: implement subdomain resolver for domain resolution
* api/handler: fix tests
2020-06-26 14:28:18 +01:00
92e9d05432
api/handler/rpc: dont log error on normal websocket error code ( #1688 )
...
Signed-off-by: Vasiliy Tolstov <v.tolstov@unistack.org>
2020-06-12 10:42:52 +01:00
90dd1f63c8
api/handler/rpc: fix encoding of inner message ( #1601 )
...
* api/handler/rpc: fix encoding of inner message
Signed-off-by: Vasiliy Tolstov <v.tolstov@unistack.org>
2020-05-04 15:50:53 +03:00
6fa27373ed
bundle qson lib in util ( #1561 )
...
* copy qson from https://github.com/joncalhoun/qson
as author not want to maintain repo
* latest code contains our fix to proper decode strings
with escaped & symbol
* replace package in api/handler/rpc
Signed-off-by: Vasiliy Tolstov <v.tolstov@unistack.org>
2020-04-23 11:08:09 +03:00
62cedf64da
api/router/registry: extract path based parameters from url to req ( #1530 )
...
* api/router/registry: extract path based parameters from url to req
* api/handler/rpc: fix empty body request parsing
* bundle grpc-gateway util funcs
Signed-off-by: Vasiliy Tolstov <v.tolstov@unistack.org>
2020-04-15 17:50:51 +03:00
b700d425a4
api/handler/rpc: improvements and fixes ( #1535 )
...
* api/handler/rpc: fix empty body case
* api/handler/rpc: copy all request headers to metadata
Signed-off-by: Vasiliy Tolstov <v.tolstov@unistack.org>
2020-04-15 01:37:15 +03:00
Asim Aslam
e515005083
Remove only allowing certain methods
2020-04-13 23:05:39 +01:00
Asim Aslam
a056bdce7c
fix metadata parsing
2020-04-12 14:40:37 +01:00
Asim Aslam
b08c636b44
fixup handler tests
2020-04-12 14:29:38 +01:00
Asim Aslam
962588b649
Strip MetadataKey global var
2020-04-12 11:16:08 +01:00
0a2363b49b
api minor improvements ( #1526 )
...
* api/handler/rpc: unblock all http methods and set Host meta
* api/router/static: add debug log
Signed-off-by: Vasiliy Tolstov <v.tolstov@unistack.org>
2020-04-11 22:21:55 +03:00
Ben Toogood
4ff959ef50
Dynamic Namespace
2020-04-09 11:03:33 +01:00
Ben Toogood
3ede494945
Change import name
2020-04-09 10:32:08 +01:00
Ben Toogood
f102aba4c1
Fix HTTP tests
2020-04-09 10:28:38 +01:00
Asim Aslam
9a73828782
Remove unused handlers
2020-04-08 15:34:11 +01:00
6aaad7d63f
api/router/static: allow to specify body dst ( #1486 )
...
Signed-off-by: Vasiliy Tolstov <v.tolstov@unistack.org>
2020-04-07 15:38:27 +01:00
bc7579f1d8
api/handler/rpc: fix panic on invalid error conversation ( #1483 )
...
Signed-off-by: Vasiliy Tolstov <v.tolstov@unistack.org>
2020-04-04 00:55:15 +03:00
38aed6f0f6
api/handler/rpc: not log error on client disconnect ( #1482 )
...
Signed-off-by: Vasiliy Tolstov <v.tolstov@unistack.org>
2020-04-04 00:37:18 +03:00
0241197c6a
api/handler/rpc: binary streaming support ( #1466 )
...
* api/handler/rpc: binary streaming support
Signed-off-by: Vasiliy Tolstov <v.tolstov@unistack.org>
* fixup
Signed-off-by: Vasiliy Tolstov <v.tolstov@unistack.org>
* fix
Signed-off-by: Vasiliy Tolstov <v.tolstov@unistack.org>
* fix sec webscoekt protol
Signed-off-by: Vasiliy Tolstov <v.tolstov@unistack.org>
2020-04-02 10:13:04 +01:00
7b7a859a03
api: use http request Clone ( #1458 )
...
Signed-off-by: Vasiliy Tolstov <v.tolstov@unistack.org>
2020-04-01 01:50:37 +03:00
8a8742f867
api/handler/rpc: dont change types of url fields ( #1457 )
...
Signed-off-by: Vasiliy Tolstov <v.tolstov@unistack.org>
2020-04-01 01:26:58 +03:00
1490aff38e
api/handler/rpc: correctly parse nested url vars ( #1455 )
...
Signed-off-by: Vasiliy Tolstov <v.tolstov@unistack.org>
2020-04-01 00:23:17 +03:00
18061723bb
fix api metadata extract from context ( #1452 )
...
Signed-off-by: Vasiliy Tolstov <v.tolstov@unistack.org>
2020-03-31 22:36:51 +03:00
d6bef84de0
api/handler/rpc: fix metadata cleanup ( #1451 )
...
Signed-off-by: Vasiliy Tolstov <v.tolstov@unistack.org>
2020-03-31 21:59:35 +03:00
3d7d5ce6b4
api: add static router and improve path parser in rpc handler ( #1437 )
...
* api: add static router and improve path parser in rpc handler
Signed-off-by: Vasiliy Tolstov <v.tolstov@unistack.org>
* expose metadata context key to be able to get unmodified map keys
Signed-off-by: Vasiliy Tolstov <v.tolstov@unistack.org>
* server/grpc: fix jsonpb codec for protobuf msg
Signed-off-by: Vasiliy Tolstov <v.tolstov@unistack.org>
* api/handler/rpc: write 204 status code when rsp is nil
Signed-off-by: Vasiliy Tolstov <v.tolstov@unistack.org>
* api/handler/rpc: add check for nil response for non javascript
Signed-off-by: Vasiliy Tolstov <v.tolstov@unistack.org>
2020-03-30 09:04:59 +01:00
b38da6ced0
api/handler/rpc: process all methods and merge url params to json body ( #1427 )
...
* api/handler/rpc: process all methods and merge url params to json body
Signed-off-by: Vasiliy Tolstov <v.tolstov@unistack.org>
* add merge json test
Signed-off-by: Vasiliy Tolstov <v.tolstov@unistack.org>
2020-03-27 07:59:31 +00:00
Asim Aslam
62f9a054a4
100mb ( #1421 )
2020-03-26 16:57:31 +00:00
02839cfba5
api/handler: use http.MaxBytesReader and buffer pool ( #1415 )
...
* api/handler: use http.MaxBytesReader
protect api handlers from OOM cases
Signed-off-by: Vasiliy Tolstov <v.tolstov@unistack.org>
2020-03-26 14:29:28 +03:00
9826ddbd64
api/handler/rpc: log errors ( #1390 )
...
Signed-off-by: Vasiliy Tolstov <v.tolstov@unistack.org>
2020-03-23 10:31:35 +03:00
7b385bf163
minimize allocations in logger and tunnel code ( #1323 )
...
* logs alloc
Signed-off-by: Vasiliy Tolstov <v.tolstov@unistack.org>
* fix allocs
Signed-off-by: Vasiliy Tolstov <v.tolstov@unistack.org>
* fix allocs
Signed-off-by: Vasiliy Tolstov <v.tolstov@unistack.org>
* tunnel allocs
Signed-off-by: Vasiliy Tolstov <v.tolstov@unistack.org>
* try to fix tunnel
Signed-off-by: Vasiliy Tolstov <v.tolstov@unistack.org>
* cache cipher for send
Signed-off-by: Vasiliy Tolstov <v.tolstov@unistack.org>
* more logger
Signed-off-by: Vasiliy Tolstov <v.tolstov@unistack.org>
* more logger
Signed-off-by: Vasiliy Tolstov <v.tolstov@unistack.org>
* more logger
Signed-off-by: Vasiliy Tolstov <v.tolstov@unistack.org>
* more logger
Signed-off-by: Vasiliy Tolstov <v.tolstov@unistack.org>
* more logger
Signed-off-by: Vasiliy Tolstov <v.tolstov@unistack.org>
* more logger
Signed-off-by: Vasiliy Tolstov <v.tolstov@unistack.org>
* more logger
Signed-off-by: Vasiliy Tolstov <v.tolstov@unistack.org>
2020-03-11 17:55:39 +00:00