Merged
Conversation
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## master #1056 +/- ##
==========================================
- Coverage 71.39% 71.23% -0.16%
==========================================
Files 178 180 +2
Lines 12587 12705 +118
==========================================
+ Hits 8986 9051 +65
- Misses 3212 3264 +52
- Partials 389 390 +1 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
There was a problem hiding this comment.
⚠️ Performance Alert ⚠️
Possible performance regression was detected for benchmark.
Benchmark result of this commit is worse than the previous benchmark result exceeding threshold 1.50.
| Benchmark suite | Current: f95d1af | Previous: 1d20e34 | Ratio |
|---|---|---|---|
BenchmarkFile_ReadWrite |
342772 ns/op 6186 B/op 97 allocs/op |
203254 ns/op 6185 B/op 97 allocs/op |
1.69 |
BenchmarkFile_ReadWrite - ns/op |
342772 ns/op |
203254 ns/op |
1.69 |
This comment was automatically generated by workflow using github-action-benchmark.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
📑 Description
This pull request introduces significant enhancements and refactoring to the queue system, including the addition of new functionality, error handling improvements, and code restructuring for better modularity. The most notable changes include the implementation of a
Connectionmethod in the queue interface, the addition of aQueueRetryCommandfor retrying failed jobs, and the extraction of utility functions into a dedicatedutilspackage.New Features and Functionality:
Added a
Connectionmethod to theQueueinterface, allowing retrieval of a driver instance by connection name. This includes corresponding implementations inqueue/application.goand mocks inmocks/queue/Queue.go. [1] [2] [3]Introduced the
QueueRetryCommandinqueue/console/queue_retry_command.go, enabling retry of failed queue jobs via a console command. This includes features such as retrying jobs by queue or UUID and handling errors during retries.Error Handling Improvements:
errors/list.gofor better granularity when handling queue-related failures, such asQueueFailedJobNotFound,QueueFailedToDeleteFailedJob, andQueueNoRetryableJobsFound.Code Refactoring:
Moved task-related utility functions (e.g.,
TaskToJson,JsonToTask,ConvertArgs) from the main queue package to a newutilspackage for better separation of concerns. This change impacts multiple files, includingqueue/driver_database.go,queue/driver_database_job.go, and their corresponding test files. [1] [2] [3] [4]Renamed
queue/utils.gotoqueue/utils/convert.goand updated all references accordingly. [1] [2]Models and Data Handling:
JobandFailedJobstructs inqueue/models/job.goto encapsulate database representations of queue jobs. These models include helper methods for incrementing attempts and updating timestamps.✅ Checks