sidekiq 6.5.9 → 7.0.0.beta1

Sign up to get free protection for your applications and to get access to all the features.

Potentially problematic release.


This version of sidekiq might be problematic. Click here for more details.

Files changed (92) hide show
  1. checksums.yaml +4 -4
  2. data/Changes.md +5 -13
  3. data/README.md +13 -12
  4. data/bin/sidekiq +3 -8
  5. data/bin/sidekiqload +14 -23
  6. data/lib/sidekiq/api.rb +51 -127
  7. data/lib/sidekiq/capsule.rb +110 -0
  8. data/lib/sidekiq/cli.rb +44 -59
  9. data/lib/sidekiq/client.rb +30 -17
  10. data/lib/sidekiq/component.rb +1 -0
  11. data/lib/sidekiq/config.rb +270 -0
  12. data/lib/sidekiq/deploy.rb +62 -0
  13. data/lib/sidekiq/embedded.rb +61 -0
  14. data/lib/sidekiq/fetch.rb +10 -11
  15. data/lib/sidekiq/job.rb +375 -10
  16. data/lib/sidekiq/job_logger.rb +1 -1
  17. data/lib/sidekiq/job_retry.rb +8 -8
  18. data/lib/sidekiq/job_util.rb +4 -4
  19. data/lib/sidekiq/launcher.rb +36 -46
  20. data/lib/sidekiq/logger.rb +1 -26
  21. data/lib/sidekiq/manager.rb +9 -11
  22. data/lib/sidekiq/metrics/query.rb +3 -3
  23. data/lib/sidekiq/metrics/shared.rb +4 -3
  24. data/lib/sidekiq/metrics/tracking.rb +18 -18
  25. data/lib/sidekiq/middleware/chain.rb +7 -9
  26. data/lib/sidekiq/middleware/current_attributes.rb +3 -8
  27. data/lib/sidekiq/monitor.rb +1 -1
  28. data/lib/sidekiq/paginator.rb +1 -9
  29. data/lib/sidekiq/pool.rb +7 -0
  30. data/lib/sidekiq/processor.rb +17 -26
  31. data/lib/sidekiq/redis_client_adapter.rb +9 -45
  32. data/lib/sidekiq/redis_connection.rb +11 -111
  33. data/lib/sidekiq/scheduled.rb +19 -20
  34. data/lib/sidekiq/testing.rb +4 -32
  35. data/lib/sidekiq/transaction_aware_client.rb +4 -5
  36. data/lib/sidekiq/version.rb +1 -1
  37. data/lib/sidekiq/web/application.rb +1 -4
  38. data/lib/sidekiq/web/csrf_protection.rb +1 -1
  39. data/lib/sidekiq/web/helpers.rb +21 -22
  40. data/lib/sidekiq/web.rb +2 -17
  41. data/lib/sidekiq/worker_compatibility_alias.rb +13 -0
  42. data/lib/sidekiq.rb +52 -274
  43. data/sidekiq.gemspec +29 -5
  44. data/web/assets/javascripts/base-charts.js +106 -0
  45. data/web/assets/javascripts/dashboard-charts.js +166 -0
  46. data/web/assets/javascripts/dashboard.js +3 -223
  47. data/web/assets/javascripts/metrics.js +90 -116
  48. data/web/assets/stylesheets/application-rtl.css +2 -91
  49. data/web/assets/stylesheets/application.css +21 -296
  50. data/web/locales/ar.yml +70 -70
  51. data/web/locales/cs.yml +62 -62
  52. data/web/locales/da.yml +52 -52
  53. data/web/locales/de.yml +65 -65
  54. data/web/locales/el.yml +2 -7
  55. data/web/locales/en.yml +76 -70
  56. data/web/locales/es.yml +68 -68
  57. data/web/locales/fa.yml +65 -65
  58. data/web/locales/fr.yml +67 -67
  59. data/web/locales/he.yml +65 -64
  60. data/web/locales/hi.yml +59 -59
  61. data/web/locales/it.yml +53 -53
  62. data/web/locales/ja.yml +64 -68
  63. data/web/locales/ko.yml +52 -52
  64. data/web/locales/lt.yml +66 -66
  65. data/web/locales/nb.yml +61 -61
  66. data/web/locales/nl.yml +52 -52
  67. data/web/locales/pl.yml +45 -45
  68. data/web/locales/pt-br.yml +59 -69
  69. data/web/locales/pt.yml +51 -51
  70. data/web/locales/ru.yml +67 -66
  71. data/web/locales/sv.yml +53 -53
  72. data/web/locales/ta.yml +60 -60
  73. data/web/locales/uk.yml +62 -61
  74. data/web/locales/ur.yml +64 -64
  75. data/web/locales/vi.yml +67 -67
  76. data/web/locales/zh-cn.yml +1 -0
  77. data/web/locales/zh-tw.yml +10 -1
  78. data/web/views/_footer.erb +5 -2
  79. data/web/views/busy.erb +1 -6
  80. data/web/views/dashboard.erb +36 -5
  81. data/web/views/metrics.erb +30 -19
  82. data/web/views/metrics_for_job.erb +16 -34
  83. metadata +60 -37
  84. data/lib/sidekiq/delay.rb +0 -43
  85. data/lib/sidekiq/extensions/action_mailer.rb +0 -48
  86. data/lib/sidekiq/extensions/active_record.rb +0 -43
  87. data/lib/sidekiq/extensions/class_methods.rb +0 -43
  88. data/lib/sidekiq/extensions/generic_proxy.rb +0 -33
  89. data/lib/sidekiq/metrics/deploy.rb +0 -47
  90. data/lib/sidekiq/worker.rb +0 -370
  91. data/web/assets/javascripts/graph.js +0 -16
  92. /data/{LICENSE → LICENSE.txt} +0 -0
