Reduce unnecessary DB queries for Actions tasks #219

Merged
wolfogre merged 12 commits from sillyguodong/act_runner:feature/fetch_task_with_index into main 2023-07-25 03:25:52 +00:00
Member

implement: https://github.com/go-gitea/gitea/issues/24544

Changes:

  • Add a global variable tasksVersion to store the lastest version number which returned by Gitea.
  • Pass tasksVersion to Gitea when invoking FetchTask.
  • If there is no task in the FetchTask response, store the version from the FetchTask response into tasksVersion variable.
  • If there is a task in the FetchTask response, set tasksVersion to zero to focre query db in next FetchTask request.

Related:

implement: https://github.com/go-gitea/gitea/issues/24544 Changes: - Add a global variable `tasksVersion` to store the lastest version number which returned by Gitea. - Pass `tasksVersion` to Gitea when invoking `FetchTask`. - If there is no task in the `FetchTask` response, store the version from the `FetchTask` response into `tasksVersion` variable. - If there is a task in the `FetchTask` response, set `tasksVersion` to zero to focre query db in next `FetchTask` request. Related: - Protocol: https://gitea.com/gitea/actions-proto-def/pulls/10 - Gitea side: https://github.com/go-gitea/gitea/pull/25199
sillyguodong added 1 commit 2023-05-29 02:01:46 +00:00
fetch task with index
Some checks failed
checks / check and test (pull_request) Failing after 1m3s
cef297af9c
sillyguodong added 1 commit 2023-06-07 02:19:33 +00:00
use version
Some checks failed
checks / check and test (pull_request) Failing after 50s
06d40a2c3c
sillyguodong added 1 commit 2023-06-07 06:02:54 +00:00
Merge branch 'main' into feature/fetch_task_with_index
Some checks failed
checks / check and test (pull_request) Failing after 41s
333d82258a
sillyguodong added 1 commit 2023-06-28 07:19:25 +00:00
Merge branch 'main' into feature/fetch_task_with_index
Some checks failed
checks / check and test (pull_request) Failing after 53s
76af298aa3
sillyguodong added 1 commit 2023-06-28 07:27:57 +00:00
go mod
All checks were successful
checks / check and test (pull_request) Successful in 1m18s
c3c6747bef
sillyguodong changed title from WIP: Reduce unnecessary DB queries for Actions tasks to Reduce unnecessary DB queries for Actions tasks 2023-06-30 03:57:28 +00:00
sillyguodong added 1 commit 2023-06-30 04:04:37 +00:00
Merge branch 'main' into feature/fetch_task_with_index
All checks were successful
checks / check and test (pull_request) Successful in 1m15s
b3ddee05c9
wolfogre requested changes 2023-07-06 07:42:25 +00:00
Dismissed
wolfogre dismissed wolfogre’s review 2023-07-06 07:43:19 +00:00
Reason:

Test

lunny approved these changes 2023-07-23 14:24:24 +00:00
sillyguodong added 1 commit 2023-07-24 05:18:28 +00:00
Merge branch 'main' into feature/fetch_task_with_index
All checks were successful
checks / check and test (pull_request) Successful in 1m46s
bf75f0c248
sillyguodong added 2 commits 2023-07-24 06:10:26 +00:00
zero
All checks were successful
checks / check and test (pull_request) Successful in 39s
5beaa5622a
sillyguodong added 1 commit 2023-07-24 07:11:09 +00:00
improve
All checks were successful
checks / check and test (pull_request) Successful in 1m5s
e5461e3ccb
sillyguodong added 1 commit 2023-07-24 07:28:11 +00:00
Merge branch 'main' into feature/fetch_task_with_index
All checks were successful
checks / check and test (pull_request) Successful in 40s
27ea804e21
sillyguodong added 1 commit 2023-07-25 01:33:42 +00:00
comment
All checks were successful
checks / check and test (pull_request) Successful in 41s
b8454234f8
wolfogre approved these changes 2023-07-25 03:19:53 +00:00
wolfogre merged commit 12999b61dd into main 2023-07-25 03:25:52 +00:00
Sign in to join this conversation.
No description provided.