[PR #2] [MERGED] Use Lua script to make multiple redis commands atomic #530

Closed
opened 2026-03-02 05:38:10 +03:00 by kerem · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/hibiken/asynq/pull/2
Author: @hibiken
Created: 11/26/2019
Status: Merged
Merged: 11/26/2019
Merged by: @hibiken

Base: masterHead: feature/lua


📝 Commits (9)

  • 4aa5078 Add (*rdb).forward method using lua script
  • 737de89 Refactor rdb_test.go
  • faa9b6e Rename (*rdb).push to enqueue
  • 199dcf8 Use pipeline for enqueue
  • 810c40b Refactor dequeue test
  • cff5e67 Refactor (*rdb).forward test
  • d2a6cc1 Use (*rdb).forward in poller
  • 4fd82c5 Refactor (*rdb).moveAll test
  • 97b96f6 Use lua script to implement (*rdb).moveAll

📊 Changes

4 files changed (+252 additions, -148 deletions)

View changed files

📝 client.go (+1 -1)
📝 poller.go (+2 -18)
📝 rdb.go (+41 -62)
📝 rdb_test.go (+208 -67)

📄 Description

Related changes

  • Refactored existing tests to use table-driven test style

🔄 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/2 **Author:** [@hibiken](https://github.com/hibiken) **Created:** 11/26/2019 **Status:** ✅ Merged **Merged:** 11/26/2019 **Merged by:** [@hibiken](https://github.com/hibiken) **Base:** `master` ← **Head:** `feature/lua` --- ### 📝 Commits (9) - [`4aa5078`](https://github.com/hibiken/asynq/commit/4aa5078dc45e95bf680685f9109fce92f5d74bbd) Add (*rdb).forward method using lua script - [`737de89`](https://github.com/hibiken/asynq/commit/737de898ebfc51cb848c1341b230f925c41d79fe) Refactor rdb_test.go - [`faa9b6e`](https://github.com/hibiken/asynq/commit/faa9b6ee22a6d1a0efbda2c6d422dea36234b5a8) Rename (*rdb).push to enqueue - [`199dcf8`](https://github.com/hibiken/asynq/commit/199dcf8fdb89d030e0cb6b0bea59c0879e6d77f7) Use pipeline for enqueue - [`810c40b`](https://github.com/hibiken/asynq/commit/810c40bd54be2b509e0651e4378c54261f57a7cf) Refactor dequeue test - [`cff5e67`](https://github.com/hibiken/asynq/commit/cff5e67018911026692ce7dee2fe672b25bfe1f9) Refactor (*rdb).forward test - [`d2a6cc1`](https://github.com/hibiken/asynq/commit/d2a6cc127d5fc6980d27b26f27408f4717c8c413) Use (*rdb).forward in poller - [`4fd82c5`](https://github.com/hibiken/asynq/commit/4fd82c59754a4027d5f11637125bda3d5eb4b9f9) Refactor (*rdb).moveAll test - [`97b96f6`](https://github.com/hibiken/asynq/commit/97b96f6992a477f25b86b5af8340ae6218a38c67) Use lua script to implement (*rdb).moveAll ### 📊 Changes **4 files changed** (+252 additions, -148 deletions) <details> <summary>View changed files</summary> 📝 `client.go` (+1 -1) 📝 `poller.go` (+2 -18) 📝 `rdb.go` (+41 -62) 📝 `rdb_test.go` (+208 -67) </details> ### 📄 Description Related changes - Refactored existing tests to use table-driven test style --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
kerem 2026-03-02 05:38:10 +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#530
No description provided.