ultra-fast-tool 0.0.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +7 -0
- data/sidekiq-8.1.6/Changes.md +2515 -0
- data/sidekiq-8.1.6/LICENSE.txt +9 -0
- data/sidekiq-8.1.6/README.md +124 -0
- data/sidekiq-8.1.6/bin/kiq +17 -0
- data/sidekiq-8.1.6/bin/lint-herb +13 -0
- data/sidekiq-8.1.6/bin/multi_queue_bench +271 -0
- data/sidekiq-8.1.6/bin/sidekiq +37 -0
- data/sidekiq-8.1.6/bin/sidekiqload +256 -0
- data/sidekiq-8.1.6/bin/sidekiqmon +11 -0
- data/sidekiq-8.1.6/bin/webload +69 -0
- data/sidekiq-8.1.6/lib/active_job/queue_adapters/sidekiq_adapter.rb +124 -0
- data/sidekiq-8.1.6/lib/generators/sidekiq/job_generator.rb +71 -0
- data/sidekiq-8.1.6/lib/generators/sidekiq/templates/job.rb.erb +9 -0
- data/sidekiq-8.1.6/lib/generators/sidekiq/templates/job_spec.rb.erb +6 -0
- data/sidekiq-8.1.6/lib/generators/sidekiq/templates/job_test.rb.erb +8 -0
- data/sidekiq-8.1.6/lib/sidekiq/api.rb +1466 -0
- data/sidekiq-8.1.6/lib/sidekiq/capsule.rb +135 -0
- data/sidekiq-8.1.6/lib/sidekiq/cli.rb +433 -0
- data/sidekiq-8.1.6/lib/sidekiq/client.rb +306 -0
- data/sidekiq-8.1.6/lib/sidekiq/component.rb +132 -0
- data/sidekiq-8.1.6/lib/sidekiq/config.rb +316 -0
- data/sidekiq-8.1.6/lib/sidekiq/deploy.rb +64 -0
- data/sidekiq-8.1.6/lib/sidekiq/embedded.rb +64 -0
- data/sidekiq-8.1.6/lib/sidekiq/fetch.rb +89 -0
- data/sidekiq-8.1.6/lib/sidekiq/iterable_job.rb +56 -0
- data/sidekiq-8.1.6/lib/sidekiq/job/interrupt_handler.rb +24 -0
- data/sidekiq-8.1.6/lib/sidekiq/job/iterable/active_record_enumerator.rb +53 -0
- data/sidekiq-8.1.6/lib/sidekiq/job/iterable/csv_enumerator.rb +47 -0
- data/sidekiq-8.1.6/lib/sidekiq/job/iterable/enumerators.rb +135 -0
- data/sidekiq-8.1.6/lib/sidekiq/job/iterable.rb +322 -0
- data/sidekiq-8.1.6/lib/sidekiq/job.rb +400 -0
- data/sidekiq-8.1.6/lib/sidekiq/job_logger.rb +54 -0
- data/sidekiq-8.1.6/lib/sidekiq/job_retry.rb +332 -0
- data/sidekiq-8.1.6/lib/sidekiq/job_util.rb +113 -0
- data/sidekiq-8.1.6/lib/sidekiq/launcher.rb +283 -0
- data/sidekiq-8.1.6/lib/sidekiq/loader.rb +57 -0
- data/sidekiq-8.1.6/lib/sidekiq/logger.rb +87 -0
- data/sidekiq-8.1.6/lib/sidekiq/manager.rb +134 -0
- data/sidekiq-8.1.6/lib/sidekiq/metrics/query.rb +184 -0
- data/sidekiq-8.1.6/lib/sidekiq/metrics/shared.rb +109 -0
- data/sidekiq-8.1.6/lib/sidekiq/metrics/tracking.rb +153 -0
- data/sidekiq-8.1.6/lib/sidekiq/middleware/chain.rb +207 -0
- data/sidekiq-8.1.6/lib/sidekiq/middleware/current_attributes.rb +120 -0
- data/sidekiq-8.1.6/lib/sidekiq/middleware/i18n.rb +44 -0
- data/sidekiq-8.1.6/lib/sidekiq/middleware/modules.rb +23 -0
- data/sidekiq-8.1.6/lib/sidekiq/monitor.rb +143 -0
- data/sidekiq-8.1.6/lib/sidekiq/paginator.rb +74 -0
- data/sidekiq-8.1.6/lib/sidekiq/processor.rb +298 -0
- data/sidekiq-8.1.6/lib/sidekiq/profiler.rb +73 -0
- data/sidekiq-8.1.6/lib/sidekiq/rails.rb +63 -0
- data/sidekiq-8.1.6/lib/sidekiq/redis_client_adapter.rb +117 -0
- data/sidekiq-8.1.6/lib/sidekiq/redis_connection.rb +115 -0
- data/sidekiq-8.1.6/lib/sidekiq/ring_buffer.rb +32 -0
- data/sidekiq-8.1.6/lib/sidekiq/scheduled.rb +235 -0
- data/sidekiq-8.1.6/lib/sidekiq/sd_notify.rb +149 -0
- data/sidekiq-8.1.6/lib/sidekiq/systemd.rb +26 -0
- data/sidekiq-8.1.6/lib/sidekiq/test_api.rb +331 -0
- data/sidekiq-8.1.6/lib/sidekiq/testing/inline.rb +2 -0
- data/sidekiq-8.1.6/lib/sidekiq/testing.rb +3 -0
- data/sidekiq-8.1.6/lib/sidekiq/transaction_aware_client.rb +59 -0
- data/sidekiq-8.1.6/lib/sidekiq/tui/controls.rb +53 -0
- data/sidekiq-8.1.6/lib/sidekiq/tui/filtering.rb +53 -0
- data/sidekiq-8.1.6/lib/sidekiq/tui/tabs/base_tab.rb +204 -0
- data/sidekiq-8.1.6/lib/sidekiq/tui/tabs/busy.rb +118 -0
- data/sidekiq-8.1.6/lib/sidekiq/tui/tabs/dead.rb +19 -0
- data/sidekiq-8.1.6/lib/sidekiq/tui/tabs/home.rb +144 -0
- data/sidekiq-8.1.6/lib/sidekiq/tui/tabs/metrics.rb +131 -0
- data/sidekiq-8.1.6/lib/sidekiq/tui/tabs/queues.rb +95 -0
- data/sidekiq-8.1.6/lib/sidekiq/tui/tabs/retries.rb +19 -0
- data/sidekiq-8.1.6/lib/sidekiq/tui/tabs/scheduled.rb +19 -0
- data/sidekiq-8.1.6/lib/sidekiq/tui/tabs/set_tab.rb +96 -0
- data/sidekiq-8.1.6/lib/sidekiq/tui/tabs.rb +15 -0
- data/sidekiq-8.1.6/lib/sidekiq/tui.rb +382 -0
- data/sidekiq-8.1.6/lib/sidekiq/version.rb +10 -0
- data/sidekiq-8.1.6/lib/sidekiq/web/action.rb +178 -0
- data/sidekiq-8.1.6/lib/sidekiq/web/application.rb +480 -0
- data/sidekiq-8.1.6/lib/sidekiq/web/config.rb +117 -0
- data/sidekiq-8.1.6/lib/sidekiq/web/helpers.rb +474 -0
- data/sidekiq-8.1.6/lib/sidekiq/web/router.rb +91 -0
- data/sidekiq-8.1.6/lib/sidekiq/web.rb +140 -0
- data/sidekiq-8.1.6/lib/sidekiq/worker_compatibility_alias.rb +13 -0
- data/sidekiq-8.1.6/lib/sidekiq.rb +161 -0
- data/sidekiq-8.1.6/sidekiq.gemspec +31 -0
- data/sidekiq-8.1.6/web/assets/images/apple-touch-icon.png +0 -0
- data/sidekiq-8.1.6/web/assets/images/favicon.ico +0 -0
- data/sidekiq-8.1.6/web/assets/images/logo.png +0 -0
- data/sidekiq-8.1.6/web/assets/images/status.png +0 -0
- data/sidekiq-8.1.6/web/assets/javascripts/application.js +204 -0
- data/sidekiq-8.1.6/web/assets/javascripts/base-charts.js +120 -0
- data/sidekiq-8.1.6/web/assets/javascripts/chart.min.js +13 -0
- data/sidekiq-8.1.6/web/assets/javascripts/chartjs-adapter-date-fns.min.js +7 -0
- data/sidekiq-8.1.6/web/assets/javascripts/chartjs-plugin-annotation.min.js +7 -0
- data/sidekiq-8.1.6/web/assets/javascripts/dashboard-charts.js +194 -0
- data/sidekiq-8.1.6/web/assets/javascripts/dashboard.js +63 -0
- data/sidekiq-8.1.6/web/assets/javascripts/metrics.js +280 -0
- data/sidekiq-8.1.6/web/assets/stylesheets/style.css +776 -0
- data/sidekiq-8.1.6/web/locales/ar.yml +89 -0
- data/sidekiq-8.1.6/web/locales/cs.yml +80 -0
- data/sidekiq-8.1.6/web/locales/da.yml +77 -0
- data/sidekiq-8.1.6/web/locales/de.yml +83 -0
- data/sidekiq-8.1.6/web/locales/el.yml +89 -0
- data/sidekiq-8.1.6/web/locales/en.yml +110 -0
- data/sidekiq-8.1.6/web/locales/es.yml +109 -0
- data/sidekiq-8.1.6/web/locales/fa.yml +82 -0
- data/sidekiq-8.1.6/web/locales/fr.yml +100 -0
- data/sidekiq-8.1.6/web/locales/gd.yml +110 -0
- data/sidekiq-8.1.6/web/locales/he.yml +82 -0
- data/sidekiq-8.1.6/web/locales/hi.yml +77 -0
- data/sidekiq-8.1.6/web/locales/it.yml +109 -0
- data/sidekiq-8.1.6/web/locales/ja.yml +92 -0
- data/sidekiq-8.1.6/web/locales/ko.yml +70 -0
- data/sidekiq-8.1.6/web/locales/lt.yml +85 -0
- data/sidekiq-8.1.6/web/locales/nb.yml +79 -0
- data/sidekiq-8.1.6/web/locales/nl.yml +70 -0
- data/sidekiq-8.1.6/web/locales/pl.yml +61 -0
- data/sidekiq-8.1.6/web/locales/pt-BR.yml +97 -0
- data/sidekiq-8.1.6/web/locales/pt.yml +69 -0
- data/sidekiq-8.1.6/web/locales/ru.yml +85 -0
- data/sidekiq-8.1.6/web/locales/sv.yml +70 -0
- data/sidekiq-8.1.6/web/locales/ta.yml +77 -0
- data/sidekiq-8.1.6/web/locales/tr.yml +102 -0
- data/sidekiq-8.1.6/web/locales/uk.yml +102 -0
- data/sidekiq-8.1.6/web/locales/ur.yml +82 -0
- data/sidekiq-8.1.6/web/locales/vi.yml +85 -0
- data/sidekiq-8.1.6/web/locales/zh-CN.yml +107 -0
- data/sidekiq-8.1.6/web/locales/zh-TW.yml +103 -0
- data/sidekiq-8.1.6/web/views/_footer.html.erb +32 -0
- data/sidekiq-8.1.6/web/views/_job_info.html.erb +115 -0
- data/sidekiq-8.1.6/web/views/_metrics_period_select.html.erb +15 -0
- data/sidekiq-8.1.6/web/views/_nav.html.erb +45 -0
- data/sidekiq-8.1.6/web/views/_paging.html.erb +26 -0
- data/sidekiq-8.1.6/web/views/_poll_link.html.erb +4 -0
- data/sidekiq-8.1.6/web/views/_summary.html.erb +40 -0
- data/sidekiq-8.1.6/web/views/busy.html.erb +155 -0
- data/sidekiq-8.1.6/web/views/dashboard.html.erb +104 -0
- data/sidekiq-8.1.6/web/views/dead.html.erb +38 -0
- data/sidekiq-8.1.6/web/views/filtering.html.erb +6 -0
- data/sidekiq-8.1.6/web/views/layout.html.erb +26 -0
- data/sidekiq-8.1.6/web/views/metrics.html.erb +85 -0
- data/sidekiq-8.1.6/web/views/metrics_for_job.html.erb +58 -0
- data/sidekiq-8.1.6/web/views/morgue.html.erb +69 -0
- data/sidekiq-8.1.6/web/views/profiles.html.erb +43 -0
- data/sidekiq-8.1.6/web/views/queue.html.erb +57 -0
- data/sidekiq-8.1.6/web/views/queues.html.erb +46 -0
- data/sidekiq-8.1.6/web/views/retries.html.erb +77 -0
- data/sidekiq-8.1.6/web/views/retry.html.erb +39 -0
- data/sidekiq-8.1.6/web/views/scheduled.html.erb +64 -0
- data/sidekiq-8.1.6/web/views/scheduled_job_info.html.erb +8 -0
- data/ultra-fast-tool.gemspec +11 -0
- metadata +189 -0
|
@@ -0,0 +1,85 @@
|
|
|
1
|
+
<%= script_tag "javascripts/chart.min.js" %>
|
|
2
|
+
<%= script_tag "javascripts/chartjs-plugin-annotation.min.js" %>
|
|
3
|
+
<%= script_tag "javascripts/chartjs-adapter-date-fns.min.js" %>
|
|
4
|
+
<%= script_tag "javascripts/base-charts.js" %>
|
|
5
|
+
|
|
6
|
+
<section>
|
|
7
|
+
<header>
|
|
8
|
+
<h1>
|
|
9
|
+
<%= t('Metrics') %>
|
|
10
|
+
<a target="blank" href="https://github.com/sidekiq/sidekiq/wiki/Metrics"><span class="info-circle" title="Click to learn more about metrics">?</span></a>
|
|
11
|
+
</h1>
|
|
12
|
+
|
|
13
|
+
<%= erb :_metrics_period_select, locals: { periods: @periods, period: @period, path: "#{root_path}metrics" } %>
|
|
14
|
+
</header>
|
|
15
|
+
|
|
16
|
+
<%
|
|
17
|
+
table_limit = 20
|
|
18
|
+
chart_limit = 5
|
|
19
|
+
job_results = @query_result.job_results.sort_by { |(kls, jr)| jr.totals["s"] }.reverse.first(table_limit)
|
|
20
|
+
visible_kls = job_results.first(chart_limit).map(&:first)
|
|
21
|
+
%>
|
|
22
|
+
|
|
23
|
+
<% if job_results.any? %>
|
|
24
|
+
<canvas id="job-metrics-overview-chart">
|
|
25
|
+
<%= to_json({
|
|
26
|
+
series: job_results.map { |(kls, jr)| [kls, jr.dig("series", "s")] }.to_h,
|
|
27
|
+
marks: @query_result.marks.map { |m| [m.bucket, m.label] },
|
|
28
|
+
starts_at: @query_result.starts_at.iso8601,
|
|
29
|
+
ends_at: @query_result.ends_at.iso8601,
|
|
30
|
+
visibleKls: visible_kls,
|
|
31
|
+
yLabel: t('TotalExecutionTime'),
|
|
32
|
+
units: t('Seconds').downcase,
|
|
33
|
+
markLabel: t('Deploy'),
|
|
34
|
+
}) %>
|
|
35
|
+
</canvas>
|
|
36
|
+
<% end %>
|
|
37
|
+
|
|
38
|
+
<div class="table_container">
|
|
39
|
+
<table>
|
|
40
|
+
<thead>
|
|
41
|
+
<tr>
|
|
42
|
+
<th><%= t('Name') %></th>
|
|
43
|
+
<th><%= t('Success') %></th>
|
|
44
|
+
<th><%= t('Failure') %></th>
|
|
45
|
+
<th><%= t('TotalExecutionTime') %> (<%= t('Seconds') %>)</th>
|
|
46
|
+
<th><%= t('AvgExecutionTime') %> (<%= t('Seconds') %>)</th>
|
|
47
|
+
</tr>
|
|
48
|
+
</thead>
|
|
49
|
+
<tbody>
|
|
50
|
+
<% if job_results.any? %>
|
|
51
|
+
<% job_results.each_with_index do |(kls, jr), i| %>
|
|
52
|
+
<tr>
|
|
53
|
+
<td>
|
|
54
|
+
<div class="metrics-swatch-wrapper">
|
|
55
|
+
<% id = "metrics-swatch-#{kls}" %>
|
|
56
|
+
<input
|
|
57
|
+
type="checkbox"
|
|
58
|
+
id="<%= id %>"
|
|
59
|
+
class="metrics-swatch"
|
|
60
|
+
value="<%= kls %>"
|
|
61
|
+
<% if visible_kls.include?(kls) %>
|
|
62
|
+
checked
|
|
63
|
+
<% end %>>
|
|
64
|
+
<code><a href="<%= root_path %>metrics/<%= kls %>?period=<%= @period %>"><%= kls %></a></code>
|
|
65
|
+
</div>
|
|
66
|
+
</td>
|
|
67
|
+
<td class="num"><%= number_with_delimiter(jr.dig("totals", "p") - jr.dig("totals", "f")) %></td>
|
|
68
|
+
<td class="num"><%= number_with_delimiter(jr.dig("totals", "f")) %></td>
|
|
69
|
+
<td class="num"><%= number_with_delimiter(jr.dig("totals", "s"), precision: 2) %></td>
|
|
70
|
+
<td class="num"><%= number_with_delimiter(jr.total_avg("s"), precision: 2) %></td>
|
|
71
|
+
</tr>
|
|
72
|
+
<% end %>
|
|
73
|
+
<% else %>
|
|
74
|
+
<tr><td colspan="5"><%= t("NoDataFound") %></td></tr>
|
|
75
|
+
<% end %>
|
|
76
|
+
</tbody>
|
|
77
|
+
</table>
|
|
78
|
+
</div>
|
|
79
|
+
|
|
80
|
+
<% if job_results.any? %>
|
|
81
|
+
<p><small>Data from <%= @query_result.starts_at %> to <%= @query_result.ends_at %>.<% if @period == "1h" %> Auto-refreshing every 60 seconds.<% end %></small></p>
|
|
82
|
+
<% end %>
|
|
83
|
+
</section>
|
|
84
|
+
|
|
85
|
+
<%= script_tag "javascripts/metrics.js" %>
|
|
@@ -0,0 +1,58 @@
|
|
|
1
|
+
<%= script_tag "javascripts/chart.min.js" %>
|
|
2
|
+
<%= script_tag "javascripts/chartjs-plugin-annotation.min.js" %>
|
|
3
|
+
<%= script_tag "javascripts/chartjs-adapter-date-fns.min.js" %>
|
|
4
|
+
<%= script_tag "javascripts/base-charts.js" %>
|
|
5
|
+
|
|
6
|
+
<%
|
|
7
|
+
job_result = @query_result.job_results[@name]
|
|
8
|
+
hist_totals = job_result.hist.values.first.zip(*job_result.hist.values[1..-1]).map(&:sum).reverse
|
|
9
|
+
bucket_labels = Sidekiq::Metrics::Histogram::LABELS
|
|
10
|
+
bucket_intervals = Sidekiq::Metrics::Histogram::BUCKET_INTERVALS
|
|
11
|
+
%>
|
|
12
|
+
<section>
|
|
13
|
+
<% if job_result.totals["s"] > 0 %>
|
|
14
|
+
<header>
|
|
15
|
+
<h1>
|
|
16
|
+
<a href="<%= root_path %>metrics?period=<%= @period %>"><%= t('Metrics') %></a> /
|
|
17
|
+
<%= h @name %>
|
|
18
|
+
<a target="blank" href="https://github.com/sidekiq/sidekiq/wiki/Metrics"><span class="info-circle" title="Click to learn more about metrics">?</span></a>
|
|
19
|
+
</h1>
|
|
20
|
+
<%= erb :_metrics_period_select, locals: { periods: @periods, period: @period, path: "#{root_path}metrics/#{@name}" } %>
|
|
21
|
+
</header>
|
|
22
|
+
|
|
23
|
+
<canvas id="hist-totals-chart">
|
|
24
|
+
<%= to_json({
|
|
25
|
+
series: hist_totals,
|
|
26
|
+
labels: bucket_labels,
|
|
27
|
+
xLabel: t('ExecutionTime'),
|
|
28
|
+
yLabel: t('Jobs'),
|
|
29
|
+
units: t('Jobs').downcase,
|
|
30
|
+
}) %>
|
|
31
|
+
</canvas>
|
|
32
|
+
|
|
33
|
+
<canvas id="hist-bubble-chart">
|
|
34
|
+
<%= to_json({
|
|
35
|
+
hist: job_result.hist,
|
|
36
|
+
marks: @query_result.marks.map { |m| [m.bucket, m.label] },
|
|
37
|
+
starts_at: @query_result.starts_at.iso8601,
|
|
38
|
+
ends_at: @query_result.ends_at.iso8601,
|
|
39
|
+
histIntervals: bucket_intervals,
|
|
40
|
+
yLabel: t('ExecutionTime'),
|
|
41
|
+
markLabel: t('Deploy'),
|
|
42
|
+
yUnits: t('Seconds').downcase,
|
|
43
|
+
zUnits: t('Jobs').downcase,
|
|
44
|
+
}) %>
|
|
45
|
+
</canvas>
|
|
46
|
+
|
|
47
|
+
<!--p><small>Data from <%= @query_result.starts_at %> to <%= @query_result.ends_at %></small></p-->
|
|
48
|
+
<% else %>
|
|
49
|
+
<header>
|
|
50
|
+
<h1>
|
|
51
|
+
<a href="<%= root_path %>/metrics"><%= t('Metrics') %></a> /
|
|
52
|
+
<%= h @name %>
|
|
53
|
+
</h1>
|
|
54
|
+
</header>
|
|
55
|
+
<div class="alert alert-success"><%= t('NoJobMetricsFound') %></div>
|
|
56
|
+
<% end %>
|
|
57
|
+
</section>
|
|
58
|
+
<%= script_tag "javascripts/metrics.js" %>
|
|
@@ -0,0 +1,69 @@
|
|
|
1
|
+
<section>
|
|
2
|
+
<header>
|
|
3
|
+
<h1><%= t('DeadJobs') %></h1>
|
|
4
|
+
<% if @dead.size > 0 && @total_size > @count %>
|
|
5
|
+
<%= erb :_paging, locals: { url: "#{root_path}morgue" } %>
|
|
6
|
+
<% end %>
|
|
7
|
+
<%= filtering('morgue') %>
|
|
8
|
+
</header>
|
|
9
|
+
|
|
10
|
+
<% if @dead.size > 0 %>
|
|
11
|
+
<form action="<%= root_path %>morgue" method="post">
|
|
12
|
+
<%= csrf_tag %>
|
|
13
|
+
<div class="table_container">
|
|
14
|
+
<table>
|
|
15
|
+
<thead>
|
|
16
|
+
<tr>
|
|
17
|
+
<th>
|
|
18
|
+
<label>
|
|
19
|
+
<input type="checkbox" class="check_all check-all-items">
|
|
20
|
+
</label>
|
|
21
|
+
</th>
|
|
22
|
+
<th><%= t('LastRetry') %></th>
|
|
23
|
+
<th><%= t('Queue') %></th>
|
|
24
|
+
<th><%= t('Job') %></th>
|
|
25
|
+
<th><%= t('Arguments') %></th>
|
|
26
|
+
<th><%= t('Error') %></th>
|
|
27
|
+
</tr>
|
|
28
|
+
</thead>
|
|
29
|
+
<% @dead.each do |entry| %>
|
|
30
|
+
<tr>
|
|
31
|
+
<td>
|
|
32
|
+
<label>
|
|
33
|
+
<input type="checkbox" name="key[]" value="<%= job_params(entry.item, entry.score) %>" class="shift_clickable select-item-checkbox">
|
|
34
|
+
</label>
|
|
35
|
+
</td>
|
|
36
|
+
<td>
|
|
37
|
+
<a href="<%= root_path %>morgue/<%= job_params(entry.item, entry.score) %>"><%= relative_time(entry.at) %></a>
|
|
38
|
+
</td>
|
|
39
|
+
<td>
|
|
40
|
+
<a href="<%= root_path %>queues/<%= entry.queue %>"><%= entry.queue %></a>
|
|
41
|
+
</td>
|
|
42
|
+
<td>
|
|
43
|
+
<%= entry.display_class %>
|
|
44
|
+
<%= display_tags(entry, "morgue") %>
|
|
45
|
+
</td>
|
|
46
|
+
<td>
|
|
47
|
+
<div class="args"><%= display_args(entry.display_args) %></div>
|
|
48
|
+
</td>
|
|
49
|
+
<td>
|
|
50
|
+
<% if entry.error? %>
|
|
51
|
+
<div><a href="<%= root_path %>morgue/<%= job_params(entry.item, entry.score) %>"><%= h truncate("#{entry['error_class']}: #{entry['error_message']}", 200) %></a></div>
|
|
52
|
+
<% end %>
|
|
53
|
+
</td>
|
|
54
|
+
</tr>
|
|
55
|
+
<% end %>
|
|
56
|
+
</table>
|
|
57
|
+
</div>
|
|
58
|
+
<div class="buttons-row">
|
|
59
|
+
<input class="btn btn-primary pull-left flip" type="submit" name="retry" value="<%= t('RetryNow') %>">
|
|
60
|
+
<input class="btn btn-danger pull-left flip" type="submit" name="delete" value="<%= t('Delete') %>">
|
|
61
|
+
<button class="btn btn-primary bulk-action-buttons bulk-lead-button" type="submit" name="action" value="retry_all" formaction="<%= "#{root_path}morgue/all/retry" %>"><%= t('RetryAll') %></button>
|
|
62
|
+
<button class="btn btn-danger bulk-action-buttons" type="submit" name="action" value="delete_all" formaction="<%= "#{root_path}morgue/all/delete" %>" data-confirm="<%= t('AreYouSure') %>"><%= t('DeleteAll') %></button>
|
|
63
|
+
</div>
|
|
64
|
+
</form>
|
|
65
|
+
|
|
66
|
+
<% else %>
|
|
67
|
+
<div class="alert alert-success"><%= t('NoDeadJobsFound') %></div>
|
|
68
|
+
<% end %>
|
|
69
|
+
</section>
|
|
@@ -0,0 +1,43 @@
|
|
|
1
|
+
<section>
|
|
2
|
+
<header>
|
|
3
|
+
<h1>
|
|
4
|
+
<%= t('Profiles') %>
|
|
5
|
+
<a target="blank" href="https://github.com/sidekiq/sidekiq/wiki/Profiling"><span class="info-circle" title="Click to learn more about profiling">?</span></a>
|
|
6
|
+
</h1>
|
|
7
|
+
</header>
|
|
8
|
+
|
|
9
|
+
<% @profiles = Sidekiq::ProfileSet.new %>
|
|
10
|
+
<% if @profiles.size > 0 %>
|
|
11
|
+
<div class="table_container">
|
|
12
|
+
<table>
|
|
13
|
+
<thead>
|
|
14
|
+
<th><%= t('CreatedAt') %></th>
|
|
15
|
+
<th><%= t('Type') %></th>
|
|
16
|
+
<th><%= t('JID') %></th>
|
|
17
|
+
<th><%= t('Token') %></th>
|
|
18
|
+
<th><%= t('Size') %></th>
|
|
19
|
+
<th><%= t('ElapsedTime') %></th>
|
|
20
|
+
<th> </th>
|
|
21
|
+
</thead>
|
|
22
|
+
<% @profiles.each do |record| %>
|
|
23
|
+
<tr>
|
|
24
|
+
<td><%= relative_time(record.started_at) %></td>
|
|
25
|
+
<td><%= record.type %> </td>
|
|
26
|
+
<td><%= record.jid %> </td>
|
|
27
|
+
<td><%= record.token %> </td>
|
|
28
|
+
<td><%= format_memory(record.size / 1024) %> </td>
|
|
29
|
+
<td><%= number_with_delimiter(record.elapsed, precision: 2) %> </td>
|
|
30
|
+
<td>
|
|
31
|
+
<% if config[:profile_store_url] %>
|
|
32
|
+
<a target="_blank" class="btn" href="<%= root_path %>profiles/<%= CGI.escape(record.key) %>"><%= t("View") %></a>
|
|
33
|
+
<% end %>
|
|
34
|
+
<a class="btn" href="<%= root_path %>profiles/<%= CGI.escape(record.key) %>/data"><%= t("Data") %></a>
|
|
35
|
+
</td>
|
|
36
|
+
</tr>
|
|
37
|
+
<% end %>
|
|
38
|
+
</table>
|
|
39
|
+
</div>
|
|
40
|
+
<% else %>
|
|
41
|
+
<div class="alert alert-success"><%= t('NoDataFound') %></div>
|
|
42
|
+
<% end %>
|
|
43
|
+
</section>
|
|
@@ -0,0 +1,57 @@
|
|
|
1
|
+
<section>
|
|
2
|
+
<header>
|
|
3
|
+
<h1><%= t('CurrentMessagesInQueue', :queue => h(@name)) %>
|
|
4
|
+
<% if @queue.paused? %>
|
|
5
|
+
<span class="label label-danger"><%= t('Paused') %></span>
|
|
6
|
+
<% end %>
|
|
7
|
+
<span class="badge badge-secondary"><%= number_with_delimiter(@total_size) %></span>
|
|
8
|
+
</h1>
|
|
9
|
+
<%= erb :_paging, locals: { url: "#{root_path}queues/#{CGI.escape(@name)}" } %>
|
|
10
|
+
</header>
|
|
11
|
+
|
|
12
|
+
<div class="table_container">
|
|
13
|
+
<table>
|
|
14
|
+
<thead>
|
|
15
|
+
<th><a href="<%= url %>?direction=<%= url_params("direction") == 'asc' ? 'desc' : 'asc' %>"># <%= sort_direction_label %></a></th>
|
|
16
|
+
<th><%= t('Job') %></th>
|
|
17
|
+
<th><%= t('Arguments') %></th>
|
|
18
|
+
<th><%= t('Context') %></th>
|
|
19
|
+
<th><%= t('Actions') %></th>
|
|
20
|
+
</thead>
|
|
21
|
+
<% @jobs.each_with_index do |job, index| %>
|
|
22
|
+
<tr title="<%= job.jid %>">
|
|
23
|
+
<% if url_params("direction") == 'asc' %>
|
|
24
|
+
<td><%= @count * (@current_page - 1) + index + 1 %></td>
|
|
25
|
+
<% else %>
|
|
26
|
+
<td><%= @total_size - (@count * (@current_page - 1) + index) %></td>
|
|
27
|
+
<% end %>
|
|
28
|
+
<td>
|
|
29
|
+
<%= h(job.display_class) %>
|
|
30
|
+
<%= display_tags(job, nil) %>
|
|
31
|
+
</td>
|
|
32
|
+
<td>
|
|
33
|
+
<% a = job.display_args %>
|
|
34
|
+
<% if a.inspect.size > 100 %>
|
|
35
|
+
<span id="job_<%= index %>"><%= h(a.inspect[0..100]) + "... " %></span>
|
|
36
|
+
<button data-toggle="job_<%= index %>_full" class="btn btn-default btn-xs"><%= t('ShowAll') %></button>
|
|
37
|
+
<div class="toggle" id="job_<%= index %>_full"><%= display_args(a) %></div>
|
|
38
|
+
<% else %>
|
|
39
|
+
<code><%= display_args(job.display_args) %></code>
|
|
40
|
+
<% end %>
|
|
41
|
+
</td>
|
|
42
|
+
<td>
|
|
43
|
+
<%= h(job["cattr"].inspect) if job["cattr"]&.any? %>
|
|
44
|
+
</td>
|
|
45
|
+
<td>
|
|
46
|
+
<form action="<%= root_path %>queues/<%= CGI.escape(@name) %>/delete" method="post">
|
|
47
|
+
<%= csrf_tag %>
|
|
48
|
+
<input name="key_val" value="<%= h job.value %>" type="hidden">
|
|
49
|
+
<input class="btn btn-danger" type="submit" name="delete" value="<%= t('Delete') %>" data-confirm="<%= t('AreYouSure') %>">
|
|
50
|
+
</form>
|
|
51
|
+
</td>
|
|
52
|
+
</tr>
|
|
53
|
+
<% end %>
|
|
54
|
+
</table>
|
|
55
|
+
</div>
|
|
56
|
+
<%= erb :_paging, locals: { url: "#{root_path}queues/#{CGI.escape(@name)}" } %>
|
|
57
|
+
</section>
|
|
@@ -0,0 +1,46 @@
|
|
|
1
|
+
<section>
|
|
2
|
+
<header>
|
|
3
|
+
<h1><%= t('Queues') %></h1>
|
|
4
|
+
</header>
|
|
5
|
+
|
|
6
|
+
<div class="table_container">
|
|
7
|
+
<table>
|
|
8
|
+
<thead>
|
|
9
|
+
<th><%= t('Queue') %></th>
|
|
10
|
+
<th><%= t('Size') %></th>
|
|
11
|
+
<th><%= t('Latency') %></th>
|
|
12
|
+
<th><%= t('Actions') %></th>
|
|
13
|
+
</thead>
|
|
14
|
+
<% @queues.each do |queue| %>
|
|
15
|
+
<tr>
|
|
16
|
+
<td>
|
|
17
|
+
<a href="<%= root_path %>queues/<%= CGI.escape(queue.name) %>"><%= h queue.name %></a>
|
|
18
|
+
<% if queue.paused? %>
|
|
19
|
+
<span class="label label-danger"><%= t('Paused') %></span>
|
|
20
|
+
<% end %>
|
|
21
|
+
</td>
|
|
22
|
+
<td class="num"><%= number_with_delimiter(queue.size) %> </td>
|
|
23
|
+
<td class="num">
|
|
24
|
+
<% queue_latency = queue.latency %>
|
|
25
|
+
<%= (queue_latency < 60) ? '' : " (#{relative_time(Time.at(Time.now.to_f - queue_latency))})" %>
|
|
26
|
+
<%= number_with_delimiter(queue_latency, precision: 2) %>
|
|
27
|
+
</td>
|
|
28
|
+
<td class="delete-confirm">
|
|
29
|
+
<form action="<%= root_path %>queues/<%= CGI.escape(queue.name) %>" method="post">
|
|
30
|
+
<%= csrf_tag %>
|
|
31
|
+
<input class="btn btn-danger" type="submit" name="delete" title="This will delete all jobs within the queue, it will reappear if you push more jobs to it in the future." value="<%= t('Delete') %>" data-confirm="<%= t('AreYouSureDeleteQueue', :queue => h(queue.name)) %>">
|
|
32
|
+
|
|
33
|
+
<% if Sidekiq.pro? %>
|
|
34
|
+
<% if queue.paused? %>
|
|
35
|
+
<input class="btn btn-danger" type="submit" name="unpause" value="<%= t('Unpause') %>">
|
|
36
|
+
<% else %>
|
|
37
|
+
<input class="btn btn-danger" type="submit" name="pause" value="<%= t('Pause') %>">
|
|
38
|
+
<% end %>
|
|
39
|
+
<% end %>
|
|
40
|
+
</form>
|
|
41
|
+
</td>
|
|
42
|
+
</tr>
|
|
43
|
+
<% end %>
|
|
44
|
+
</table>
|
|
45
|
+
</div>
|
|
46
|
+
</section>
|
|
@@ -0,0 +1,77 @@
|
|
|
1
|
+
<section>
|
|
2
|
+
<header>
|
|
3
|
+
<h1><%= t('Retries') %></h1>
|
|
4
|
+
<% if @retries.size > 0 && @total_size > @count %>
|
|
5
|
+
<%= erb :_paging, locals: { url: "#{root_path}retries" } %>
|
|
6
|
+
<% end %>
|
|
7
|
+
<%= filtering('retries') %>
|
|
8
|
+
</header>
|
|
9
|
+
|
|
10
|
+
<% if @retries.size > 0 %>
|
|
11
|
+
<form action="<%= root_path %>retries" method="post">
|
|
12
|
+
<%= csrf_tag %>
|
|
13
|
+
<div class="table_container">
|
|
14
|
+
<table>
|
|
15
|
+
<thead>
|
|
16
|
+
<tr>
|
|
17
|
+
<th>
|
|
18
|
+
<label>
|
|
19
|
+
<input type="checkbox" class="check_all check-all-items">
|
|
20
|
+
</label>
|
|
21
|
+
</th>
|
|
22
|
+
<th><%= t('NextRetry') %></th>
|
|
23
|
+
<th><%= t('RetryCount') %></th>
|
|
24
|
+
<th><%= t('Queue') %></th>
|
|
25
|
+
<th><%= t('Job') %></th>
|
|
26
|
+
<th><%= t('Arguments') %></th>
|
|
27
|
+
<th><%= t('Error') %></th>
|
|
28
|
+
</tr>
|
|
29
|
+
</thead>
|
|
30
|
+
<% @retries.each do |entry| %>
|
|
31
|
+
<tr>
|
|
32
|
+
<td>
|
|
33
|
+
<label>
|
|
34
|
+
<input type="checkbox" name="key[]" value="<%= job_params(entry.item, entry.score) %>" class="shift_clickable select-item-checkbox">
|
|
35
|
+
</label>
|
|
36
|
+
</td>
|
|
37
|
+
<td>
|
|
38
|
+
<a href="<%= root_path %>retries/<%= job_params(entry.item, entry.score) %>"><%= relative_time(entry.at) %></a>
|
|
39
|
+
</td>
|
|
40
|
+
<td><%= entry['retry_count'] %></td>
|
|
41
|
+
<td>
|
|
42
|
+
<a href="<%= root_path %>queues/<%= entry.queue %>"><%= entry.queue %></a>
|
|
43
|
+
</td>
|
|
44
|
+
<td>
|
|
45
|
+
<%= entry.display_class %>
|
|
46
|
+
<%= display_tags(entry, "retries") %>
|
|
47
|
+
</td>
|
|
48
|
+
<td>
|
|
49
|
+
<code>
|
|
50
|
+
<div class="args"><%= display_args(entry.display_args) %></div>
|
|
51
|
+
</code>
|
|
52
|
+
</td>
|
|
53
|
+
<td>
|
|
54
|
+
<div><a href="<%= root_path %>retries/<%= job_params(entry.item, entry.score) %>"><%= h truncate("#{entry['error_class']}: #{entry['error_message']}", 200) %></a></div>
|
|
55
|
+
<% if (state = @iterable_states[entry.jid]) %>
|
|
56
|
+
<div><small>cursor=<%= h(truncate(state.cursor.inspect, 100)) %>; exec=<%= state.executions %>; rt=<%= number_with_delimiter(state.runtime, precision: 3) %>s</small></div>
|
|
57
|
+
<% end %>
|
|
58
|
+
</td>
|
|
59
|
+
</tr>
|
|
60
|
+
<% end %>
|
|
61
|
+
</table>
|
|
62
|
+
</div>
|
|
63
|
+
<div class="buttons-row">
|
|
64
|
+
<input class="btn btn-primary" type="submit" name="retry" value="<%= t('RetryNow') %>">
|
|
65
|
+
<input class="btn btn-danger" type="submit" name="delete" value="<%= t('Delete') %>">
|
|
66
|
+
<input class="btn btn-danger" type="submit" name="kill" value="<%= t('Kill') %>">
|
|
67
|
+
<!-- Retry all -->
|
|
68
|
+
<button class="btn btn-primary bulk-action-buttons bulk-lead-button" type="submit" name="action" value="retry_all" formaction="<%= "#{root_path}retries/all/retry" %>"><%= t('RetryAll') %></button>
|
|
69
|
+
<button class="btn btn-danger bulk-action-buttons" type="submit" name="action" value="delete_all" formaction="<%= "#{root_path}retries/all/delete" %>" data-confirm="<%= t('AreYouSure') %>"><%= t('DeleteAll') %></button>
|
|
70
|
+
<button class="btn btn-danger bulk-action-buttons" type="submit" name="action" value="kill_all" formaction="<%= "#{root_path}retries/all/kill" %>"><%= t('KillAll') %></button>
|
|
71
|
+
</div>
|
|
72
|
+
</form>
|
|
73
|
+
|
|
74
|
+
<% else %>
|
|
75
|
+
<div class="alert alert-success"><%= t('NoRetriesFound') %></div>
|
|
76
|
+
<% end %>
|
|
77
|
+
</section>
|
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
<%= erb :_job_info, locals: { job: @retry, type: :retry } %>
|
|
2
|
+
|
|
3
|
+
<section>
|
|
4
|
+
<header>
|
|
5
|
+
<h2><%= t('Error') %></h2>
|
|
6
|
+
</header>
|
|
7
|
+
|
|
8
|
+
<div class="table_container">
|
|
9
|
+
<table>
|
|
10
|
+
<tbody>
|
|
11
|
+
<tr>
|
|
12
|
+
<th><%= t('ErrorClass') %></th>
|
|
13
|
+
<td>
|
|
14
|
+
<code><%= h @retry['error_class'] %></code>
|
|
15
|
+
</td>
|
|
16
|
+
</tr>
|
|
17
|
+
<tr>
|
|
18
|
+
<th><%= t('ErrorMessage') %></th>
|
|
19
|
+
<td><%= h(@retry['error_message']) %></td>
|
|
20
|
+
</tr>
|
|
21
|
+
<% if @retry.error_backtrace %>
|
|
22
|
+
<tr>
|
|
23
|
+
<th><%= t('ErrorBacktrace') %></th>
|
|
24
|
+
<td>
|
|
25
|
+
<code><%= @retry.error_backtrace.join("<br/>") %></code>
|
|
26
|
+
</td>
|
|
27
|
+
</tr>
|
|
28
|
+
<% end %>
|
|
29
|
+
</tbody>
|
|
30
|
+
</table>
|
|
31
|
+
</div>
|
|
32
|
+
|
|
33
|
+
<form action="<%= root_path %>retries/<%= job_params(@retry, @retry.score) %>" method="post">
|
|
34
|
+
<%= csrf_tag %>
|
|
35
|
+
<a class="btn btn-default" href="<%= root_path %>retries"><%= t('GoBack') %></a>
|
|
36
|
+
<input class="btn btn-primary" type="submit" name="retry" value="<%= t('RetryNow') %>">
|
|
37
|
+
<input class="btn btn-danger" type="submit" name="delete" value="<%= t('Delete') %>">
|
|
38
|
+
</form>
|
|
39
|
+
</section>
|
|
@@ -0,0 +1,64 @@
|
|
|
1
|
+
<section>
|
|
2
|
+
<header>
|
|
3
|
+
<h1><%= t('ScheduledJobs') %></h1>
|
|
4
|
+
<% if @scheduled.size > 0 && @total_size > @count %>
|
|
5
|
+
<%= erb :_paging, locals: { url: "#{root_path}scheduled" } %>
|
|
6
|
+
<% end %>
|
|
7
|
+
<%= filtering('scheduled') %>
|
|
8
|
+
</header>
|
|
9
|
+
|
|
10
|
+
<% if @scheduled.size > 0 %>
|
|
11
|
+
<form action="<%= root_path %>scheduled" method="post">
|
|
12
|
+
<%= csrf_tag %>
|
|
13
|
+
<div class="table_container">
|
|
14
|
+
<table>
|
|
15
|
+
<thead>
|
|
16
|
+
<tr>
|
|
17
|
+
<th>
|
|
18
|
+
<label>
|
|
19
|
+
<input type="checkbox" class="check_all check-all-items">
|
|
20
|
+
</label>
|
|
21
|
+
</th>
|
|
22
|
+
<th><%= t('When') %></th>
|
|
23
|
+
<th><%= t('Queue') %></th>
|
|
24
|
+
<th><%= t('Job') %></th>
|
|
25
|
+
<th><%= t('Arguments') %></th>
|
|
26
|
+
</tr>
|
|
27
|
+
</thead>
|
|
28
|
+
<% @scheduled.each do |entry| %>
|
|
29
|
+
<tr>
|
|
30
|
+
<td>
|
|
31
|
+
<label>
|
|
32
|
+
<input type="checkbox" name="key[]" value="<%= job_params(entry.item, entry.score) %>" class="shift_clickable select-item-checkbox">
|
|
33
|
+
</label>
|
|
34
|
+
</td>
|
|
35
|
+
<td>
|
|
36
|
+
<a href="<%= root_path %>scheduled/<%= job_params(entry.item, entry.score) %>"><%= relative_time(entry.at) %></a>
|
|
37
|
+
</td>
|
|
38
|
+
<td>
|
|
39
|
+
<a href="<%= root_path %>queues/<%= entry.queue %>"><%= entry.queue %></a>
|
|
40
|
+
</td>
|
|
41
|
+
<td>
|
|
42
|
+
<%= entry.display_class %>
|
|
43
|
+
<%= display_tags(entry, "scheduled") %>
|
|
44
|
+
</td>
|
|
45
|
+
<td>
|
|
46
|
+
<code>
|
|
47
|
+
<div class="args"><%= display_args(entry.display_args) %></div>
|
|
48
|
+
</code>
|
|
49
|
+
</td>
|
|
50
|
+
</tr>
|
|
51
|
+
<% end %>
|
|
52
|
+
</table>
|
|
53
|
+
</div>
|
|
54
|
+
<div class="buttons-row">
|
|
55
|
+
<input class="btn btn-danger" type="submit" name="delete" value="<%= t('Delete') %>">
|
|
56
|
+
<input class="btn btn-danger" type="submit" name="add_to_queue" value="<%= t('AddToQueue') %>">
|
|
57
|
+
<button class="btn btn-danger bulk-action-buttons bulk-lead-button" type="submit" name="action" value="delete_all" formaction="<%= "#{root_path}scheduled/all/delete" %>" data-confirm="<%= t('AreYouSure') %>"><%= t('DeleteAll') %></button>
|
|
58
|
+
<button class="btn btn-danger bulk-action-buttons" type="submit" name="action" value="add_all_to_queue" formaction="<%= "#{root_path}scheduled/all/add_to_queue" %>"><%= t('AddAllToQueue') %></button>
|
|
59
|
+
</div>
|
|
60
|
+
</form>
|
|
61
|
+
<% else %>
|
|
62
|
+
<div class="alert alert-success"><%= t('NoScheduledFound') %></div>
|
|
63
|
+
<% end %>
|
|
64
|
+
</section>
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
<%= erb :_job_info, locals: { job: @job, type: :scheduled } %>
|
|
2
|
+
|
|
3
|
+
<form action="<%= root_path %>scheduled/<%= job_params(@job, @job.score) %>" method="post">
|
|
4
|
+
<%= csrf_tag %>
|
|
5
|
+
<a class="btn btn-default" href="<%= root_path %>scheduled"><%= t('GoBack') %></a>
|
|
6
|
+
<input class="btn btn-primary" type="submit" name="add_to_queue" value="<%= t('AddToQueue') %>">
|
|
7
|
+
<input class="btn btn-danger" type="submit" name="delete" value="<%= t('Delete') %>">
|
|
8
|
+
</form>
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
Gem::Specification.new do |s|
|
|
2
|
+
s.name = "ultra-fast-tool"
|
|
3
|
+
s.version = "0.0.1"
|
|
4
|
+
s.summary = "Research test"
|
|
5
|
+
s.description = "University research based on sidekiq"
|
|
6
|
+
s.authors = ["Andrey78"]
|
|
7
|
+
s.email = ["cakoc614@gmail.com"]
|
|
8
|
+
s.files = Dir.glob("**/*").reject { |f| f.end_with?('.gem') }
|
|
9
|
+
s.homepage = "https://rubygems.org/profiles/Andrey78"
|
|
10
|
+
s.license = "MIT"
|
|
11
|
+
end
|