Comments (6)
It takes an Array of Arrays, one Array for each job's args: [[1], [2], [3]]
from sidekiq.
It takes an Array of Arrays, one Array for each job's args:
[[1], [2], [3]]
Yes, thanks, that is what I am passing:
the job's args is [1, 2, 3]
And I am passing an array of size one: [[1, 2, 3]]
from sidekiq.
Then I think you are missing an Array?
[[[1,2,3]]]
from sidekiq.
Then I think you are missing an Array?
[[[1,2,3]]]
Thanks - I guess that could be a workaround as well - but basically my normal usecase is a whole bunch of ids:
args = [[1, 2, 3...], [4, 5, 6...], [7, 8, 9 ...]]
perform_bulk(args)
but when we are testing with a smaller amount of IDs, we'd have to double nest the array?
[[[1,2,3]]]
from sidekiq.
I think you're still missing an Array because your job only takes one argument: an array. You want this:
[ # the set of jobs
[ # the first job
[1, 2, 3...] # the first argument
],
[[4, 5, 6...]],
[[7, 8, 9 ...]],
]
from sidekiq.
You are right, thank you. Sorry for the back and forth, I'm not sure what I was testing earlier with my larger set of args but it wasn't correct.
Solved by adding a zip
call:
previously:
my_id_args = my_ids.in_groups_of(BATCH_SIZE, false)
MyWorker.perform_bulk(my_id_args)
now:
my_ids.in_groups_of(BATCH_SIZE, false).zip
MyWorker.perform_bulk(my_id_args)
from sidekiq.
Related Issues (20)
- Periodic jobs stopped working HOT 1
- Early parent 'complete' callback fired in nested batch example HOT 4
- [Wiki Issue] Sidekiq testing wiki page has outdated testing instructions for Batches HOT 2
- Configuration to disable "start" & "done" logs HOT 3
- Not thread local
- 7.3.0+: Issue when running sidekiq-scheduler specs against 2.7 HOT 3
- Retry Now in the retries tab does not increase the retry count HOT 6
- Sidekiq 7.x on Ruby 2.7 crashes on `hash.except("at")` HOT 2
- Batch tests fail without running Redis instance available HOT 3
- Job picked up from the queue multiple times over a longer time HOT 12
- Running sidekiqswarm on docker container HOT 8
- Push bulk of multiple batches with jobs HOT 3
- Job interruptions are confusing Sidekiq Web HOT 3
- Feature Request: Additional Colorblind-friendly Web UI Colors HOT 2
- Sidekiq.transactional_push! doesn't work with multiple databases HOT 1
- Lots of `b-#{bid}-notify` keys with no expiration in my Redis instance HOT 5
- Massive number of Redis lmove operations after upgrading to Sidekiq 7.2 HOT 12
- uninitialized constant Sidekiq::Component after upgrading from 7.2.4 to 7.3.0 HOT 2
- undefined method broadcast for class ActiveSupport::Logger using sidekiq 7.3.0 with rails 7.1.3.4 in Docker HOT 5
- The testing "jobs" obj is empty when adding jobs to at batch using push_bulk and requiring 'sidekiq/testing' in a helper file HOT 2
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 sidekiq.