data/web/locales/vi.yml CHANGED
@@ -1,83 +1,83 @@
1
1
  # elements like %{queue} are variables and should not be translated
2
- vi: # <---- change this to your locale code
3
- Dashboard: Bảng điều khiển
4
- Status: Trạng thái
5
- Time: Thời gian
6
- Namespace: Không gian tên
7
- Realtime: Thời gian thực
8
- History: Lịch sử
2
+ vi:
3
+ Actions: Những hành động
4
+ AddToQueue: Thêm vào hàng đợi
5
+ AreYouSure: Bạn chắc chứ?
6
+ AreYouSureDeleteJob: Bạn chắc là muốn xóa tác vụ này?
7
+ AreYouSureDeleteQueue: Bạn chắc là muốn xóa %{queue} này?
8
+ Arguments: Tham số
9
+ BackToApp: Trở về ứng dụng
9
10
  Busy: Bận rộn
10
- Processed: Đã xử lí
11
- Failed: Đã thất bại
12
- Scheduled: Đã lên lịch
13
- Retries: Số lần thử
14
- Enqueued: Đã xếp hàng đợi
15
- Worker: Máy xử lí
16
- LivePoll: Thăm dò trực tiếp
17
- StopPolling: Ngừng thăm dò
18
- Queue: Hàng đợi
19
11
  Class: Lớp
20
- Job: Tác vụ
21
- Arguments: Tham số
22
- Extras: Thêm
23
- Started: Đã bắt đầu
24
- ShowAll: Hiện tất cả
12
+ Connections: Các kết nối
13
+ CreatedAt: Được tạo vào lúc
25
14
  CurrentMessagesInQueue: Số lượng công việc trong <span class='title'>%{queue}</span>
15
+ Dashboard: Bảng điều khiển
16
+ Dead: Chết
17
+ DeadJobs: Những tác vụ đã chết
26
18
  Delete: Xóa
27
- AddToQueue: Thêm vào hàng đợi
28
- AreYouSureDeleteJob: Bạn có chắc là muốn xóa tác vụ này?
29
- AreYouSureDeleteQueue: Bạn có chắc là muốn xóa %{queue} này?
30
- Queues: Các hàng đợi
31
- Size: Kích thước
32
- Actions: Những hành động
33
- NextRetry: Lần thử lại tiếp theo
34
- RetryCount: Số lần thử lại
35
- RetryNow: Thử lại ngay bây giờ
36
- Kill: Giết
37
- LastRetry: Lần thử cuối
38
- OriginallyFailed: Đã thất bại từ đầu
39
- AreYouSure: Bạn chắc chứ?
40
19
  DeleteAll: Xóa hết
41
- RetryAll: Thử lại tất cả
42
- KillAll: Giết hết
43
- NoRetriesFound: Không có lần thử nào được tìm thấy
20
+ Enqueued: Đã xếp hàng đợi
44
21
  Error: Lỗi
22
+ ErrorBacktrace: Dấu vết của lỗi
45
23
  ErrorClass: Lớp lỗi
46
24
  ErrorMessage: Tin nhắn lỗi
47
- ErrorBacktrace: Dấu vết của lỗi
25
+ Extras: Thêm
26
+ Failed: Đã thất bại
27
+ Failures: Các thất bại
48
28
  GoBack: ← Trở lại
49
- NoScheduledFound: Không có tác vụ đã lên lịch nào được tìm thấy
50
- When: Khi nào
51
- ScheduledJobs: Những Tác Vụ Được Hẹn
52
- idle: Đang chờ
53
- active: Đang hoạt động
54
- Version: Phiên bản
55
- Connections: Các kết nối
29
+ History: Lịch sử
30
+ Job: Tác vụ
31
+ Jobs: Các tác vụ
32
+ Kill: Giết
33
+ KillAll: Giết hết
34
+ LastRetry: Lần thử cuối
35
+ Latency: Độ trễ
36
+ LivePoll: Thăm dò trực tiếp
56
37
  MemoryUsage: Lượng bộ nhớ sử dụng
