Commit Graph

20 Commits

Author SHA1 Message Date
Andrey Borodin 298cdca895
Implement client_max_routing (#72) 2019-10-15 17:15:37 +03:00
Andrey Borodin 76ec3581a1
Use pg_lrand48 for portability (#48) 2019-01-30 14:30:31 +05:00
Dmitry Simonenko 6c0a1f09f8 odyssey: major rework of io architecture
This patch intend is to improve overall io performance, reduce
cpu and system usage.

Machinarium:

IO read/write logic is highly simplified and now based on conditions
instead of previously made internal readahead buffer and msg
queues. This allows to give user more control over io operations and
avoid doing undesired readahead copying.

Above that, TLS implementation reworked to use async logic instead of
separate BIO layer.

Direct pooling functions removed.

New objects machine_cond_t and machine_iov_t objects.

Odyssey:

Introduced readahead, io and relay objects.

Relay allows to connect two io handles for direct data retransmission
without double copying.

Removed configuration options no longer needed:
packet_read_size, packet_write_queue
2019-01-23 18:43:52 +03:00
Dmitry Simonenko 2e03af9c88 odyssey: major router and shared logic rework
Goal is to improve overall performance during massive peaks
of connecting clients.

This patch makes router a shared structure, instead of
being run in separate system worker thread/coroutine.

Now router and each route object is protected by
separate mutex. Worker threads directly access router object
without calls to separate thread.
2018-12-06 17:23:15 +03:00
Dmitry Simonenko 9115d60117 machinarium: rework time update logic 2018-11-27 16:19:16 +03:00
Dmitry Simonenko fbc037aa23 odyssey: implement packet retransmission in chunks; packet_read_size 2018-10-23 16:51:30 +03:00
Dmitry Simonenko a790378ddb odyssey: force obsolete clients to disconnect on reload 2018-09-19 13:45:10 +03:00
Dmitry Simonenko 11dce290c3 odyssey: implement config file reload. fix #38 2018-09-18 19:22:22 +03:00
Dmitry Simonenko da7e6ea7a5 odyssey: major io rework and refactoring
This patch moves Odyssey from stream based write caching
to message driven. All write operations are delayed
and happen on a group of messages.

This removes necessity to do IO and wait for write completion during calls
from SSL_write() context. Write timings should behave more predictable now and
number of used syscalls should be also decreased.

This patch also simplifies caching management. All clients are simply
reusing cached messages without prolonged contention.

Several configuration options are no longer used:
pipeline, cache, cache_chunk
2018-08-28 17:43:46 +03:00
Dmitry Simonenko 3eb948af76 odyssey: proper server->tls init on server listen 2018-08-08 15:15:21 +03:00
Dmitry Simonenko f7a4438ec1 odyssey: move stats out of server_t 2018-08-02 16:38:36 +03:00
Dmitry Simonenko 6e73c241f8 odyssey: implement kill_client console command. fix #39 2018-07-19 17:33:44 +03:00
Dmitry Simonenko c495b9ea8a odyssey: add unix_socket_mode configuration param 2018-07-03 16:02:46 +03:00
Dmitry Simonenko fb023d42cb odyssey: add unix socket support. fix #31 2018-07-02 18:41:17 +03:00
Dmitry Simonenko 8a735a8e87 odyssey: do not exit on SIGHUP 2018-05-24 19:07:57 +03:00
Dmitry Simonenko 5ca3fa926a odyssey: update source file headers 2018-04-04 16:19:58 +03:00
Dmitry Simonenko 38430a9d51 odyssey: remove config versioning 2018-03-21 17:36:57 +03:00
Dmitry Simonenko 3378e60827 odyssey: remove instance_t* field out from system 2018-03-13 16:37:53 +03:00
Dmitry Simonenko fb07550d06 odyssey: remove unused field 2018-03-13 16:28:45 +03:00
Dmitry Simonenko 9fcf2a4a80 odyssey: remake pooler service as system 2018-03-13 16:26:04 +03:00