sidekiq 7.0.8 → 7.1.4

Sign up to get free protection for your applications and to get access to all the features.
@@ -7,26 +7,32 @@ module Sidekiq
7
7
  # This can be useful for multi-tenancy, i18n locale, timezone, any implicit
8
8
  # per-request attribute. See +ActiveSupport::CurrentAttributes+.
9
9
  #
10
+ # For multiple current attributes, pass an array of current attributes.
11
+ #
10
12
  # @example
11
13
  #
12
14
  # # in your initializer
13
15
  # require "sidekiq/middleware/current_attributes"
14
16
  # Sidekiq::CurrentAttributes.persist("Myapp::Current")
17
+ # # or multiple current attributes
18
+ # Sidekiq::CurrentAttributes.persist(["Myapp::Current", "Myapp::OtherCurrent"])
15
19
  #
16
20
  module CurrentAttributes
17
21
  class Save
18
22
  include Sidekiq::ClientMiddleware
19
23
 
20
- def initialize(cattr)
21
- @strklass = cattr
24
+ def initialize(cattrs)
25
+ @cattrs = cattrs
22
26
  end
23
27
 
24
28
  def call(_, job, _, _)
25
- if !job.has_key?("cattr")
26
- attrs = @strklass.constantize.attributes
27
- # Retries can push the job N times, we don't
28
- # want retries to reset cattr. #5692, #5090
29
- job["cattr"] = attrs if attrs.any?
29
+ @cattrs.each do |(key, strklass)|
30
+ if !job.has_key?(key)
31
+ attrs = strklass.constantize.attributes
32
+ # Retries can push the job N times, we don't
33
+ # want retries to reset cattr. #5692, #5090
34
+ job[key] = attrs if attrs.any?
35
+ end
30
36
  end
31
37
  yield
32
38
  end
@@ -35,22 +41,55 @@ module Sidekiq
35
41
  class Load
36
42
  include Sidekiq::ServerMiddleware
37
43
 
38
- def initialize(cattr)
39
- @strklass = cattr
44
+ def initialize(cattrs)
45
+ @cattrs = cattrs
40
46
  end
41
47
 
42
48
  def call(_, job, _, &block)
43
- if job.has_key?("cattr")
44
- @strklass.constantize.set(job["cattr"], &block)
45
- else
46
- yield
49
+ cattrs_to_reset = []
50
+
51
+ @cattrs.each do |(key, strklass)|
52
+ if job.has_key?(key)
53
+ constklass = strklass.constantize
54
+ cattrs_to_reset << constklass
55
+
56
+ job[key].each do |(attribute, value)|
57
+ constklass.public_send("#{attribute}=", value)
58
+ end
59
+ end
47
60
  end
61
+
62
+ yield
63
+ ensure
64
+ cattrs_to_reset.each(&:reset)
48
65
  end
49
66
  end
50
67
 
51
- def self.persist(klass, config = Sidekiq.default_configuration)
52
- config.client_middleware.add Save, klass.to_s
53
- config.server_middleware.add Load, klass.to_s
68
+ class << self
69
+ def persist(klass_or_array, config = Sidekiq.default_configuration)
70
+ cattrs = build_cattrs_hash(klass_or_array)
71
+
72
+ config.client_middleware.add Save, cattrs
73
+ config.server_middleware.add Load, cattrs
74
+ end
75
+
76
+ private
77
+
78
+ def build_cattrs_hash(klass_or_array)
79
+ if klass_or_array.is_a?(Array)
80
+ {}.tap do |hash|
81
+ klass_or_array.each_with_index do |klass, index|
82
+ hash[key_at(index)] = klass.to_s
83
+ end
84
+ end
85
+ else
86
+ {key_at(0) => klass_or_array.to_s}
87
+ end
88
+ end
89
+
90
+ def key_at(index)
91
+ (index == 0) ? "cattr" : "cattr_#{index}"
92
+ end
54
93
  end
