Comments (2)
@adamalbrecht @jwoertink if you're still interested, please have a look at #117. Thank you!
from mosquito.
For anyone that happens to pop in here, I sort of monkey-patched for my case.
# spec/support/mosquito_helper.cr
module Mosquito
abstract class QueuedJob < Job
ENQUEUED_JOBS = [] of String
def enqueue
ENQUEUED_JOBS << self.class.name
end
end
end
# spec/your_thing_spec.cr
describe "Sending jobs" do
before_each do
Mosquito::QueuedJob::ENQUEUED_JOBS.clear
end
it "sends a job" do
MyCode.run
Mosquito::QueuedJob::ENQUEUED_JOBS.should contain("MyJob")
end
end
but yes, an official way would be awesome.
from mosquito.
Related Issues (20)
- Leaky Bucket Queue?
- Array support for params (or better error message...) HOT 5
- mosquito is completely broken after 1.0.1 HOT 5
- Graceful shutdown when receiving the TERM signal HOT 7
- High CPU usage HOT 9
- Make executor count configurable HOT 1
- Ability to specify a redis connection pool from an application, instead of making mosquito handle it all
- Add a before/after enqueue set of hooks
- Add hook for job-interrupted, and improve scheduling logic to requeue a job if it needs to be terminated
- unknown command `lmove` HOT 6
- Add ability to configure global Redis namespace prefix HOT 1
- Unexpected argument when using `-Dno_number_autocast` HOT 1
- Crash - ERR too many keys to fetch, please use SCAN
- Should Periodic Jobs include a way to manually enqueue them?
- Provide API for inspecting the backend data
- Provide a way to detect and clean up jobs which were started but never finished HOT 1
- Redis RPOPLPUSH command is deprecated since Redis 6.2
- Provide an easy way to cancel a job without it being rescheduled
- Support error handlers HOT 3
- Update runner to use time::span instead of bare seconds, and monotonic for the idle wait
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from mosquito.