57
- PeakMemoryUsage: Lượng bộ nhớ sử dụng đỉnh điểm
58
- Uptime: Thời gian hệ thống đã online (days)
59
- OneWeek: 1 tuần
60
- OneMonth: 1 tháng
61
- ThreeMonths: 3 tháng
62
- SixMonths: 6 tháng
63
- Failures: Các thất bại
64
- DeadJobs: Những tác vụ đã chết
38
+ Namespace: Không gian tên
39
+ NextRetry: Lần thử lại tiếp theo
65
40
  NoDeadJobsFound: Không có tác vụ đã chết nào được tìm thấy
66
- Dead: Chết
67
- Processes: Tiến trình xử
68
- Thread: Luồng xử
69
- Threads: Những luồng xử lí
70
- Jobs: Các tác vụ
41
+ NoRetriesFound: Không có lần thử nào được tìm thấy
42
+ NoScheduledFound: Không tác vụ đã lên lịch nào được tìm thấy
43
+ NotYetEnqueued: Chưa được bỏ vào hàng đợi
44
+ OneMonth: 1 tháng
45
+ OneWeek: 1 tuần
46
+ OriginallyFailed: Đã thất bại từ đầu
47
+ Pause: Tạm dừng
71
48
  Paused: Đã tạm dừng
72
- Stop: Dừng Lại
49
+ PeakMemoryUsage: Lượng bộ nhớ sử dụng đỉnh điểm
50
+ Plugins: Hệ thống đính kèm
51
+ PollingInterval: Khoảng thời gian giữa các lần thăm dò
52
+ Processed: Đã xử lí
53
+ Processes: Tiến trình xử lí
54
+ Queue: Hàng đợi
55
+ Queues: Các hàng đợi
73
56
  Quiet: Im lặng
74
- StopAll: Dừng lại tất cả
75
57
  QuietAll: Làm cho tất cả im lặng
76
- PollingInterval: Khoảng thời gian giữa các lần thăm dò
77
- Plugins: Hệ thống đính kèm
78
- NotYetEnqueued: Chưa được bỏ vào hàng đợi
79
- CreatedAt: Được tạo vào lúc
80
- BackToApp: Trở về ứng dụng
81
- Latency: Độ trễ
82
- Pause: Tạm dừng
58
+ Realtime: Thời gian thực
59
+ Retries: Số lần thử
60
+ RetryAll: Thử lại tất cả
61
+ RetryCount: Số lần thử lại
62
+ RetryNow: Thử lại ngay bây giờ
63
+ Scheduled: Đã lên lịch
64
+ ScheduledJobs: Những Tác Vụ Được Hẹn
65
+ ShowAll: Hiện tất cả
66
+ SixMonths: 6 tháng
67
+ Size: Kích thước
68
+ Started: Đã bắt đầu
69
+ Status: Trạng thái
70
+ Stop: Dừng Lại
71
+ StopAll: Dừng lại tất cả
72
+ StopPolling: Ngừng thăm dò
73
+ Thread: Luồng xử lí
74
+ Threads: Những luồng xử lí
75
+ ThreeMonths: 3 tháng
76
+ Time: Thời gian
83
77
  Unpause: Hủy tạm dừng
78
+ Uptime: Thời gian hệ thống đã online (days)
79
+ Version: Phiên bản
80
+ When: Khi nào
81
+ Worker: Máy xử lí
82
+ active: Đang hoạt động
83
+ idle: Đang chờ
@@ -43,6 +43,7 @@ zh-cn: # <---- change this to your locale code
43
43
  KillAll: 全部终止
44
44
  NoRetriesFound: 沒有发现可重试
45
45
  Error: 错误
46
+ ErrorBacktrace: 错误的回调追踪
46
47
  ErrorClass: 错误类别
47
48
  ErrorMessage: 错误消息
48
49
  ErrorBacktrace: 错误细节
@@ -43,6 +43,7 @@ zh-tw: # <---- change this to your locale code
43
43
  KillAll: 全部取消
44
44
  NoRetriesFound: 找無可重試的工作
45
45
  Error: 錯誤
46
+ ErrorBacktrace: 錯誤的回調追踨
46
47
  ErrorClass: 錯誤類別
47
48
  ErrorMessage: 錯誤訊息
48
49
  ErrorBacktrace: 詳細錯誤訊息
