Vsevolod Stakhov
14c13854d3
[Rework] Further types conversion (no functional changes)
pirms 3 mēnešiem
Vsevolod Stakhov
537a7180a0
[Rework] Use clang-format to unify formatting in all sources
No meaningful changes.
pirms 11 mēnešiem
Vsevolod Stakhov
160184d857
[Minor] Refactor argument/member name for better soundness
pirms 2 gadiem
Vsevolod Stakhov
d6b21b8142
[Minor] Log events on forced timeout
pirms 2 gadiem
Vsevolod Stakhov
c271eb3665
[Rework] Add C++ guards to all headers
pirms 5 gadiem
Vsevolod Stakhov
134526b562
[Project] Rename events.h
pirms 5 gadiem
Vsevolod Stakhov
3ce1f7720f
[Minor] Improve debug traces for async events
pirms 5 gadiem
Vsevolod Stakhov
0c20729f33
[Rework] Add more traces to async events, get rid of GQuarks
pirms 5 gadiem
Vsevolod Stakhov
b849942bc8
[Project] Kill async watchers as they are way too complex
pirms 5 gadiem
Vsevolod Stakhov
5480f08714
[Fix] Implement watchers replacement to handle nested calls
pirms 5 gadiem
Vsevolod Stakhov
c05c2b3b82
[Fix] Fix more issues with watching of async events
pirms 5 gadiem
Vsevolod Stakhov
d45ec6978f
[Fix] Fix crashes on task cleanup
pirms 5 gadiem
Vsevolod Stakhov
1af89c3566
[Fix] Add fail-safety for destroying sessions
pirms 5 gadiem
Vsevolod Stakhov
c2450b3cf4
[Minor] Improve lua_tcp logging
pirms 6 gadiem
Vsevolod Stakhov
d17d3ff2be
[Minor] Return async event produced
pirms 6 gadiem
Vsevolod Stakhov
0bbc551746
[Feature] Allow to have a stack of watcher finalisers
pirms 7 gadiem
Vsevolod Stakhov
a74882ea00
[Minor] Add id to async watchers to simplify debugging
pirms 7 gadiem
Vsevolod Stakhov
8766fba694
Switch the rest to apache 2
pirms 8 gadiem
Vsevolod Stakhov
ff74d74215
Implement forced timeout for delayed filters
Issue: #452
pirms 8 gadiem
Vsevolod Stakhov
b3f330944f
Add routine to add events for a specific watcher structure
pirms 8 gadiem
Vsevolod Stakhov
fef4d3d836
Extend watchers functionality.
It is now possible to add fake watcher events that delays guarded events
untill it is really completed.
pirms 9 gadiem
Vsevolod Stakhov
64ff1b265c
Pass session data to event watchers.
pirms 9 gadiem
Vsevolod Stakhov
9d9a3d43b7
Fix states logic broken by the previous commit.
pirms 9 gadiem
Vsevolod Stakhov
f1e2f1acd4
Refactor events API.
pirms 9 gadiem
Vsevolod Stakhov
d1ecdb5f47
Call watchers on event group completion.
pirms 9 gadiem
Vsevolod Stakhov
93a2660813
Impelement concept of watched events.
pirms 9 gadiem
Vsevolod Stakhov
1abb0939d1
Remove async threads for now.
They are anyway broken in the asynchronous world.
pirms 9 gadiem
Vsevolod Stakhov
1c7f982f9d
Update copyright.
pirms 9 gadiem
Vsevolod Stakhov
379055dbbb
Unify style without sorting headers.
pirms 10 gadiem
Vsevolod Stakhov
fe79d8c5a3
Revert "Unify code style."
This reverts commit e0483657ff
.
pirms 10 gadiem
Vsevolod Stakhov
e0483657ff
Unify code style.
pirms 10 gadiem
Vsevolod Stakhov
61555065f3
Rework project structure, remove trash files.
pirms 10 gadiem
Vsevolod Stakhov
ad5bf825b7
Refactor task functions.
pirms 10 gadiem
Vsevolod Stakhov
ad837700b8
Refactor memory pool naming.
pirms 10 gadiem
Vsevolod Stakhov
a5b48a05a9
* More things to be thread-safe:
- pool allocator is now thread-safe
- lua subsystem now holds lock to avoid lua stack corruption
- events subsystem now using conditional variables to wait for async_threads
- insert_result is thread-safe now
pirms 12 gadiem
Vsevolod Stakhov
0d64c808b7
Add quarks to events to determine source of event inside rspamd.
Another try to fix threading.
pirms 12 gadiem
Vsevolod Stakhov
5c0f36dfe7
Fixes to threading (still incomplete).
pirms 12 gadiem
Vsevolod Stakhov
2d70897116
Rework events library slightly:
- forced events are no longer checked or created
- add async threads to prevent session to be destroyed till all threads are finished
pirms 12 gadiem
Vsevolod Stakhov
e5c2094331
Allow for post filters to register async events.
Some fixes to lua redis library.
pirms 12 gadiem
Vsevolod Stakhov
4499fc9218
* Finally get rid of stupid savepoints system and migrate to async events logic completely
Fix lua redis library.
pirms 12 gadiem
Vsevolod Stakhov
626a11ad98
* Implement new system of async events handling (experimental)
pirms 14 gadiem