55
94
  end
56
95
  end
@@ -19,7 +19,7 @@ module Sidekiq
19
19
  total_size, items = conn.multi { |transaction|
20
20
  transaction.zcard(key)
21
21
  if rev
22
- transaction.zrevrange(key, starting, ending, withscores: true)
22
+ transaction.zrange(key, starting, ending, "REV", withscores: true)
23
23
  else
24
24
  transaction.zrange(key, starting, ending, withscores: true)
25
25
  end
@@ -148,6 +148,8 @@ module Sidekiq
148
148
 
149
149
  IGNORE_SHUTDOWN_INTERRUPTS = {Sidekiq::Shutdown => :never}
150
150
  private_constant :IGNORE_SHUTDOWN_INTERRUPTS
151
+ ALLOW_SHUTDOWN_INTERRUPTS = {Sidekiq::Shutdown => :immediate}
152
+ private_constant :ALLOW_SHUTDOWN_INTERRUPTS
151
153
 
152
154
  def process(uow)
153
155
  jobstr = uow.job
@@ -171,36 +173,35 @@ module Sidekiq
171
173
  end
172
174
 
173
175
  ack = false
174
- begin
175
- dispatch(job_hash, queue, jobstr) do |inst|
176
- config.server_middleware.invoke(inst, job_hash, queue) do
177
- execute_job(inst, job_hash["args"])
176
+ Thread.handle_interrupt(IGNORE_SHUTDOWN_INTERRUPTS) do
177
+ Thread.handle_interrupt(ALLOW_SHUTDOWN_INTERRUPTS) do
178
+ dispatch(job_hash, queue, jobstr) do |inst|
179
+ config.server_middleware.invoke(inst, job_hash, queue) do
180
+ execute_job(inst, job_hash["args"])
181
+ end
178
182
  end
183
+ ack = true
184
+ rescue Sidekiq::Shutdown
185
+ # Had to force kill this job because it didn't finish
186
+ # within the timeout. Don't acknowledge the work since
187
+ # we didn't properly finish it.
188
+ rescue Sidekiq::JobRetry::Handled => h
189
+ # this is the common case: job raised error and Sidekiq::JobRetry::Handled
190
+ # signals that we created a retry successfully. We can acknowlege the job.
191
+ ack = true
192
+ e = h.cause || h
193
+ handle_exception(e, {context: "Job raised exception", job: job_hash})
194
+ raise e
195
+ rescue Exception => ex
196
+ # Unexpected error! This is very bad and indicates an exception that got past
197
+ # the retry subsystem (e.g. network partition). We won't acknowledge the job
198
+ # so it can be rescued when using Sidekiq Pro.
199
+ handle_exception(ex, {context: "Internal exception!", job: job_hash, jobstr: jobstr})
200
+ raise ex
179
201
  end
180
- ack = true
181
- rescue Sidekiq::Shutdown
182
- # Had to force kill this job because it didn't finish
183
- # within the timeout. Don't acknowledge the work since
184
- # we didn't properly finish it.
185
- rescue Sidekiq::JobRetry::Handled => h
186
- # this is the common case: job raised error and Sidekiq::JobRetry::Handled
187
- # signals that we created a retry successfully. We can acknowlege the job.
188
- ack = true
189
- e = h.cause || h
190
- handle_exception(e, {context: "Job raised exception", job: job_hash})
191
- raise e
192
- rescue Exception => ex
193
- # Unexpected error! This is very bad and indicates an exception that got past
194
- # the retry subsystem (e.g. network partition). We won't acknowledge the job
195
- # so it can be rescued when using Sidekiq Pro.
196
- handle_exception(ex, {context: "Internal exception!", job: job_hash, jobstr: jobstr})
197
- raise ex
198
202
  ensure
199
203
  if ack
200
- # We don't want a shutdown signal to interrupt job acknowledgment.
201
- Thread.handle_interrupt(IGNORE_SHUTDOWN_INTERRUPTS) do
202
- uow.acknowledge
203
- end
204
+ uow.acknowledge
204
205
  end
205
206
  end
206
207
  end
data/lib/sidekiq/rails.rb CHANGED
@@ -20,6 +20,10 @@ module Sidekiq
20
20
  def inspect
21
21
  "#<Sidekiq::Rails::Reloader @app=#{@app.class.name}>"
22
22
  end
23
+
24
+ def to_json(*)
25
+ Sidekiq.dump_json(inspect)
26
+ end
23
27
  end
24
28
 
25
29
  # By including the Options module, we allow AJs to directly control sidekiq features
@@ -50,6 +54,12 @@ module Sidekiq
50
54
  end
51
55
  end
52
56
 
57
+ initializer "sidekiq.backtrace_cleaner" do
58
+ Sidekiq.configure_server do |config|
59
+ config[:backtrace_cleaner] = ->(backtrace) { ::Rails.backtrace_cleaner.clean(backtrace) }
60
+ end
61
+ end
62
+
53
63
  # This hook happens after all initializers are run, just before returning
54
64
  # from config/environment.rb back to sidekiq/cli.rb.
55
65
  #
@@ -1,5 +1,6 @@
1
1
  # frozen_string_literal: true
2
2
 
3
+ require "set"
3
4
  require "redis_client"
4
5
  require "redis_client/decorator"
5
6
 
@@ -8,13 +9,14 @@ module Sidekiq
8
9
  BaseError = RedisClient::Error
9
10
  CommandError = RedisClient::CommandError
10
11
 
12
+ # You can add/remove items or clear the whole thing if you don't want deprecation warnings.
13
+ DEPRECATED_COMMANDS = %i[rpoplpush zrangebyscore zrevrange zrevrangebyscore getset hmset setex setnx].to_set
14
+
11
15
  module CompatMethods
12
- # TODO Deprecate and remove this
13
16
  def info
14
17
  @client.call("INFO") { |i| i.lines(chomp: true).map { |l| l.split(":", 2) }.select { |l| l.size == 2 }.to_h }
15
18
  end
16
19
 
17
- # TODO Deprecate and remove this
18
20
  def evalsha(sha, keys, argv)
19
21
  @client.call("EVALSHA", sha, keys.size, *keys, *argv)
20
22
  end
@@ -24,6 +26,7 @@ module Sidekiq
24
26
  # this allows us to use methods like `conn.hmset(...)` instead of having to use
25
27
  # redis-client's native `conn.call("hmset", ...)`
26
28
  def method_missing(*args, &block)
29
+ warn("[sidekiq#5788] Redis has deprecated the `#{args.first}`command, called at #{caller(1..1)}") if DEPRECATED_COMMANDS.include?(args.first)
27
30
  @client.call(*args, *block)
28
31
  end
29
32
  ruby2_keywords :method_missing if respond_to?(:ruby2_keywords, true)
@@ -39,28 +42,6 @@ module Sidekiq
39
42
  def config
40
43
  @client.config
41
44
  end
42
-
43
- def message
44
- yield nil, @queue.pop
45
- end
46
-
47
- # NB: this method does not return
48
- def subscribe(chan)
49
- @queue = ::Queue.new
50
-
51
- pubsub = @client.pubsub
52
- pubsub.call("subscribe", chan)
53
-
54
- loop do
55
- evt = pubsub.next_event
56
- next if evt.nil?
57
- next unless evt[0] == "message" && evt[1] == chan
58
-
59
- (_, _, msg) = evt
60
- @queue << msg
61
- yield self
62
- end
63
- end
64
45
  end
65
46
 
66
47
  def initialize(options)
@@ -12,7 +12,7 @@ module Sidekiq
12
12
 
13
13
  LUA_ZPOPBYSCORE = <<~LUA
14
14
  local key, now = KEYS[1], ARGV[1]
15
- local jobs = redis.call("zrangebyscore", key, "-inf", now, "limit", 0, 1)
15
+ local jobs = redis.call("zrange", key, "-inf", now, "byscore", "limit", 0, 1)
16
16
  if jobs[1] then
17
17
  redis.call("zrem", key, jobs[1])
18
18
  return jobs[1]
@@ -1,6 +1,6 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module Sidekiq
4
- VERSION = "7.0.8"
4
+ VERSION = "7.1.4"
5
5
  MAJOR = 7
6
6
  end
@@ -15,11 +15,11 @@ module Sidekiq
15
15
  end
16
16
 
17
17
  def halt(res)
18
- throw :halt, [res, {"content-type" => "text/plain"}, [res.to_s]]
18
+ throw :halt, [res, {Rack::CONTENT_TYPE => "text/plain"}, [res.to_s]]
19
19
  end
20
20
 
21
21
  def redirect(location)
22
- throw :halt, [302, {"location" => "#{request.base_url}#{location}"}, []]
22
+ throw :halt, [302, {Web::LOCATION => "#{request.base_url}#{location}"}, []]
23
23
  end
24
24
 
25
25
  def params
@@ -68,7 +68,7 @@ module Sidekiq
68
68
  end
69
69
 
70
70
  def json(payload)
71
- [200, {"content-type" => "application/json", "cache-control" => "private, no-store"}, [Sidekiq.dump_json(payload)]]
71
+ [200, {Rack::CONTENT_TYPE => "application/json", Rack::CACHE_CONTROL => "private, no-store"}, [Sidekiq.dump_json(payload)]]
72
72
  end
73
73
 
74
74
  def initialize(env, block)
@@ -330,7 +330,7 @@ module Sidekiq
330
330
 
331
331
  def call(env)
332
332
  action = self.class.match(env)
333
- return [404, {"content-type" => "text/plain", "x-cascade" => "pass"}, ["Not Found"]] unless action
333
+ return [404, {Rack::CONTENT_TYPE => "text/plain", Web::X_CASCADE => "pass"}, ["Not Found"]] unless action
334
334
 
335
335
  app = @klass
336
336
  resp = catch(:halt) do
@@ -347,10 +347,10 @@ module Sidekiq
347
347
  else
348
348
  # rendered content goes here
349
349
  headers = {
350
- "content-type" => "text/html",
351
- "cache-control" => "private, no-store",
352
- "content-language" => action.locale,
353
- "content-security-policy" => CSP_HEADER
350
+ Rack::CONTENT_TYPE => "text/html",
351
+ Rack::CACHE_CONTROL => "private, no-store",
352
+ Web::CONTENT_LANGUAGE => action.locale,
353
+ Web::CONTENT_SECURITY_POLICY => CSP_HEADER
354
354
  }
355
355
  # we'll let Rack calculate Content-Length for us.
356
356
  [200, headers, [resp]]
@@ -62,7 +62,7 @@ module Sidekiq
62
62
 
63
63
  def deny(env)
64
64
  logger(env).warn "attack prevented by #{self.class}"
65
- [403, {"Content-Type" => "text/plain"}, ["Forbidden"]]
65
+ [403, {Rack::CONTENT_TYPE => "text/plain"}, ["Forbidden"]]
66
66
  end
67
67
 
68
68
  def session(env)
data/lib/sidekiq/web.rb CHANGED
@@ -34,6 +34,18 @@ module Sidekiq
34
34
  "Metrics" => "metrics"
35
35
  }