@@ -62,7 +63,15 @@ zh-tw: # <---- change this to your locale code
62
63
  ThreeMonths: 三個月
63
64
  SixMonths: 六個月
64
65
  Failures: 失敗
65
- DeadJobs: 停滯工作
66
+ GoBack: ← 返回
67
+ History: 歷史資料
68
+ Job: 工作
69
+ Jobs: 工作
70
+ LastRetry: 最後一次重試
71
+ LivePoll: 即時輪詢
72
+ MemoryUsage: 記憶體使用量
73
+ Namespace: 命名空間
74
+ NextRetry: 下次重試
66
75
  NoDeadJobsFound: 沒有發現任何停滯的工作
67
76
  Dead: 停滯
68
77
  Process: 程序
@@ -6,13 +6,16 @@
6
6
  <p class="navbar-text product-version"><%= product_version %></p>
7
7
  </li>
8
8
  <li>
9
- <p class="navbar-text redis-url" title="<%= redis_connection_and_namespace %>"><%= redis_connection_and_namespace %></p>
9
+ <p class="navbar-text redis-url" title="<%= redis_url %>"><%= redis_url %></p>
10
10
  </li>
11
11
  <li>
12
12
  <p id="serverUtcTime" class="navbar-text server-utc-time"><%= server_utc_time %></p>
13
13
  </li>
14
14
  <li>
15
- <p class="navbar-text"><a style="color: gray;" href="https://github.com/mperham/sidekiq/wiki">docs</a></p>
15
+ <p class="navbar-text"><a rel=help href="https://github.com/mperham/sidekiq/wiki">docs</a></p>
16
+ </li>
17
+ <li>
18
+ <p class="navbar-text"><a rel=external href="https://github.com/mperham/sidekiq/tree/main/web/locales"><%= locale %></a></p>
16
19
  </li>
17
20
  </ul>
18
21
  </div>
data/web/views/busy.erb CHANGED
@@ -96,11 +96,6 @@
96
96
  <div class="col-sm-7">
97
97
  <h3><%= t('Jobs') %></h3>
98
98
  </div>
99
- <% if @workset.size > 0 && @total_size > @count %>
100
- <div class="col-sm-4">
101
- <%= erb :_paging, locals: { url: "#{root_path}busy" } %>
102
- </div>
103
- <% end %>
104
99
  </div>
105
100
 
106
101
  <div class="table_container">
@@ -114,7 +109,7 @@
114
109
  <th><%= t('Arguments') %></th>
115
110
  <th><%= t('Started') %></th>
116
111
  </thead>
117
- <% @workset.each do |process, thread, msg| %>
112
+ <% workset.each do |process, thread, msg| %>
118
113
  <% job = Sidekiq::JobRecord.new(msg['payload']) %>
119
114
  <tr>
120
115
  <td><%= process %></td>
@@ -1,4 +1,7 @@
1
- <script type="text/javascript" src="<%= root_path %>javascripts/graph.js"></script>
1
+ <script type="text/javascript" src="<%= root_path %>javascripts/chart.min.js"></script>
2
+ <script type="text/javascript" src="<%= root_path %>javascripts/chartjs-plugin-annotation.min.js"></script>
3
+ <script type="text/javascript" src="<%= root_path %>javascripts/base-charts.js"></script>
4
+ <script type="text/javascript" src="<%= root_path %>javascripts/dashboard-charts.js"></script>
2
5
  <script type="text/javascript" src="<%= root_path %>javascripts/dashboard.js"></script>
3
6
  <div class= "dashboard clearfix">
4
7
  <h3 >
@@ -17,8 +20,26 @@
17
20
  </div>
18
21
 
19
22
  <div class="row chart">
20
- <div id="realtime" data-processed-label="<%= t('Processed') %>" data-failed-label="<%= t('Failed') %>"></div>
21
- <div id="realtime-legend"></div>
23
+ <canvas id="realtime-chart"></canvas>
24
+ <script>
25
+ window.realtimeChart = new RealtimeChart(
26
+ document.getElementById("realtime-chart"),
27
+ <%= Sidekiq.dump_json({
28
+ processedLabel: t('Processed'),
29
+ failedLabel: t('Failed'),
30
+ labels: Array.new(50, ""),
31
+ processed: Array.new(50),
32
+ failed: Array.new(50),
33
+ updateUrl: "#{root_path}stats",
34
+ }) %>
35
+ )
36
+ </script>
37
+
38
+ <!-- start with a space in the legend so the height doesn't change when we add content dynamically -->
39
+ <div id="realtime-legend">&nbsp;</div>
40
+ <script>
41
+ realtimeChart.registerLegend(document.getElementById("realtime-legend"))
42
+ </script>
22
43
  </div>
23
44
 
24
45
  <div class="row header">
