1ca213ee7c
[ #12 ] mclock: Fix deadlock caused by mclock.Close
...
DCO action / DCO (pull_request) Successful in 21s
Vulncheck / Vulncheck (pull_request) Successful in 42s
Pre-commit hooks / Pre-commit (pull_request) Successful in 1m14s
Tests and linters / Lint (pull_request) Successful in 1m14s
Tests and linters / Run gofumpt (pull_request) Successful in 1m10s
Tests and linters / Staticcheck (pull_request) Successful in 1m17s
Tests and linters / Tests (pull_request) Successful in 1m6s
Tests and linters / Tests with -race (pull_request) Successful in 1m22s
Tests and linters / gopls check (pull_request) Successful in 1m29s
Deadlock scenario:
- mclock closed by `Close` method, it locks mutex and calls `clock.close`
- clock starts `scheduleRequest` goroutine, it tries to lock mutex
- `clock.Close` waits for all goroutines
Signed-off-by: Dmitrii Stepanov <d.stepanov@yadro.com>
2025-03-20 10:31:15 +03:00
346752477b
[ #12 ] mclock: Fix timer-based scheduling
...
DCO action / DCO (pull_request) Successful in 21s
Vulncheck / Vulncheck (pull_request) Successful in 34s
Pre-commit hooks / Pre-commit (pull_request) Successful in 1m13s
Tests and linters / Tests with -race (pull_request) Successful in 1m14s
Tests and linters / Run gofumpt (pull_request) Successful in 1m13s
Tests and linters / gopls check (pull_request) Successful in 1m17s
Tests and linters / Lint (pull_request) Successful in 1m22s
Tests and linters / Staticcheck (pull_request) Successful in 1m18s
Tests and linters / Tests (pull_request) Successful in 1m27s
Let's assume that there are two requests in the queue with execution time t1 and t2.
The timer is set to t1. The timer is triggered, schedules the t1 request,
calculates the time for the next timer t2 to be triggered.
But it doesn't schedules timer to this time because of the
`q.timeBasedScheduleTs > nextTs` check.
Signed-off-by: Dmitrii Stepanov <d.stepanov@yadro.com>
2025-03-19 17:12:00 +03:00
3e7ca94035
Revert "[ #7 ] mclock: Add tag stat"
...
DCO action / DCO (pull_request) Successful in 26s
Vulncheck / Vulncheck (pull_request) Successful in 38s
Tests and linters / Run gofumpt (pull_request) Successful in 1m9s
Pre-commit hooks / Pre-commit (pull_request) Successful in 1m18s
Tests and linters / Lint (pull_request) Successful in 1m16s
Tests and linters / Staticcheck (pull_request) Successful in 1m18s
Tests and linters / gopls check (pull_request) Successful in 1m33s
Tests and linters / Tests (pull_request) Successful in 1m40s
Tests and linters / Tests with -race (pull_request) Successful in 1m52s
Vulncheck / Vulncheck (push) Successful in 39s
Pre-commit hooks / Pre-commit (push) Successful in 1m15s
Tests and linters / Run gofumpt (push) Successful in 1m17s
Tests and linters / Lint (push) Successful in 1m24s
Tests and linters / Staticcheck (push) Successful in 1m20s
Tests and linters / Tests with -race (push) Successful in 1m36s
Tests and linters / gopls check (push) Successful in 1m42s
Tests and linters / Tests (push) Successful in 1m54s
This reverts commit 25102d1e1a
.
Signed-off-by: Dmitrii Stepanov <d.stepanov@yadro.com>
2025-03-10 16:58:38 +03:00
25102d1e1a
[ #7 ] mclock: Add tag stat
...
Vulncheck / Vulncheck (push) Successful in 33s
Pre-commit hooks / Pre-commit (push) Successful in 1m17s
Tests and linters / Tests (push) Successful in 1m16s
Tests and linters / Run gofumpt (push) Successful in 1m16s
Tests and linters / gopls check (push) Successful in 1m18s
Tests and linters / Lint (push) Successful in 1m28s
Tests and linters / Staticcheck (push) Successful in 1m24s
Tests and linters / Tests with -race (push) Successful in 1m41s
Signed-off-by: Dmitrii Stepanov <d.stepanov@yadro.com>
2025-02-27 07:29:15 +00:00
f4d8ebf13d
[ #1 ] mclock: Add assert package
...
DCO action / DCO (pull_request) Successful in 26s
Vulncheck / Vulncheck (pull_request) Successful in 29s
Pre-commit hooks / Pre-commit (pull_request) Successful in 1m9s
Tests and linters / gopls check (pull_request) Successful in 1m5s
Tests and linters / Tests (pull_request) Successful in 1m3s
Tests and linters / Lint (pull_request) Successful in 1m13s
Tests and linters / Run gofumpt (pull_request) Successful in 1m12s
Tests and linters / Staticcheck (pull_request) Successful in 1m13s
Tests and linters / Tests with -race (pull_request) Successful in 1m21s
Tests and linters / Run gofumpt (push) Successful in 32s
Vulncheck / Vulncheck (push) Successful in 36s
Tests and linters / Staticcheck (push) Successful in 49s
Pre-commit hooks / Pre-commit (push) Successful in 1m10s
Tests and linters / Lint (push) Successful in 1m12s
Tests and linters / Tests (push) Successful in 1m15s
Tests and linters / Tests with -race (push) Successful in 1m17s
Tests and linters / gopls check (push) Successful in 1m20s
Signed-off-by: Dmitrii Stepanov <d.stepanov@yadro.com>
2025-01-28 11:35:54 +03:00
9a48a50220
[ #1 ] mclock: Refactor scheduleRequest
...
Split to `scheduleRequest` and `scheduleRequestUnsafe`.
Signed-off-by: Dmitrii Stepanov <d.stepanov@yadro.com>
2025-01-28 11:23:07 +03:00
f1cb5b40d5
[ #1 ] mclock: Use time.Duration
for idle timeout
...
Signed-off-by: Dmitrii Stepanov <d.stepanov@yadro.com>
2025-01-28 11:20:54 +03:00
47559a8d16
[ #1 ] mclock: Refactor: split code between files
...
Signed-off-by: Dmitrii Stepanov <d.stepanov@yadro.com>
2025-01-28 11:20:53 +03:00
54b4bf7cc1
[ #1 ] mclock: Fix time based scheduling
...
Signed-off-by: Dmitrii Stepanov <d.stepanov@yadro.com>
2025-01-28 11:20:53 +03:00
0dccab22c2
[ #1 ] mclock: Initial implementation
...
Signed-off-by: Dmitrii Stepanov <d.stepanov@yadro.com>
2025-01-28 11:20:51 +03:00