Commit Graph

68 Commits

Author SHA1 Message Date
Arseny Smirnov
ebe93d7e4f Binlog::erase_batch, TQueue:pop_batch 2023-02-10 15:14:14 +01:00
levlam
882de6e8e8 Replace unsafe to maintain data_ field with get_data() method. 2023-02-02 03:08:26 +03:00
levlam
b4658f3da3 Reserve storage for deleted_log_event_ids. 2023-02-01 22:01:26 +03:00
levlam
f8372a52e3 Improve TQueue::clear logging. 2023-01-29 13:04:04 +03:00
levlam
c8acf63e02 Delete TQueue events directly if appropriate. 2023-01-06 17:54:02 +03:00
levlam
c4afb9283c Return all deleted events fron TQueue::clear. 2023-01-05 23:17:06 +03:00
levlam
cf1984844b Update copyright year. 2023-01-01 00:28:08 +03:00
levlam
124d0d4043 Use directly remove_event instead of pop in TQueue:clear. 2022-12-20 19:34:55 +03:00
levlam
f99fb4fc06 Delete events from callback before forgetting them in TQueue. 2022-12-20 16:37:22 +03:00
levlam
b1ddf9d3a7 Minor fixes. 2022-11-23 16:32:09 +03:00
levlam
62d5ffcd86 Fix logging. 2022-11-23 01:00:29 +03:00
levlam
2849a0857b Add warning about too long TQueue clear. 2022-11-21 12:20:48 +03:00
levlam
32456872af Decrease the maximum number of kept TQueue events. 2022-11-10 21:18:13 +03:00
levlam
52aa76584a Improve TQueue::clear. 2022-11-08 17:27:02 +03:00
levlam
5945cc9b70 Add TQueue::clear. 2022-11-08 17:04:45 +03:00
levlam
ec86b34d55 Don't allow TQueue::run_gc to run for more than 50 milliseconds. 2022-10-13 16:04:24 +03:00
levlam
ec4ae065b0 Simplify TQueue::run_gc. 2022-10-13 15:22:06 +03:00
levlam
2b1314295d Check and fix half of FlatHashMap usages. 2022-02-10 00:59:52 +03:00
levlam
bcc2adeb47 Fix includes and formatting. 2022-02-08 00:04:34 +03:00
Arseny Smirnov
86bceb2972 td: replace most of std::unordered_map usages to td::FlatHashMap 2022-02-07 21:21:31 +01:00
levlam
8085779cdc Update copyright year. 2022-01-01 03:35:39 +03:00
levlam
44a186c7c1 Minor improvements. 2021-10-18 19:26:14 +03:00
levlam
40c5d47717 Make inherited classes final if possible. 2021-07-04 05:58:54 +03:00
levlam
edfa5d1d98 Use final instead of override. 2021-07-03 23:51:36 +03:00
levlam
52c1da0a70 Update copyright year. 2021-01-01 15:57:46 +03:00
levlam
35a9a93fc9 Fix std::...::erase return value usages.
GitOrigin-RevId: d9729ccd619e3b99554f1e1c2262d8826f0a8571
2020-10-08 23:04:40 +03:00
levlam
cb3f390a92 Unify "log event" spelling.
GitOrigin-RevId: a1a491981596c56dbf7541d80ead1ea9f5d5bd04
2020-09-22 02:15:09 +03:00
levlam
3d8d4bcf1c Fix warning.
GitOrigin-RevId: 033adb463f56b8135180dd22d4c48e82b967fe39
2020-08-28 14:53:22 +03:00
levlam
dfd01bf87b Fix from_id check in TQueue.
GitOrigin-RevId: ad52ed5183780b806dcd994bb1a33e67ba508635
2020-08-26 21:36:29 +03:00
levlam
e0caa301a5 TQueue: fix adding already expired events.
GitOrigin-RevId: b78748cd001d9439c9e215b378b76b973a77a79a
2020-08-16 02:57:31 +03:00
levlam
f266aa3912 Minor fixes.
GitOrigin-RevId: a4aacfa1ecab2718475d32bcbd99f9671ba7e982
2020-08-14 22:51:10 +03:00
levlam
fe5bf41980 Minor improvements.
GitOrigin-RevId: 45477784ae1840f217b9394e3d0cc56e1241f9ce
2020-08-07 22:14:42 +03:00
Arseny Smirnov
80d98def74 TQueue: run_gc returns count of deleted events
GitOrigin-RevId: 7cddd57c1c2842eade83aa253209462e33629dc9
2020-08-07 19:36:23 +03:00
Arseny Smirnov
857f981847 TQueue: minor refactoring of gc
GitOrigin-RevId: 4f4d460723a60f075e2a66d2b1269bc8e41927d1
2020-08-07 14:03:39 +03:00
levlam
2097934da5 Optimize TQueue::run_gc, so it can be run arbitrary often.
GitOrigin-RevId: f7fc488cf3682683c0164c557992dbbc4eed9d4d
2020-08-07 06:06:29 +03:00
levlam
5109f43435 Use unix_time in TQueue.
GitOrigin-RevId: d49c0871c7cb1a4315e38a66c198f56cb2b89428
2020-08-06 04:02:54 +03:00
levlam
7187b9c32f Erase the dummy event when new event is pushed to TQueue.
GitOrigin-RevId: 42f310f52cf74ddf32655fe3da42c731ff24e799
2020-07-25 03:11:03 +03:00
levlam
7d8d13606c Use std::map instead of VectorQueue in TQueue.
GitOrigin-RevId: a419aa0c9ee5954f8bf1681e6e4097b3e632fa0c
2020-07-25 00:37:45 +03:00
levlam
2882e96b63 Do not delete queue if there is no callback.
GitOrigin-RevId: d19a6b2c2c5ee517bae5cf809068f413217ca723
2020-07-24 14:03:59 +03:00
levlam
8132c4dfd3 Fix TQueue run_gc statistics.
GitOrigin-RevId: 2311da0ba65e33de466c3f627058ec2a973dcb76
2020-07-24 07:12:43 +03:00
levlam
85ba9e5654 Fix TQueue binlog replaying.
GitOrigin-RevId: 172d70847206253de981d38fed329276b2f778e0
2020-07-24 06:57:48 +03:00
levlam
db29976a90 Check queue constraints in TQueue::do_push.
GitOrigin-RevId: 385d120c8bdee21bb18d97699af4b7b78fa36277
2020-07-24 05:47:31 +03:00
levlam
692b0f18df Drop only one week old empty queues from TQueue.
GitOrigin-RevId: b7ce4c1b4471cfa385ca4d268e8e052db0896ef3
2020-07-24 05:26:25 +03:00
levlam
70534a8aca Add TQueue run_gc statistics.
GitOrigin-RevId: 371d38aa5c59d927b0f1e601f08ac7c7bbbdb137
2020-07-24 02:42:54 +03:00
levlam
060c01ace3 Minor improvements.
GitOrigin-RevId: b4e5073248377d84cb8acdf4a032970ec5cf5df9
2020-07-14 20:54:38 +03:00
Arseny Smirnov
d701e17cc6 close(Promise<>) interface for TQueue and BinlogKeyValue
GitOrigin-RevId: d2c524407888b99c9e6207f74828eb2da29a7720
2020-07-14 19:10:26 +03:00
levlam
32f9e4924f Add limit on total TQueue events size.
GitOrigin-RevId: cd0d77e4b0e2d66d7c5253a6d36bd543bca95bd1
2020-07-13 23:48:15 +03:00
levlam
8872fbf6ac Fix tdutils after merge.
GitOrigin-RevId: 5b9a863e405a9e3782157570156fda71bf2bb589
2020-06-26 02:24:13 +03:00
levlam
a9e95b7f4b Add TQueue::get_size.
GitOrigin-RevId: 20b842bfb145a890e149f80bff56f0fa80785337
2020-06-24 15:11:39 +03:00
levlam
2ed9cb3b75 Minor fixes.
GitOrigin-RevId: ce9058c2075281697cc41de2ab970dd11e189f77
2020-06-13 05:13:11 +03:00