@@ -34,8 +55,18 @@
34
55
  <a href="<%= root_path %>?days=180" class="history-graph <%= "active" if params[:days] == "180" %>"><%= t('SixMonths') %></a>
35
56
  </div>
36
57
 
37
- <div id="history" data-processed-label="<%= t('Processed') %>" data-failed-label="<%= t('Failed') %>" data-processed="<%= h Sidekiq.dump_json(@processed_history) %>" data-failed="<%= h Sidekiq.dump_json(@failed_history) %>" data-update-url="<%= root_path %>stats"></div>
38
- <div id="history-legend"></div>
58
+ <canvas id="history-chart"></canvas>
59
+ <script>
60
+ window.historyChart = new DashboardChart(
61
+ document.getElementById("history-chart"),
62
+ <%= Sidekiq.dump_json({
63
+ processedLabel: t('Processed'),
64
+ failedLabel: t('Failed'),
65
+ processed: @processed_history.to_a.reverse,
66
+ failed: @failed_history.to_a.reverse,
67
+ }) %>
68
+ )
69
+ </script>
39
70
  </div>
40
71
 
41
72
  <br/>
@@ -1,8 +1,15 @@
1
1
  <script type="text/javascript" src="<%= root_path %>javascripts/chart.min.js"></script>
2
2
  <script type="text/javascript" src="<%= root_path %>javascripts/chartjs-plugin-annotation.min.js"></script>
3
+ <script type="text/javascript" src="<%= root_path %>javascripts/base-charts.js"></script>
3
4
  <script type="text/javascript" src="<%= root_path %>javascripts/metrics.js"></script>
4
5
 
5
- <h2>Total execution time</h2>
6
+ <div class="header-container">
7
+ <h1><%= t('Metrics') %></h1>
8
+
9
+ <div>
10
+ <a target="blank" href="https://github.com/mperham/sidekiq/wiki/Metrics"><span class="info-circle" title="Click to learn more about metrics">?</span></a>
11
+ </div>
12
+ </div>
6
13
 
7
14
  <%
8
15
  table_limit = 20
@@ -11,30 +18,33 @@
11
18
  visible_kls = job_results.first(chart_limit).map(&:first)
12
19
  %>
13
20
 
14
- <canvas id="job-metrics-overview-chart"></canvas>
15
-
16
- <script>
17
- window.jobMetricsChart = new JobMetricsOverviewChart(
18
- "job-metrics-overview-chart",
19
- <%= Sidekiq.dump_json({
20
- series: job_results.map { |(kls, jr)| [kls, jr.dig("series", "s")] }.to_h,
21
- marks: @query_result.marks.map { |m| [m.bucket, m.label] },
22
- visible: visible_kls,
23
- labels: @query_result.buckets,
24
- }) %>
25
- )
26
- </script>
21
+ <% if job_results.any? %>
22
+ <canvas id="job-metrics-overview-chart"></canvas>
27
23
 
28
- <h2>Most Time-Consuming Jobs</h2>
24
+ <script>
25
+ window.jobMetricsChart = new JobMetricsOverviewChart(
26
+ document.getElementById("job-metrics-overview-chart"),
27
+ <%= Sidekiq.dump_json({
28
+ series: job_results.map { |(kls, jr)| [kls, jr.dig("series", "s")] }.to_h,
29
+ marks: @query_result.marks.map { |m| [m.bucket, m.label] },
30
+ labels: @query_result.buckets,
31
+ visibleKls: visible_kls,
32
+ yLabel: t('TotalExecutionTime'),
33
+ units: t('Seconds').downcase,
34
+ markLabel: t('Deploy'),
35
+ }) %>
36
+ )
37
+ </script>
38
+ <% end %>
29
39
 
30
40
  <div class="table_container">
31
41
  <table class="table table-bordered table-striped table-hover">
32
42
  <tbody>
33
43
  <tr>
34
44
  <th><%= t('Name') %></th>
35
- <th><%= t('Processed') %></th>
36
- <th><%= t('Failed') %></th>
37
- <th><%= t('ExecutionTime') %></th>
45
+ <th><%= t('Success') %></th>
46
+ <th><%= t('Failure') %></th>
47
+ <th><%= t('TotalExecutionTime') %></th>
38
48
  <th><%= t('AvgExecutionTime') %></th>
39
49
  </tr>
40
50
  <% if job_results.any? %>
@@ -48,12 +58,13 @@
48
58
  id="<%= id %>"
49
59
  class="metrics-swatch"
50
60
  value="<%= kls %>"
61
+ <%= visible_kls.include?(kls) ? 'checked' : '' %>
51
62
  />
52
63
  <code><a href="<%= root_path %>metrics/<%= kls %>"><%= kls %></a></code>
53
64
  </div>
