Сергей Прохоров
da597f0f8c
Return more details about downstream socket errors
2019-02-16 20:50:12 +01:00
Сергей Прохоров
46c37ae6a7
All dialyzer errors fixed; dialyzer added to travis.yml
2019-02-16 20:50:12 +01:00
Сергей Прохоров
8031dafa20
Fix "maybe_close_down" race-condition
...
If downstream connection pool crashed and recovered while some
upstream was alive holding it's DC ID, it may return downstream
taken from the old incarnation of pool to new one because it's
registered under the same name.
Fix is to hold pool's PID instead of name
2019-02-16 20:50:12 +01:00
Сергей Прохоров
e9f999a151
Stop ranch listeners in 'prep_stop', not 'stop' application callback
2019-02-16 20:50:12 +01:00
Сергей Прохоров
bf01459be5
Handle some of 'unknown_upstream' errors as expected race-condition
2019-02-16 20:50:12 +01:00
Сергей Прохоров
8026fb5552
Detect downstream connection attempt failure quicker
...
By checking for monitor message
2019-02-16 20:50:12 +01:00
Сергей Прохоров
79fb6015f6
Experimental backpressure for downstream
2019-02-16 20:50:12 +01:00
Сергей Прохоров
6bc9253999
Don't report tcp socket error as gen_server error
2019-02-16 20:50:12 +01:00
Сергей Прохоров
414e7bc037
Fix some dialyzer errors
2019-02-16 20:50:12 +01:00
Сергей Прохоров
447639224f
Simplify codecs. Use fixed/flat 2-layer codec instead of tree
2019-02-16 20:50:11 +01:00
Сергей Прохоров
590a633ab7
Refactor self-healtcheck
...
* Trigger GC with lower threshold
* Unconditionally die if queue len is too large
2019-02-16 20:50:11 +01:00
Сергей Прохоров
4f30749d83
Make multiplexed downstream socket buffer size tunable
2019-02-16 20:50:11 +01:00
Сергей Прохоров
0af1923ca2
Minor cleanups
2019-02-16 20:49:26 +01:00
Сергей Прохоров
120bf6a46e
Garbage-collect self before making final decision about termination
2019-02-16 20:49:25 +01:00
Сергей Прохоров
835f82aa73
Terminate upstream if it have too long queue and uses too much memory
2019-02-16 20:49:25 +01:00
Сергей Прохоров
88dddb5ed4
Better handling of down connection termination
2019-02-16 20:49:25 +01:00
Сергей Прохоров
dd8a8d48ef
Use standard process registration for dc pools instead of ETS
...
There was a race-condition, that caused crashes.
We could use gproc, but it feels a bit overkill for ~10-20 processes
2019-02-16 20:49:25 +01:00
Сергей Прохоров
8669db42f9
Fix metric
2019-02-16 20:49:25 +01:00
Сергей Прохоров
f67f88f8c9
Metrics fixed
2019-02-16 20:49:25 +01:00
Сергей Прохоров
91b89061e4
Add monitor dc_pool <-> down_conn
2019-02-16 20:48:06 +01:00
Сергей Прохоров
15bff24888
Bit more logging
2019-02-16 20:47:27 +01:00
Сергей Прохоров
b0f6ee2958
Fix rpc_close_ext
2019-02-16 20:47:27 +01:00
Сергей Прохоров
a182c3be65
Fix wrong match pattern
2019-02-16 20:47:27 +01:00
Сергей Прохоров
a28cb437f9
Add "status" for dc pools; add initial burst handling for pool growth
2019-02-16 20:47:27 +01:00
Сергей Прохоров
a8803a7b66
Add multiplexing draft
2019-02-16 20:46:24 +01:00
Сергей Прохоров
8dd4511701
Make it possible to overwrite port/secret/tag from docker command-line
2019-02-16 20:27:42 +01:00
Сергей Прохоров
34eb21dc00
Bump version
2019-02-16 20:27:41 +01:00
Сергей Прохоров
e46e69b77f
Fix docker build for cases when prod-* configs already exist
2019-02-16 20:27:41 +01:00
Сергей Прохоров
68c4659fdb
Add epmd systemd service on systems that don't have it. Fixes #5
2019-02-16 20:27:41 +01:00
Сергей Прохоров
1726701e2d
Add xref check to travis
2019-02-16 20:27:41 +01:00
Сергей Прохоров
2b24b366c8
Upgrade ranch to 1.7
2019-02-16 20:27:34 +01:00
Сергей Прохоров
9d7903e8f4
Fix some deprecation warnings
2019-02-16 17:16:02 +01:00
Сергей Прохоров
f47ba71336
Add 'dumb-init' to docker
2019-01-26 22:58:05 +01:00
Сергей Прохоров
3cf06c7bda
Make docker use default configs if specific doesn't exist
2019-01-24 00:52:32 +01:00
Сергей Прохоров
8d5d0aca32
Add dockerfile and docker instructions
2019-01-23 02:37:39 +01:00
Сергей Прохоров
9e0eaa0652
Make it possible to tune socket buffer sizes
2018-10-27 21:27:29 +02:00
Сергей Прохоров
d49a451d42
Don't create installation dirrectory
2018-10-22 22:26:46 +02:00
Сергей Прохоров
d4b8c76cdf
Ease debugging
...
use fully qualified node name
2018-10-22 22:21:30 +02:00
Сергей Прохоров
1253fdc844
Add user-agent to outgoing HTTP requests
2018-10-22 22:03:12 +02:00
Сергей Прохоров
ef7380700f
makefile: create user before logdir
2018-10-21 21:26:02 +02:00
Сергей Прохоров
8d9c64b58b
Don't crash on tcp send errors
2018-10-20 16:42:04 +02:00
Сергей Прохоров
e0d586ef3e
Remove downstream IP from metrics
2018-10-20 16:27:58 +02:00
Сергей Прохоров
8b685c941c
Move hot function clause to be 1st clause
2018-10-13 21:58:29 +02:00
Сергей Прохоров
02bcdf53be
Add "dc_id" to metrics
2018-10-09 15:55:46 +02:00
Сергей Прохоров
7d0480be32
Fix typo in metric name
2018-10-06 23:17:32 +02:00
Сергей Прохоров
f3c3690a03
Use more reliable method of filtering ranch listeners
2018-10-06 23:02:02 +02:00
Сергей Прохоров
ea6c692ae5
Add session_lifetime metric
2018-10-06 20:49:28 +02:00
Сергей Прохоров
56d8bac4ea
Record connection start time in milliseconds, not seconds
2018-10-06 14:51:15 +02:00
Сергей Прохоров
8e618906b4
Make it possible to export metrics by providing callback module
2018-10-05 22:10:30 +02:00
Сергей Прохоров
1cfdf90513
Fix bug in automatic TG config/IP updater
2018-10-04 08:26:02 +02:00