36
36
 
37
+ if Gem::Version.new(Rack::RELEASE) < Gem::Version.new("3")
38
+ CONTENT_LANGUAGE = "Content-Language"
39
+ CONTENT_SECURITY_POLICY = "Content-Security-Policy"
40
+ LOCATION = "Location"
41
+ X_CASCADE = "X-Cascade"
42
+ else
43
+ CONTENT_LANGUAGE = "content-language"
44
+ CONTENT_SECURITY_POLICY = "content-security-policy"
45
+ LOCATION = "location"
46
+ X_CASCADE = "x-cascade"
47
+ end
48
+
37
49
  class << self
38
50
  def settings
39
51
  self
@@ -137,7 +149,7 @@ module Sidekiq
137
149
  m = middlewares
138
150
 
139
151
  rules = []
140
- rules = [[:all, {"cache-control" => "public, max-age=86400"}]] unless ENV["SIDEKIQ_WEB_TESTING"]
152
+ rules = [[:all, {Rack::CACHE_CONTROL => "private, max-age=86400"}]] unless ENV["SIDEKIQ_WEB_TESTING"]
141
153
 
142
154
  ::Rack::Builder.new do
143
155
  use Rack::Static, urls: ["/stylesheets", "/images", "/javascripts"],
data/sidekiq.gemspec CHANGED
@@ -23,17 +23,8 @@ Gem::Specification.new do |gem|
23
23
  "rubygems_mfa_required" => "true"