54
65
  <script>jobMetricsChart.registerSwatch("<%= id %>")</script>
55
66
  </td>
56
- <td><%= jr.dig("totals", "p") %></td>
67
+ <td><%= jr.dig("totals", "p") - jr.dig("totals", "f") %></td>
57
68
  <td><%= jr.dig("totals", "f") %></td>
58
69
  <td><%= jr.dig("totals", "s").round(2) %> seconds</td>
59
70
  <td><%= jr.total_avg("s").round(2) %> seconds</td>
@@ -1,5 +1,6 @@
1
1
  <script type="text/javascript" src="<%= root_path %>javascripts/chart.min.js"></script>
2
2
  <script type="text/javascript" src="<%= root_path %>javascripts/chartjs-plugin-annotation.min.js"></script>
3
+ <script type="text/javascript" src="<%= root_path %>javascripts/base-charts.js"></script>
3
4
  <script type="text/javascript" src="<%= root_path %>javascripts/metrics.js"></script>
4
5
 
5
6
  <%
@@ -13,69 +14,50 @@
13
14
  %>
14
15
 
15
16
  <% if job_result.totals["s"] > 0 %>
16
- <div class="header-with-subheader">
17
+ <div class="header-container">
17
18
  <h1>
18
- <a href="<%= root_path %>/metrics"><%= t(:metrics).to_s.titleize %></a> /
19
+ <a href="<%= root_path %>metrics"><%= t(:metrics).to_s.titleize %></a> /
19
20
  <%= h @name %>
20
21
  </h1>
21
- <h2>Histogram summary</h2>
22
+
23
+ <div>
24
+ <a target="blank" href="https://github.com/mperham/sidekiq/wiki/Metrics"><span class="info-circle" title="Click to learn more about metrics">?</span></a>
25
+ </div>
22
26
  </div>
23
27
 
24
28
  <canvas id="hist-totals-chart"></canvas>
25
29
 
26
30
  <script>
27
31
  window.histTotalsChart = new HistTotalsChart(
28
- "hist-totals-chart",
32
+ document.getElementById("hist-totals-chart"),
29
33
  <%= Sidekiq.dump_json({
30
34
  series: hist_totals,
31
35
  labels: bucket_labels,
36
+ xLabel: t('ExecutionTime'),
37
+ yLabel: t('Jobs'),
38
+ units: t('Jobs').downcase,
32
39
  }) %>
33
40
  )
34
41
  </script>
35
42
 
36
- <h2>Performance over time</h2>
37
-
38
43
  <canvas id="hist-bubble-chart"></canvas>
39
44
 
40
45
  <script>
41
46
  window.histBubbleChart = new HistBubbleChart(
42
- "hist-bubble-chart",
47
+ document.getElementById("hist-bubble-chart"),
43
48
  <%= Sidekiq.dump_json({
44
49
  hist: job_result.hist,
45
50
  marks: @query_result.marks.map { |m| [m.bucket, m.label] },
46
51
  labels: @query_result.buckets,
47
52
  histIntervals: bucket_intervals,
53
+ yLabel: t('ExecutionTime'),
54
+ markLabel: t('Deploy'),
55
+ yUnits: t('Seconds').downcase,
56
+ zUnits: t('Jobs').downcase,
48
57
  }) %>
49
58
  )
50
59
  </script>
51
60
 
52
- <div class="table_container">
53
- <table class="table table-bordered table-striped table-hover">
54
- <tbody>
55
- <tr>
56
- <th><%= t('Time') %></th>
57
- <th><%= t('Processed') %></th>
58
- <th><%= t('Failed') %></th>
59
- <th><%= t('ExecutionTime') %></th>
60
- <th><%= t('AvgExecutionTime') %></th>
61
- </tr>
62
- <% @query_result.buckets.reverse.each do |bucket| %>
63
- <tr>
64
- <td><%= bucket %></td>
65
- <td><%= job_result.series.dig("p", bucket) %></td>
66
- <td><%= job_result.series.dig("f", bucket) %></td>
67
- <% if (total_sec = job_result.series.dig("s", bucket)) > 0 %>
68
- <td><%= total_sec.round(2) %> seconds</td>
69
- <td><%= job_result.series_avg("s")[bucket].round(2) %> seconds</td>
70
- <% else %>
71
- <td>&mdash;</td>
72
- <td>&mdash;</td>
73
- <% end %>
74
- </tr>
75
- <% end %>
76
- </tbody>
77
- </table>
78
- </div>
79
61
  <p><small>Data from <%= @query_result.starts_at %> to <%= @query_result.ends_at %></small></p>
80
62
  <% else %>
81
63
  <h1>
metadata CHANGED
@@ -1,69 +1,71 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: sidekiq
3
3
  version: !ruby/object:Gem::Version
