1
0
Fork 0
mirror of https://github.com/mperham/sidekiq.git synced 2022-11-09 13:52:34 -05:00

merge master

This commit is contained in:
Mike Perham 2015-10-22 11:41:09 -07:00
commit 87df35a04d
10 changed files with 49 additions and 8 deletions

View file

@ -3,6 +3,13 @@ Sidekiq Enterprise Changelog
Please see [http://sidekiq.org/](http://sidekiq.org/) for more details and how to buy. Please see [http://sidekiq.org/](http://sidekiq.org/) for more details and how to buy.
0.7.4
----------
- Add additional check to prevent duplicate periodic job creation
- Allow user-specified TTLs for rate limiters [#2607]
- Paginate rate limiter index page [#2606]
0.7.3 0.7.3
---------- ----------
@ -11,7 +18,6 @@ Please see [http://sidekiq.org/](http://sidekiq.org/) for more details and how t
rate limit errors. rate limit errors.
- Fix scalability issue with Limiter index page. - Fix scalability issue with Limiter index page.
0.7.2 0.7.2
---------- ----------
@ -23,7 +29,6 @@ Please see [http://sidekiq.org/](http://sidekiq.org/) for more details and how t
- Fix issue where unique scheduled jobs can't be enqueued upon schedule - Fix issue where unique scheduled jobs can't be enqueued upon schedule
due to the existing unique lock. [#2499] due to the existing unique lock. [#2499]
0.7.0 0.7.0
---------- ----------

View file

@ -3,6 +3,12 @@ Sidekiq Pro Changelog
Please see [http://sidekiq.org/](http://sidekiq.org/) for more details and how to buy. Please see [http://sidekiq.org/](http://sidekiq.org/) for more details and how to buy.
2.1.1
-----------
- Make ShardSet lazier so Redis can first be initialized at startup. [#2603]
2.1.0 2.1.0
----------- -----------

View file

@ -336,7 +336,11 @@ module Sidekiq
die 1 die 1
end end
@parser.parse!(argv) @parser.parse!(argv)
opts[:config_file] ||= 'config/sidekiq.yml' if File.exist?('config/sidekiq.yml')
%w[config/sidekiq.yml config/sidekiq.yml.erb].each do |filename|
opts[:config_file] ||= filename if File.exist?(filename)
end
opts opts
end end

View file

@ -38,6 +38,18 @@ module Sidekiq
module ClassMethods module ClassMethods
def delay(*args)
raise ArgumentError, "Do not call .delay on a Sidekiq::Worker class, call .perform_async"
end
def delay_for(*args)
raise ArgumentError, "Do not call .delay_for on a Sidekiq::Worker class, call .perform_in"
end
def delay_until(*args)
raise ArgumentError, "Do not call .delay_until on a Sidekiq::Worker class, call .perform_at"
end
def perform_async(*args) def perform_async(*args)
client_push('class' => self, 'args' => args) client_push('class' => self, 'args' => args)
end end

View file

@ -183,7 +183,6 @@ class TestApi < Sidekiq::Test
assert_equal [1, 'mike'], job.args assert_equal [1, 'mike'], job.args
assert_equal Time.new(2012, 12, 26), job.enqueued_at assert_equal Time.new(2012, 12, 26), job.enqueued_at
end end
assert q.latency > 10_000_000 assert q.latency > 10_000_000
q = Sidekiq::Queue.new('other') q = Sidekiq::Queue.new('other')
@ -197,13 +196,19 @@ class TestApi < Sidekiq::Test
end end
it 'unwraps delayed jobs' do it 'unwraps delayed jobs' do
ApiWorker.delay.foo(1,2,3) Sidekiq::Queue.delay.foo(1,2,3)
q = Sidekiq::Queue.new q = Sidekiq::Queue.new
x = q.first x = q.first
assert_equal "TestApi::ApiWorker.foo", x.display_class assert_equal "Sidekiq::Queue.foo", x.display_class
assert_equal [1,2,3], x.display_args assert_equal [1,2,3], x.display_args
end end
it 'has no enqueued_at time for jobs enqueued in the future' do
job_id = ApiWorker.perform_in(100, 1, 'foo')
job = Sidekiq::ScheduledSet.new.find_job(job_id)
assert_nil job.enqueued_at
end
it 'can delete jobs' do it 'can delete jobs' do
q = Sidekiq::Queue.new q = Sidekiq::Queue.new
ApiWorker.perform_async(1, 'mike') ApiWorker.perform_async(1, 'mike')

Binary file not shown.

After

Width:  |  Height:  |  Size: 5.3 KiB

View file

@ -58,9 +58,14 @@ function updatePage(url) {
url: url, url: url,
dataType: 'html' dataType: 'html'
}).done(function (data) { }).done(function (data) {
var $page = $(data).filter('#page') $data = $(data)
var $page = $data.filter('#page')
$('#page').replaceWith($page) $('#page').replaceWith($page)
var $header_status = $data.find('.status')
$('.status').replaceWith($header_status)
$("time").timeago() $("time").timeago()
}) })
}, parseInt(localStorage.timeInterval) || 2000); }, parseInt(localStorage.timeInterval) || 2000);

View file

@ -181,6 +181,10 @@ form .btn {
margin-right: 5px; margin-right: 5px;
} }
form .btn-group .btn {
margin-right: 1px;
}
td form { td form {
margin-bottom: 0; margin-bottom: 0;
} }

View file

@ -12,7 +12,6 @@
</form> </form>
</div> </div>
</div> </div>
</div>
<div class="table_container"> <div class="table_container">
<table class="processes table table-hover table-bordered table-striped table-white"> <table class="processes table table-hover table-bordered table-striped table-white">

View file

@ -5,6 +5,7 @@
<meta name="viewport" content="width=device-width,initial-scale=1.0" /> <meta name="viewport" content="width=device-width,initial-scale=1.0" />
<link href="<%= root_path %>stylesheets/bootstrap.css" media="screen" rel="stylesheet" type="text/css" /> <link href="<%= root_path %>stylesheets/bootstrap.css" media="screen" rel="stylesheet" type="text/css" />
<link href="<%= root_path %>stylesheets/application.css" media="screen" rel="stylesheet" type="text/css" /> <link href="<%= root_path %>stylesheets/application.css" media="screen" rel="stylesheet" type="text/css" />
<link rel="shortcut icon" type="image/ico" href="<%= root_path %>images/favicon.ico" />
<script type="text/javascript" src="<%= root_path %>javascripts/application.js"></script> <script type="text/javascript" src="<%= root_path %>javascripts/application.js"></script>
<script type="text/javascript" src="<%= root_path %>javascripts/locales/jquery.timeago.<%= locale %>.js"></script> <script type="text/javascript" src="<%= root_path %>javascripts/locales/jquery.timeago.<%= locale %>.js"></script>
<meta name="google" content="notranslate" /> <meta name="google" content="notranslate" />