https://github.com/mperham/sidekiq

sort by:
Revision Author Date Message Commit Date
fc7b7d8 bump, release 19 April 2022, 20:56:50 UTC
152c3d8 fix code formatting 08 April 2022, 19:08:50 UTC
653c398 Revert erroneous merge of XA commits, remove Gemfile.lock 08 April 2022, 19:07:41 UTC
ea67861 remove .lock 08 April 2022, 18:55:51 UTC
f404189 fix flaky test 08 April 2022, 18:55:34 UTC
289fa24 logic cleanup 08 April 2022, 18:55:34 UTC
4b0b1d5 Remove jargon from module name 08 April 2022, 18:55:34 UTC
e2fb43b Remove a_c_e as a direct dependency 08 April 2022, 18:55:34 UTC
1e01328 fix breakage 08 April 2022, 18:55:34 UTC
51697b8 Prototype transaction-aware Sidekiq::Client extension, #5239 08 April 2022, 18:55:34 UTC
637e509 Enable live poll from url params (#5275) * Turn on Polling if url has param poll=true. poll=false does nothing. This is because the page is reloaded each time polling happens, and the url param may be out of sync with the current status. One solution would be to rewrite the URL each time the polling status changes, but that seems unnecessary. 04 April 2022, 22:20:09 UTC
d0a4b1f Merge pull request #5274 from dominikb/main Use Base64.urlsafe_* like Rake::Protection::AuthenticityToken 04 April 2022, 15:16:26 UTC
572f703 Use Base64.urlsafe_* like Rake::Protection::AuthenticityToken 02 April 2022, 17:47:26 UTC
213977c Add missing 5.2.10 changes 31 March 2022, 15:12:01 UTC
c1b8eba changes 30 March 2022, 22:06:45 UTC
f3c8c34 Merge pull request #5270 from pmichaeljones/contributing_for_beginners added beginner's guide to contributing and made RSS link target blank 30 March 2022, 15:03:04 UTC
d1d8c52 add example 30 March 2022, 14:18:52 UTC
c70c19d minimize sqlite db files 30 March 2022, 14:14:07 UTC
2781be1 added beginner's guide to contributing and made RSS link target blank 30 March 2022, 14:00:56 UTC
fe07290 Add Sidekiq.via 30 March 2022, 00:23:50 UTC
cf7b067 Merge pull request #5259 from minter/adjust-systemd-configuration 25 March 2022, 14:38:32 UTC
34f61e8 Change systemd restart method to "always" I'm running Sidekiq 6.4.1 on an Ubuntu 20.04 system with Ruby 3.1.1 installed via Snap for a Rails 7 application. Using this systemd template, I noticed something odd when deploying with Capistrano. When my cap script ran `sudo systemctl restart sidekiq`, the Sidekiq process would restart, briefly go active, then go inactive and stop running. I would need to SSH in and manually do a `systemctl restart sidekiq` in order to get the process back up and running. With some experimentation, I found that changing the `Restart` configuration from `on-failure` to `always` seems to do the trick. Now, when the Sidekiq process goes inactive, it properly restarts and stays restarted. I'm not 100% sure of the "why" behind what's going on, but this change seems to be effective and I have not noticed any side effects. Documentation of previous behavior Prior to deploy (process running) ``` root@stage-worker01:~# systemctl status sidekiq ● sidekiq.service - sidekiq Loaded: loaded (/lib/systemd/system/sidekiq.service; enabled; vendor prese> Active: active (running) since Thu 2022-03-24 16:34:32 UTC; 51s ago Main PID: 118856 (bundle) Tasks: 30 (limit: 1120) Memory: 291.2M CGroup: /system.slice/sidekiq.service └─118856 sidekiq 6.4.1 staging [0 of 20 busy] ``` Immediately post deploy (process restarting) ``` root@stage-worker01:~# systemctl status sidekiq ● sidekiq.service - sidekiq Loaded: loaded (/lib/systemd/system/sidekiq.service; enabled; vendor prese> Active: activating (start) since Thu 2022-03-24 16:38:35 UTC; 9s ago Main PID: 119572 (bundle) Tasks: 0 (limit: 1120) Memory: 43.4M CGroup: /system.slice/sidekiq.service ‣ 119572 /var/www/sox/staging/shared/bundle/ruby/3.1.0/bin/sidekiq> ``` After deploy (process started) ``` Mar 24 16:38:35 stage-worker01.suggestionox.com systemd[1]: Starting sidekiq... root@stage-worker01:~# systemctl status sidekiq ● sidekiq.service - sidekiq Loaded: loaded (/lib/systemd/system/sidekiq.service; enabled; vendor prese> Active: active (running) since Thu 2022-03-24 16:38:45 UTC; 3s ago Main PID: 119572 (bundle) Tasks: 0 (limit: 1120) Memory: 43.4M CGroup: /system.slice/sidekiq.service ‣ 119572 sidekiq 6.4.1 staging [0 of 20 busy] Mar 24 16:38:35 stage-worker01.suggestionox.com systemd[1]: Starting sidekiq... Mar 24 16:38:45 stage-worker01.suggestionox.com systemd[1]: Started sidekiq. ``` Failure (process inactive) ``` root@stage-worker01:~# systemctl status sidekiq ● sidekiq.service - sidekiq Loaded: loaded (/lib/systemd/system/sidekiq.service; enabled; vendor prese> Active: inactive (dead) since Thu 2022-03-24 16:38:56 UTC; 2s ago Process: 119572 ExecStart=/usr/bin/env bundle exec sidekiq -e staging (code> Main PID: 119572 (code=exited, status=0/SUCCESS) Mar 24 16:38:35 stage-worker01.suggestionox.com systemd[1]: Starting sidekiq... Mar 24 16:38:45 stage-worker01.suggestionox.com systemd[1]: Started sidekiq. Mar 24 16:38:56 stage-worker01.suggestionox.com systemd[1]: sidekiq.service: Su> ``` 24 March 2022, 16:53:37 UTC
dc3fa27 Use bundle add instead (#5251) 21 March 2022, 15:34:43 UTC
a8ed20a Prevent stray polling interval from running and prevent duplicate event listeners (#5247) Related to: https://github.com/mperham/sidekiq/pull/5230 ### Bug #1: Multiple event listeners are added to elements When adding event listeners to elements, Javascript will generally prevent duplicating the listener if the callback function is named. Anonymous functions aren't tracked the same way. Javascript will continue to add an event listener every time the polling happens. This commit names those functions where the listeners are added to elements outside of the "page" `div`. The duplicate event listeners caused some odd behavior: 1. Clicking in the "Stop Polling" caused a single GET call to the server for each event listener on the element. This will be problematic if someone leaves the polling on for an extended period of time. 2. It would some times cause the "Stop Polling" functionality to not stop polling. #### How to duplicate: 1. Open the page inspector from the developer tools of your browser. 2. Click on the "event" button next to the "Live Poll" button in the inspector. You'll see that there's only one event listener. 3. After the page does a poll, click on it again and you'll now see two event listeners with the same function. 4. Click on the stop polling button 5. Look at your server logs and you'll see a single request per event listener ### Bug #2: Ghost interval continues polling after clicking "Stop Polling" Every time the `addListeners` function was called, it would call the `scheduleLivePoll()` function and setup a new `setTimeout`. Thus, when you clicked on the "Stop Polling" button, it would continue to poll because of a stray `setTimeout`. The only way to stop the polling was to refresh. This commit prevents the function from running if a timeout already exists. #### How to duplicate: 1. All the UI to poll for 30 seconds 2. Clear your server logs 3. Click on "Stop Polling" 4. Watch your server logs and you'll see the same polling request continue to come in every five or so seconds. 17 March 2022, 23:13:07 UTC
b83c8e3 bump part II 17 March 2022, 17:45:09 UTC
b473cfa bump 17 March 2022, 17:42:58 UTC
a8c4966 Move payload json verification after middleware, fixes #5246 17 March 2022, 17:42:33 UTC
e2c3e2c Fix code formatting issues 14 March 2022, 19:16:36 UTC
ba557da Refactor recent client changes I find `push` is easier to read this way. push_bulk is quite complex and adds a net-negative layer of abstraction. 14 March 2022, 19:16:15 UTC
44a5bb3 Add pry for debugging 14 March 2022, 19:01:44 UTC
7060413 Fix for running client test standalone 11 March 2022, 18:10:57 UTC
20cdf68 Improve compatibility with Semantic Logger (#5238) Semantic Logger returns Symbol for `#level`: ``` [1] pry(main)> SemanticLogger[Sidekiq].level => :debug ``` so current code fails with ``` [2] pry(main)> Sidekiq.logger = SemanticLogger[Sidekiq] => #<SemanticLogger::Logger:0x00007f1d27984a18 @filter=nil, @level=nil, @level_index=nil, @name="Sidekiq"> [3] pry(main)> Sidekiq.logger.debug? ArgumentError: comparison of Symbol with 0 failed from /home/ojab/.rbenv/versions/3.1.1/lib/ruby/gems/3.1.0/gems/sidekiq-6.4.1/lib/sidekiq/logger.rb:39:in `<=' ``` Calling `#{level}?` methods on the logger directly instead of comparing `#level` with integer fixes that. 10 March 2022, 17:20:18 UTC
70da442 Catch non ok response codes and set the status to error and log the error. (#5236) Co-authored-by: John Bolliger <john.bolliger@mx.com> 10 March 2022, 00:21:13 UTC
10598b5 Surface exact job class name in complex argument error message (#5235) * Surface exact job class name in complex argument error message * Update job_util.rb * Update param for ActiveJob arg serialization failure Co-authored-by: Mike Perham <mperham@gmail.com> 09 March 2022, 19:36:32 UTC
261368d chhhhhanges 04 March 2022, 18:17:02 UTC
fc3c1be Add ent? for completeness, unused at the moment 04 March 2022, 18:16:42 UTC
9984157 changes 04 March 2022, 17:44:24 UTC
fde3cde Add event listeners after reload (#5230) * Add event listeners after reload. Fixes #5184 * Remove redundant fuzzy times update 04 March 2022, 17:35:02 UTC
5776c7a standard:fix the testsuite codebase, no functional changes 03 March 2022, 20:51:10 UTC
e7d154e Remove "worker" from codebase where possible 03 March 2022, 20:37:25 UTC
7672f05 Ignore Docker config in git (#5223) 27 February 2022, 18:55:23 UTC
a3b6679 Avoid mutating ARGV (#5222) 26 February 2022, 16:33:19 UTC
4ce86cd ignore dev.log 25 February 2022, 16:06:37 UTC
3b9058c #5211 22 February 2022, 21:13:27 UTC
091a77f Add perform_sync alias, fixes #5208 22 February 2022, 16:08:03 UTC
6a6fda3 Don’t document this 16 February 2022, 01:16:05 UTC
7cd97b4 Remove parallel code paths caused by "push" and "push_bulk" (#5182) * Remove parallel code paths caused by "push" and "push_bulk" Fixes #5158 * Refactor where jid is generated * Hardcode client class * Make generate_jid private * Build client outside the loop 16 February 2022, 01:14:45 UTC
0020086 Exit sidekiqmon with non-zero exit code if an error occurs (#5196) 15 February 2022, 15:05:07 UTC
5bfaeea Always use String keys with setter hash, fixes #5192 09 February 2022, 16:42:18 UTC
eab794f Do not fix the width of the navigation status bar (#5191) * Do not fix the width * change to inline 09 February 2022, 03:39:44 UTC
dce4b74 oops, wait_readable misuse, fixes #5190 09 February 2022, 00:55:04 UTC
a150c7a chhhanges 08 February 2022, 16:18:33 UTC
e59f1e5 Cleanups for sidekiqload (#5136) * Simplify the argument creation in sidekiqload * The toxiproxy gem is part of the Gemfile :load_test group * No need to mention it to install manually. Co-authored-by: Mike Perham <mperham@gmail.com> 07 February 2022, 20:34:05 UTC
00ae6a7 Update comm changes 07 February 2022, 20:10:36 UTC
188c878 fix #5186 07 February 2022, 15:19:41 UTC
bc7389d Further improve tests related to bulk scheduling of jobs (#5171) * Use realistic values in scheduling tests * Add one more failing test case * Add failing test for regular push * Remove the new tests as they expect too much 05 February 2022, 22:25:42 UTC
6bfcf58 Use Kernel.warn for deprecation of delay extension. (#5185) This allows disabling the console output via RUBYOPT in certain contexts where it's desirable to keep console output clean without having to change log level. (e.g. parallel builds in CI) 05 February 2022, 20:46:25 UTC
556bb6e Revert to Rails 6.x, need to support Ruby 2.6 04 February 2022, 22:13:49 UTC
af669eb Update dev dependencies, fix issues 04 February 2022, 22:06:08 UTC
bb2f10f Fix another pipeline block warning 04 February 2022, 20:06:16 UTC
72f0ddd Use new terminology in examples (#5175) 03 February 2022, 16:39:24 UTC
83201e9 Fix lingering command pipelining to Redis instance (#5173) Related to #5139. Redis was still throwing deprecation warnings for the `conn.expire` call. 03 February 2022, 16:30:44 UTC
d5bbb64 chhhhanges 02 February 2022, 22:27:23 UTC
e786e1c Dont set enqueued_at as we may be scheduling the jobs, see #5162 02 February 2022, 22:18:01 UTC
9627cbb Reconnect on known errors after failover when pushing jobs to Redis (#5159) In a Redis cluster setup, failovers will happen. In these cases a `Redis::CommandError` can be raised for different reasons, for example when the server becomes a replica, when there is a "Not enough replicas" error from the primary, or when a blocking command is force-unblocked. These errors can occur when pushing a job to Redis, so it needs to reconnect to the current master node and retry. Otherwise, these jobs are lost. The retry logic is similar to the implementation for `Sidekiq.redis`. 02 February 2022, 18:16:44 UTC
7e54709 Add failing test for scheduling in bulk and enqueued_at (#5162) 01 February 2022, 23:04:34 UTC
38f4a93 Add better contributing guidelines (#5166) Closes #5161 01 February 2022, 20:51:52 UTC
cd553fa revert kwarg support 31 January 2022, 21:17:46 UTC
b561951 Revert "Fix an error when job was enqueued without kwargs (#5138) (#5142)" This reverts commit 24fb5d3e50c072913733868b9131d8d5f5238b1f. 31 January 2022, 21:15:46 UTC
10e7feb Add keyword arguments handler in Sidekiq::JobRecord#display_args (#5134) * Add keyword arguments handler in Sidekiq::JobRecord#display_args * Update Sidekiq::JobRecord#display_args kwargs's presence check so that we are not dependent on Rails. 29 January 2022, 17:04:29 UTC
df20201 Fixing width of status span to be large enough for 'active' to reduce jump in nav bar when switching (#5155) 29 January 2022, 16:20:56 UTC
17c5214 Fix build after bumping version to 6.4.1 (#5152) 28 January 2022, 15:50:01 UTC
8ee13c7 changes 27 January 2022, 16:45:13 UTC
b65a932 Include display_class in set of UI-ignored keys 27 January 2022, 01:02:02 UTC
27aa7c0 Update myapp to Rails 7 27 January 2022, 01:01:26 UTC
01686c5 Tweak job logger to reduce overhead, 3-4% speedup 27 January 2022, 00:57:43 UTC
255b492 Standardize ruby binstubs 26 January 2022, 23:33:23 UTC
1efbadd Fix non-fatal error due to Kernel monkeypatch, fixes #5137 25 January 2022, 18:04:52 UTC
860c7b1 Load aliases for Psych 4 (included in Ruby 3.1) (#5141) 24 January 2022, 21:32:36 UTC
24fb5d3 Fix an error when job was enqueued without kwargs (#5138) (#5142) 24 January 2022, 21:31:30 UTC
c792342 Fix deprecated uses of `Redis#pipelined` and `Redis#multi` (#5139) Context: https://github.com/redis/redis-rb/pull/1059 The following is deprecated ```ruby redis.pipelined do redis.get(key) end ``` And should be rewritten as: ```ruby redis.pipelined do |pipeline| pipeline.get(key) end ``` Functionally it makes no difference. Co-authored-by: Jean Boussier <jean.boussier@gmail.com> 24 January 2022, 16:18:16 UTC
34d081f Fix the pool used by perform_bulk (#5129) * Fix the pool used by perform_bulk * Fix missing receiver * Fix missing kwargs 21 January 2022, 16:16:25 UTC
e7b67c6 fix build 21 January 2022, 00:54:38 UTC
7f6b2ef Bump minor as there are significant changes 20 January 2022, 18:47:00 UTC
7785ac1 Validate `days` parameter to avoid possible DoS in Web UI Thank you to Sergey Shpakov of http://tutum.space for reporting. 20 January 2022, 18:42:26 UTC
0a4de94 Add keyword arguments support in extensions (#5120) * Add keyword arguments support in extensions * Check that keywords arguments are passed * Test perform calls with keyword arguments * Fix kwargs forwarding on Ruby 2.6 18 January 2022, 15:55:31 UTC
b3c99ca Dashboard CSS tweaks for consistency/improvements (#5123) 18 January 2022, 01:16:10 UTC
8f7bc48 Dark Mode Improvements (#5122) * Dark Mode Improvements * Add Important Button Color * Update application-dark.css Further improvements 17 January 2022, 18:41:56 UTC
07acfad Bring back redis-namespace onto a gem release Was running master because Ruby 3.0 wasn't working in 1.8.0 10 January 2022, 22:51:30 UTC
d58a0a1 Update build for Ruby 3.1, fixes #5115 We need to remove Ruby 2.5 because the new net-smtp gem is required for the mail gem on Ruby 3.1 but it does not work on <=2.5. https://github.com/mikel/mail/pull/1439 Also remove an anon struct test which now breaks with safe YAML loading on 3.1. 10 January 2022, 17:15:23 UTC
63f6e68 standard formatting 06 January 2022, 05:01:32 UTC
96816c3 fix ruby 3.0 build 06 January 2022, 03:59:32 UTC
96ac8e7 bump 06 January 2022, 03:56:04 UTC
cea266a Better method naming, #5071 06 January 2022, 03:54:12 UTC
9818c34 Wording and formatting, no significant changes 06 January 2022, 03:43:53 UTC
4d00845 Fix YouTube capitalization (#5103) 23 December 2021, 14:38:35 UTC
f7e1fc8 Pause hard shutdown to give time for `ensure` cleanup, fixes #5095 If we raised Sidekiq::Shutdown in job threads, sleep for a while so they have time to run `ensure` blocks. Right now we immediately return from hard_shutdown and call `exit` which immediately raises SystemExit on every thread which can stop ensure blocks. 14 December 2021, 19:53:00 UTC
35eee4b change 11 December 2021, 18:13:15 UTC
c92a521 Merge new attributes if existing attributes, fixes #5090 09 December 2021, 21:14:59 UTC
615393d RDoc improvements 09 December 2021, 21:06:29 UTC
back to top