4
- version: 6.5.9
4
+ version: 7.0.0.beta1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Mike Perham
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2023-05-25 00:00:00.000000000 Z
11
+ date: 2022-09-26 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
- name: redis
14
+ name: redis-client
15
15
  requirement: !ruby/object:Gem::Requirement
16
16
  requirements:
17
- - - "<"
18
- - !ruby/object:Gem::Version
19
- version: '5'
20
17
  - - ">="
21
18
  - !ruby/object:Gem::Version
22
- version: 4.5.0
19
+ version: 0.9.0
23
20
  type: :runtime
24
21
  prerelease: false
25
22
  version_requirements: !ruby/object:Gem::Requirement
26
23
  requirements:
27
- - - "<"
28
- - !ruby/object:Gem::Version
29
- version: '5'
30
24
  - - ">="
31
25
  - !ruby/object:Gem::Version
32
- version: 4.5.0
26
+ version: 0.9.0
33
27
  - !ruby/object:Gem::Dependency
34
28
  name: connection_pool
35
29
  requirement: !ruby/object:Gem::Requirement
36
30
  requirements:
37
- - - "<"
38
- - !ruby/object:Gem::Version
39
- version: '3'
40
31
  - - ">="
41
32
  - !ruby/object:Gem::Version
42
- version: 2.2.5
33
+ version: 2.3.0
43
34
  type: :runtime
44
35
  prerelease: false
45
36
  version_requirements: !ruby/object:Gem::Requirement
46
37
  requirements:
47
- - - "<"
48
- - !ruby/object:Gem::Version
49
- version: '3'
50
38
  - - ">="
51
39
  - !ruby/object:Gem::Version
52
- version: 2.2.5
40
+ version: 2.3.0
53
41
  - !ruby/object:Gem::Dependency
54
42
  name: rack
55
43
  requirement: !ruby/object:Gem::Requirement
56
44
  requirements:
57
- - - "~>"
45
+ - - ">="
46
+ - !ruby/object:Gem::Version
47
+ version: 2.2.4
48
+ type: :runtime
49
+ prerelease: false
50
+ version_requirements: !ruby/object:Gem::Requirement
51
+ requirements:
52
+ - - ">="
53
+ - !ruby/object:Gem::Version
54
+ version: 2.2.4
55
+ - !ruby/object:Gem::Dependency
56
+ name: concurrent-ruby
57
+ requirement: !ruby/object:Gem::Requirement
58
+ requirements:
59
+ - - "<"
58
60
  - !ruby/object:Gem::Version
59
- version: '2.0'
61
+ version: '2'
60
62
  type: :runtime
61
63
  prerelease: false
62
64
  version_requirements: !ruby/object:Gem::Requirement
63
65
  requirements:
64
- - - "~>"
66
+ - - "<"
65
67
  - !ruby/object:Gem::Version
66
- version: '2.0'
68
+ version: '2'
67
69
  description: Simple, efficient background processing for Ruby.
68
70
  email:
69
71
  - mperham@gmail.com
@@ -74,7 +76,7 @@ extensions: []
74
76
  extra_rdoc_files: []
75
77
  files:
76
78
  - Changes.md
77
- - LICENSE
79
+ - LICENSE.txt
78
80
  - README.md
79
81
  - bin/sidekiq
80
82
  - bin/sidekiqload
@@ -85,14 +87,13 @@ files:
85
87
  - lib/generators/sidekiq/templates/job_test.rb.erb
86
88
  - lib/sidekiq.rb
87
89
  - lib/sidekiq/api.rb
90
+ - lib/sidekiq/capsule.rb
88
91
  - lib/sidekiq/cli.rb
89
92
  - lib/sidekiq/client.rb
90
93
  - lib/sidekiq/component.rb
91
- - lib/sidekiq/delay.rb
92
- - lib/sidekiq/extensions/action_mailer.rb
93
- - lib/sidekiq/extensions/active_record.rb
94
- - lib/sidekiq/extensions/class_methods.rb
95
- - lib/sidekiq/extensions/generic_proxy.rb
94
+ - lib/sidekiq/config.rb
95
+ - lib/sidekiq/deploy.rb
96
+ - lib/sidekiq/embedded.rb
96
97
  - lib/sidekiq/fetch.rb
97
98
  - lib/sidekiq/job.rb
98
99
  - lib/sidekiq/job_logger.rb
@@ -101,7 +102,6 @@ files:
101
102
  - lib/sidekiq/launcher.rb
102
103
  - lib/sidekiq/logger.rb
103
104
  - lib/sidekiq/manager.rb
104
- - lib/sidekiq/metrics/deploy.rb
105
105
  - lib/sidekiq/metrics/query.rb
106
106
  - lib/sidekiq/metrics/shared.rb
