[PR #333] [MERGED] Introduce Task Results #1725

Closed
opened 2026-03-07 22:12:55 +03:00 by kerem · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/hibiken/asynq/pull/333
Author: @hibiken
Created: 10/4/2021
Status: Merged
Merged: 11/5/2021
Merged by: @hibiken

Base: nextHead: feature/task_result


📝 Commits (10+)

  • 3da651f Change TaskMessage.ID type from uuid.UUID to string
  • 61833b0 Add result_ttl and completed_at fields to TaskMessage
  • 40960d6 Add ResultTTL option
  • 1b8ba80 Add CompletedKey and TaskStateCompleted to base package
  • a4e25cb Add RDB.MarkAsComplete method
  • 4c0bbe2 Update processor to handle succeeded message with result_ttl set
  • 79c17b9 Add RDB.DeleteExpiredCompletedTasks
  • 902a34a Add janitor goroutine
  • b105049 Update build workflow config
  • f06404a Add ResultWriter type

📊 Changes

33 files changed (+2099 additions, -846 deletions)

View changed files

📝 .github/workflows/build.yml (+1 -1)
📝 CHANGELOG.md (+4 -0)
📝 README.md (+1 -1)
📝 asynq.go (+76 -12)
📝 client.go (+18 -1)
📝 client_test.go (+34 -0)
📝 go.sum (+25 -0)
📝 inspector.go (+83 -23)
📝 inspector_test.go (+167 -4)
📝 internal/asynqtest/asynqtest.go (+35 -0)
📝 internal/base/base.go (+26 -0)
📝 internal/base/base_test.go (+35 -16)
📝 internal/context/context.go (+1 -1)
📝 internal/context/context_test.go (+0 -1)
📝 internal/proto/asynq.pb.go (+101 -75)
📝 internal/proto/asynq.proto (+10 -1)
📝 internal/rdb/inspect.go (+193 -58)
📝 internal/rdb/inspect_test.go (+316 -52)
📝 internal/rdb/rdb.go (+153 -1)
📝 internal/rdb/rdb_test.go (+321 -3)

...and 13 more files

📄 Description

Closes #265


🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/hibiken/asynq/pull/333 **Author:** [@hibiken](https://github.com/hibiken) **Created:** 10/4/2021 **Status:** ✅ Merged **Merged:** 11/5/2021 **Merged by:** [@hibiken](https://github.com/hibiken) **Base:** `next` ← **Head:** `feature/task_result` --- ### 📝 Commits (10+) - [`3da651f`](https://github.com/hibiken/asynq/commit/3da651fd6d9c87e23142e63c179e28921dcf5a6e) Change TaskMessage.ID type from uuid.UUID to string - [`61833b0`](https://github.com/hibiken/asynq/commit/61833b045f437ffb2a1701ea882570f184dfe6f0) Add result_ttl and completed_at fields to TaskMessage - [`40960d6`](https://github.com/hibiken/asynq/commit/40960d6acf6c2b279eddd2cbbd7746ac9afc56f4) Add ResultTTL option - [`1b8ba80`](https://github.com/hibiken/asynq/commit/1b8ba80a95cbc0d2c401ce863571dec91137e6e5) Add CompletedKey and TaskStateCompleted to base package - [`a4e25cb`](https://github.com/hibiken/asynq/commit/a4e25cba75a92ea6bd7069a2cfe1e9f3a426019d) Add RDB.MarkAsComplete method - [`4c0bbe2`](https://github.com/hibiken/asynq/commit/4c0bbe2998d8f75df17d4520bcb790c08d5bbbdd) Update processor to handle succeeded message with result_ttl set - [`79c17b9`](https://github.com/hibiken/asynq/commit/79c17b9ee9072115e06c8d0e5a2eeaa6063e7bad) Add RDB.DeleteExpiredCompletedTasks - [`902a34a`](https://github.com/hibiken/asynq/commit/902a34a308859ae6249e4f4c74b4d5ec443f57f6) Add janitor goroutine - [`b105049`](https://github.com/hibiken/asynq/commit/b10504998a3e48a7c4c583d13089bde45ecb335e) Update build workflow config - [`f06404a`](https://github.com/hibiken/asynq/commit/f06404a9a84513f6345d54cc373a04d4d93b406d) Add ResultWriter type ### 📊 Changes **33 files changed** (+2099 additions, -846 deletions) <details> <summary>View changed files</summary> 📝 `.github/workflows/build.yml` (+1 -1) 📝 `CHANGELOG.md` (+4 -0) 📝 `README.md` (+1 -1) 📝 `asynq.go` (+76 -12) 📝 `client.go` (+18 -1) 📝 `client_test.go` (+34 -0) 📝 `go.sum` (+25 -0) 📝 `inspector.go` (+83 -23) 📝 `inspector_test.go` (+167 -4) 📝 `internal/asynqtest/asynqtest.go` (+35 -0) 📝 `internal/base/base.go` (+26 -0) 📝 `internal/base/base_test.go` (+35 -16) 📝 `internal/context/context.go` (+1 -1) 📝 `internal/context/context_test.go` (+0 -1) 📝 `internal/proto/asynq.pb.go` (+101 -75) 📝 `internal/proto/asynq.proto` (+10 -1) 📝 `internal/rdb/inspect.go` (+193 -58) 📝 `internal/rdb/inspect_test.go` (+316 -52) 📝 `internal/rdb/rdb.go` (+153 -1) 📝 `internal/rdb/rdb_test.go` (+321 -3) _...and 13 more files_ </details> ### 📄 Description Closes #265 --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
kerem 2026-03-07 22:12:55 +03:00
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/asynq#1725
No description provided.