24
24
  }
25
25
 
26
- gem.add_dependency "redis-client", ">= 0.11.0"
26
+ gem.add_dependency "redis-client", ">= 0.14.0"
27
27
  gem.add_dependency "connection_pool", ">= 2.3.0"
28
28
  gem.add_dependency "rack", ">= 2.2.4"
29
29
  gem.add_dependency "concurrent-ruby", "< 2"
30
- gem.post_install_message = <<~EOM
31
-
32
- Welcome to Sidekiq 7.0!
33
-
34
- 1. Use `gem 'sidekiq', '<7'` in your Gemfile if you don't want this new version.
35
- 2. Read the release notes at https://github.com/sidekiq/sidekiq/blob/main/docs/7.0-Upgrade.md
36
- 3. If you have problems, search for open/closed issues at https://github.com/sidekiq/sidekiq/issues/
37
-
38
- EOM
39
30
  end
@@ -140,6 +140,7 @@ function checkResponse(resp) {
140
140
 
141
141
  function scheduleLivePoll() {
142
142
  let ti = parseInt(localStorage.sidekiqTimeInterval) || 5000;
143
+ if (ti < 2000) { ti = 2000 }
143
144
  livePollTimer = setTimeout(livePollCallback, ti);
144
145
  }
145
146
 
@@ -57,7 +57,9 @@ class DashboardChart extends BaseChart {
57
57
  class RealtimeChart extends DashboardChart {
58
58
  constructor(el, options) {
59
59
  super(el, options);
60
- this.delay = parseInt(localStorage.sidekiqTimeInterval) || 5000;
60
+ let d = parseInt(localStorage.sidekiqTimeInterval) || 5000;
61
+ if (d < 2000) { d = 2000; }
62
+ this.delay = d
61
63
  this.startPolling();
62
64
  document.addEventListener("interval:update", this.handleUpdate.bind(this));
63
65
  }
data/web/locales/fr.yml CHANGED
@@ -17,14 +17,17 @@ fr:
17
17
  DeadJobs: Tâches mortes
18
18
  Delete: Supprimer
19
19
  DeleteAll: Tout supprimer
20
+ Deploy: Déploiement
20
21
  Enqueued: En attente
21
22
  Error: Erreur
22
23
  ErrorBacktrace: Backtrace d’erreur
23
24
  ErrorClass: Classe d’erreur
24
25
  ErrorMessage: Message d’erreur
26
+ ExecutionTime: Temps d'exécution
25
27
  Extras: Extras
26
28
  Failed: Échouées
27
29
  Failures: Echecs
30
+ Failure: Echec
28
31
  GoBack: ← Retour
29
32
  History: Historique
30
33
  Job: Tâche
@@ -35,6 +38,7 @@ fr:
35
38
  Latency: Latence
36
39
  LivePoll: Temps réel
37
40
  MemoryUsage: Mémoire utilisée
41
+ Name: Nom
38
42
  Namespace: Namespace
39
43
  NextRetry: Prochain essai
40
44
  NoDeadJobsFound: Aucune tâche morte n'a été trouvée
@@ -63,6 +67,7 @@ fr:
63
67
  RetryNow: Réessayer maintenant
64
68
  Scheduled: Planifiées
65
69
  ScheduledJobs: Tâches planifiées
70
+ Seconds: Secondes
66
71
  ShowAll: Tout montrer
67
72
  SixMonths: 6 mois
68
73
  Size: Taille
@@ -71,6 +76,8 @@ fr:
71
76
  Stop: Arrêter
72
77
  StopAll: Tout arrêter
73
78
  StopPolling: Arrêt du temps réel
79
+ Success: Succès
80
+ Summary: Résumé
74
81
  Thread: Thread
75
82
  Threads: Threads
76
83
  ThreeMonths: 3 mois
@@ -83,3 +90,10 @@ fr:
83
90
  Worker: Travailleur
84
91
  active: actif
85
92
  idle: inactif
93
+ Metrics: Métriques
94
+ NoDataFound: Aucune donnée disponible
95
+ TotalExecutionTime: Temps d'exécution total
96
+ AvgExecutionTime: Temps d'exécution moyen
97
+ Context: Contexte
98
+ Bucket: Bucket
99
+ NoJobMetricsFound: Aucune statistique de tâche récente n'a été trouvée
@@ -0,0 +1,99 @@
1
+ # elements like %{queue} are variables and should not be translated
2
+ gd:
3
+ Actions: Gnìomhan
4
+ AddToQueue: Cuir ris a’ chiutha
5
+ AreYouSure: A bheil thu cinnteach?
6
+ AreYouSureDeleteJob: A bheil thu cinnteach gu bheil thu airson an obair seo a sguabadh às?
7
+ AreYouSureDeleteQueue: A bheil thu cinnteach gu bheil thu airson ciutha %{queue} a sguabadh às? Sguabaidh seo às gach obair sa chiutha seo, nochdaidh e a-rithist nuair a phutas tu barrachd obraichean dha an uairsin.
8
+ Arguments: Argamaidean
9
+ BackToApp: Till dhan aplacaid
10
+ Busy: Trang
11
+ Class: Clas
12
+ Connections: Ceanglaichean
13
+ CreatedAt: Air a chruthachadh
14
+ CurrentMessagesInQueue: Obraichean làithreach am broinn <span class='title'>%{queue}</span>
15
+ Dashboard: Deas-bhòrd
16
+ Dead: Marbh
17
+ DeadJobs: Obraichean marbh
18
+ Delete: Sguab às
19
+ DeleteAll: Sguab às na h-uile
20
+ Deploy: Cuir an gnìomh
21
+ Enqueued: Sa chiutha
22
+ Error: Mearachd
23
+ ErrorBacktrace: Backtrace na mearachd
24
+ ErrorClass: Clas na mearachd
25
+ ErrorMessage: Teachdaireachd na mearachd
26
+ ExecutionTime: Àm a’ ghnìomha
27
+ Extras: Nithean a bharrachd
28
+ Failed: Air fàilligeadh
29
+ Failures: Fàilligidhean
30
+ Failure: Fàilligeadh
31
+ GoBack: ← Air ais
32
+ History: Eachdraidh
33
+ Job: Obair
34
+ Jobs: Obraichean
35
+ Kill: Marbh
36
+ KillAll: Marbh na h-uile
37
+ LastRetry: An oidhirp mu dheireadh
38
+ Latency: Foillidheachd
39
+ LivePoll: Ath-nuadhachadh beò
40
+ MemoryUsage: Cleachdadh a’ chuimhne
41
+ Name: Ainm
42
+ Namespace: Ainm-spàs
43
+ NextRetry: An ath-oidhirp
44
+ NoDeadJobsFound: Cha deach obair mharbh a lorg
45
+ NoRetriesFound: Cha deach ath-oidhirp a lorg
46
+ NoScheduledFound: Cha deach obair air an sgeideal a lorg
47
+ NotYetEnqueued: Chan eil seo sa chiutha fhathast
48
+ OneMonth: Mìos
49
+ OneWeek: Seachdain
50
+ OriginallyFailed: Dh’fhàillig e o thùs
51
+ Pause: Cuir ’na stad
52
+ Paused: ’Na stad
53
+ PeakMemoryUsage: Bàrr cleachdadh a’ chuimhne
54
+ Plugins: Plugain
55
+ PollingInterval: Eadaramh an ath-nuadhachaidh
56
+ Process: Pròiseas
57
+ Processed: Air pròiseasadh
58
+ Processes: Pròiseasan
59
+ Queue: Ciutha
60
+ Queues: Ciuthan
61
+ Quiet: Mùch
62
+ QuietAll: Mùch na h-uile
63
+ Realtime: Fìor-àm
64
+ Retries: Oidhirpean
65
+ RetryAll: Feuch ris na h-uile a-rithist
66
+ RetryCount: Cunntas nan oidhirpean
67
+ RetryNow: Feuch ris a-rithist an-dràsta
68
+ Scheduled: Air an sgeideal
69
+ ScheduledJobs: Obraichean air an sgeideal
70
+ Seconds: Diogan
71
+ ShowAll: Seall na h-uile
72
+ SixMonths: Leth-bhliadhna
73
+ Size: Meud
74
+ Started: Air a thòiseachadh
75
+ Status: Staid
76
+ Stop: Cuir stad air
77
+ StopAll: Cuir stad air na h-uile
78
+ StopPolling: Sguir dhen ath-nuadhachadh
79
+ Success: Chaidh leis
80
+ Summary: Geàrr-chunntas
81
+ Thread: Snàithlean
82
+ Threads: Snàithleanan
83
+ ThreeMonths: 3 mìosan
84
+ Time: Àm
85
+ Unpause: Lean air
86
+ Uptime: Beò fad (làithean)
87
+ Utilization: Cleachdadh
88
+ Version: Tionndadh
89
+ When: Cuin
90
+ Worker: Obraiche
91
+ active: gnìomhach
92
+ idle: ’na thàmh
93
+ Metrics: Meatraigeachd
94
+ NoDataFound: Cha deach dàta a lorg
95
+ TotalExecutionTime: Ùine iomlan nan gnìomhan
96
+ AvgExecutionTime: Ùine cuibheasach nan gnìomhan
97
+ Context: Co-theacsa
98
+ Bucket: Bucaid
99
+ NoJobMetricsFound: Cha deach meatraigeachd o chionn goirid air obair a lorg
@@ -5,10 +5,13 @@
5
5
  AreYouSureDeleteJob: Deseja deletar esta tarefa?
6
6
  AreYouSureDeleteQueue: Deseja deletar a fila %{queue}? Isso irá deletar todas as tarefas desta fila.
7
7
  Arguments: Argumentos
8
+ AvgExecutionTime: Tempo médio de execução
8
9
  BackToApp: De volta ao aplicativo
10
+ Bucket: Bucket
9
11
  Busy: Ocupados
10
12
  Class: Classe
11
13
  Connections: Conexões
14
+ Context: Contexto
12
15
  CreatedAt: Criado em
13
16
  CurrentMessagesInQueue: Mensagens atualmente na <span class='title'>%{queue}</span>
14
17
  Dashboard: Painel
@@ -16,13 +19,16 @@
16
19
  DeadJobs: Tarefas mortas
17
20
  Delete: Apagar
18
21
  DeleteAll: Apagar tudo
22
+ Deploy: Deploy
19
23
  Enqueued: Na fila
20
24
  Error: Erro
21
25
  ErrorBacktrace: Rastreamento do erro
22
26
  ErrorClass: Classe de erro
23
27
  ErrorMessage: Mensagem de erro
28
+ ExecutionTime: Tempo de execução
24
29
  Extras: Extras
25
30
  Failed: Falhas
31
+ Failure: Falha
26
32
  Failures: Falhas
27
33
  GoBack: ← Voltar
28
34
  History: Histórico
@@ -34,10 +40,13 @@
34
40
  Latency: Latência
35
41
  LivePoll: Live Poll
36
42
  MemoryUsage: Uso de memória
43
+ Metrics: Métricas
37
44
  Name: Nome
38
45
  Namespace: Namespace
39
46
  NextRetry: Próxima Tentativa
47
+ NoDataFound: Nenhum dado encontrado
40
48
  NoDeadJobsFound: Nenhuma tarefa morta foi encontrada
49
+ NoJobMetricsFound: Nenhuma métrica de tarefa encontrada
41
50
  NoRetriesFound: Nenhuma tentativa encontrada
42
51
  NoScheduledFound: Nenhuma tarefa agendada foi encontrada
43
52
  NotYetEnqueued: Ainda não enfileirado
@@ -47,6 +56,7 @@
47
56
  Pause: Pausar
48
57
  Paused: Pausado
49
58
  PeakMemoryUsage: Pico de uso de memória
59
+ Uptime: Tempo de atividade
50
60
  Plugins: Plug-ins
51
61
  PollingInterval: Intervalo de Polling
52
62
  Process: Processo
@@ -63,14 +73,24 @@
63
73
  RetryNow: Tentar novamente agora
64
74
  Scheduled: Agendados
65
75
  ScheduledJobs: Tarefas agendadas
76
+ idle: Ocioso
77
+ active: Ativo
78
+ Seconds: Segundos
66
79
  ShowAll: Mostrar todos
67
80
  SixMonths: 6 meses
68
81
  Size: Tamanho
82
+ Started: Iniciado
69
83
  Stop: Parar
70
84
  StopAll: Parar Todos
71
85
  StopPolling: Parar Polling
86
+ Success: Sucesso
87
+ Summary: Resumo
72
88
  Thread: Thread
73
89
  Threads: Threads
90
+ ThreeMonths: 3 meses
91
+ TotalExecutionTime: Tempo total de execução
74
92
  Unpause: Despausar
75
93
  Utilization: Utilização
94
+ Version: Versão
95
+ When: Quando
76
96
  Worker: Trabalhador
@@ -37,7 +37,7 @@
37
37
  <tr>
38
38
  <th>BID</th>
39
39
  <td>
40
- <a href="<%= root_path %>batches/<%= job.bid %>"><%= job.bid %>
40
+ <a href="<%= root_path %>batches/<%= job.bid %>"><%= job.bid %></a>
41
41
  </td>
42
42
  </tr>
43
43
  <% end %>
data/web/views/busy.erb CHANGED
@@ -33,8 +33,8 @@
33
33
  <form method="POST" class="warning-messages">
34
34
  <%= csrf_tag %>
35
35
  <div class="btn-group pull-right flip">
36
- <button class="btn btn-warn" type="submit" name="quiet" value="1" data-confirm="<%= t('AreYouSure') %>"><%= t('QuietAll') %></button>
37
- <button class="btn btn-danger" type="submit" name="stop" value="1" data-confirm="<%= t('AreYouSure') %>"><%= t('StopAll') %></button>
36
+ <input class="btn btn-warn" type="submit" name="quiet" value="<%= t('QuietAll') %>" data-confirm="<%= t('AreYouSure') %>"/>
37
+ <input class="btn btn-danger" type="submit" name="stop" value="<%= t('StopAll') %>" data-confirm="<%= t('AreYouSure') %>"/>
38
38
  </div>
39
39
  </form>
40
40
  </div>