107
107
  - lib/sidekiq/metrics/tracking.rb
@@ -111,6 +111,7 @@ files:
111
111
  - lib/sidekiq/middleware/modules.rb
112
112
  - lib/sidekiq/monitor.rb
113
113
  - lib/sidekiq/paginator.rb
114
+ - lib/sidekiq/pool.rb
114
115
  - lib/sidekiq/processor.rb
115
116
  - lib/sidekiq/rails.rb
116
117
  - lib/sidekiq/redis_client_adapter.rb
@@ -129,17 +130,18 @@ files:
129
130
  - lib/sidekiq/web/csrf_protection.rb
130
131
  - lib/sidekiq/web/helpers.rb
131
132
  - lib/sidekiq/web/router.rb
132
- - lib/sidekiq/worker.rb
133
+ - lib/sidekiq/worker_compatibility_alias.rb
133
134
  - sidekiq.gemspec
134
135
  - web/assets/images/apple-touch-icon.png
135
136
  - web/assets/images/favicon.ico
136
137
  - web/assets/images/logo.png
137
138
  - web/assets/images/status.png
138
139
  - web/assets/javascripts/application.js
140
+ - web/assets/javascripts/base-charts.js
139
141
  - web/assets/javascripts/chart.min.js
140
142
  - web/assets/javascripts/chartjs-plugin-annotation.min.js
143
+ - web/assets/javascripts/dashboard-charts.js
141
144
  - web/assets/javascripts/dashboard.js
142
- - web/assets/javascripts/graph.js
143
145
  - web/assets/javascripts/metrics.js
144
146
  - web/assets/stylesheets/application-dark.css
145
147
  - web/assets/stylesheets/application-rtl.css
@@ -203,7 +205,28 @@ metadata:
203
205
  documentation_uri: https://github.com/mperham/sidekiq/wiki
204
206
  changelog_uri: https://github.com/mperham/sidekiq/blob/main/Changes.md
205
207
  source_code_uri: https://github.com/mperham/sidekiq
206
- post_install_message:
208
+ post_install_message: |2
209
+
210
+ ####################################################
211
+
212
+
213
+ █████████ █████ ██████████ ██████████ █████ ████ █████ ██████ ██████████ █████
214
+ ███░░░░░███░░███ ░░███░░░░███ ░░███░░░░░█░░███ ███░ ░░███ ███░░░░███ ░███░░░░███ ███░░░███
215
+ ░███ ░░░ ░███ ░███ ░░███ ░███ █ ░ ░███ ███ ░███ ███ ░░███ ░░░ ███ ███ ░░███
216
+ ░░█████████ ░███ ░███ ░███ ░██████ ░███████ ░███ ░███ ░███ ███ ░███ ░███
217
+ ░░░░░░░░███ ░███ ░███ ░███ ░███░░█ ░███░░███ ░███ ░███ ██░███ ███ ░███ ░███
218
+ ███ ░███ ░███ ░███ ███ ░███ ░ █ ░███ ░░███ ░███ ░░███ ░░████ ███ ░░███ ███
219
+ ░░█████████ █████ ██████████ ██████████ █████ ░░████ █████ ░░░██████░██ ███ ██ ░░░█████░
220
+ ░░░░░░░░░ ░░░░░ ░░░░░░░░░░ ░░░░░░░░░░ ░░░░░ ░░░░ ░░░░░ ░░░░░░ ░░ ░░░ ░░ ░░░░░░
221
+
222
+
223
+ WARNING: This is a beta release, expect breakage!
224
+
225
+ 1. Use `gem 'sidekiq', '<7'` in your Gemfile if you don't want to be a beta tester.
226
+ 2. Read the release notes at https://github.com/mperham/sidekiq/blob/7-0/docs/7.0-Upgrade.md
227
+ 3. Search for open/closed issues at https://github.com/mperham/sidekiq/issues/
228
+
229
+ ####################################################
207
230
  rdoc_options: []
208
231
  require_paths:
209
232
  - lib
@@ -211,14 +234,14 @@ required_ruby_version: !ruby/object:Gem::Requirement
211
234
  requirements:
212
235
  - - ">="
213
236
  - !ruby/object:Gem::Version
214
- version: 2.5.0
237
+ version: 2.7.0
215
238
  required_rubygems_version: !ruby/object:Gem::Requirement
216
239
  requirements:
217
- - - ">="
240
+ - - ">"
218
241
  - !ruby/object:Gem::Version
219
- version: '0'
242
+ version: 1.3.1
220
243
  requirements: []
221
- rubygems_version: 3.4.7
244
+ rubygems_version: 3.2.32
222
245
  signing_key:
223
246
  specification_version: 4
224
247
  summary: Simple, efficient background processing for Ruby