delayed_job_active_record 4.1.1 → 4.1.2
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/README.md +6 -6
- data/delayed_job_active_record.gemspec +2 -2
- data/lib/generators/delayed_job/active_record_generator.rb +9 -1
- data/lib/generators/delayed_job/templates/migration.rb +1 -1
- data/lib/generators/delayed_job/templates/upgrade_migration.rb +1 -1
- data/lib/generators/delayed_job/upgrade_generator.rb +2 -11
- metadata +5 -5
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: 587c2fcfd39aed7965f484c0e9ba9bc94dba926b
|
4
|
+
data.tar.gz: d71c55d818a0e780d972bb35c0d665195e47467e
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 123564b7b3f54d4ee8cdd1673e5fb5471f564e1306a69c3fc07e4e6b4ea6608f448f493170840137604705731ba9e5f488c00ed6a1272fd9f263622e83db385e
|
7
|
+
data.tar.gz: fa7fff077b2f611118b21abf9e106cf8b210c5ad1b9404dc9c6c8c678164f991486bd38f885e062cef233d4a082c03badca4bc333bec92f25d138215b0215184
|
data/README.md
CHANGED
@@ -1,15 +1,15 @@
|
|
1
1
|
**If you're viewing this at https://github.com/collectiveidea/delayed_job_active_record,
|
2
2
|
you're reading the documentation for the master branch.
|
3
3
|
[View documentation for the latest release
|
4
|
-
(4.1.
|
4
|
+
(4.1.2).](https://github.com/collectiveidea/delayed_job_active_record/tree/v4.1.2)**
|
5
5
|
|
6
6
|
# DelayedJob ActiveRecord Backend
|
7
7
|
|
8
|
-
[![Gem Version](https://
|
9
|
-
[![Build Status](https://
|
10
|
-
[![Dependency Status](https://
|
11
|
-
[![Code Climate](https://
|
12
|
-
[![Coverage Status](https://
|
8
|
+
[![Gem Version](https://img.shields.io/gem/v/delayed_job_active_record.svg)](https://rubygems.org/gems/delayed_job_active_record)
|
9
|
+
[![Build Status](https://img.shields.io/travis/collectiveidea/delayed_job_active_record.svg)](https://travis-ci.org/collectiveidea/delayed_job_active_record)
|
10
|
+
[![Dependency Status](https://img.shields.io/gemnasium/collectiveidea/delayed_job_active_record.svg)](https://gemnasium.com/collectiveidea/delayed_job_active_record)
|
11
|
+
[![Code Climate](https://img.shields.io/codeclimate/github/collectiveidea/delayed_job_active_record.svg)](https://codeclimate.com/github/collectiveidea/delayed_job_active_record)
|
12
|
+
[![Coverage Status](https://img.shields.io/coveralls/collectiveidea/delayed_job_active_record.svg)](https://coveralls.io/r/collectiveidea/delayed_job_active_record)
|
13
13
|
|
14
14
|
## Installation
|
15
15
|
|
@@ -1,5 +1,5 @@
|
|
1
1
|
Gem::Specification.new do |spec|
|
2
|
-
spec.add_dependency "activerecord", [">= 3.0", "< 5.
|
2
|
+
spec.add_dependency "activerecord", [">= 3.0", "< 5.2"]
|
3
3
|
spec.add_dependency "delayed_job", [">= 3.0", "< 5"]
|
4
4
|
spec.authors = ["Brian Ryckbost", "Matt Griffin", "Erik Michaels-Ober"]
|
5
5
|
spec.description = "ActiveRecord backend for Delayed::Job, originally authored by Tobias Lütke"
|
@@ -10,5 +10,5 @@ Gem::Specification.new do |spec|
|
|
10
10
|
spec.name = "delayed_job_active_record"
|
11
11
|
spec.require_paths = ["lib"]
|
12
12
|
spec.summary = "ActiveRecord backend for DelayedJob"
|
13
|
-
spec.version = "4.1.
|
13
|
+
spec.version = "4.1.2"
|
14
14
|
end
|
@@ -12,11 +12,19 @@ module DelayedJob
|
|
12
12
|
source_paths << File.join(File.dirname(__FILE__), "templates")
|
13
13
|
|
14
14
|
def create_migration_file
|
15
|
-
migration_template "migration.rb", "db/migrate/create_delayed_jobs.rb"
|
15
|
+
migration_template "migration.rb", "db/migrate/create_delayed_jobs.rb", migration_version: migration_version
|
16
16
|
end
|
17
17
|
|
18
18
|
def self.next_migration_number(dirname)
|
19
19
|
ActiveRecord::Generators::Base.next_migration_number dirname
|
20
20
|
end
|
21
|
+
|
22
|
+
private
|
23
|
+
|
24
|
+
def migration_version
|
25
|
+
if ActiveRecord::VERSION::MAJOR >= 5
|
26
|
+
"[#{ActiveRecord::VERSION::MAJOR}.#{ActiveRecord::VERSION::MINOR}]"
|
27
|
+
end
|
28
|
+
end
|
21
29
|
end
|
22
30
|
end
|
@@ -1,4 +1,4 @@
|
|
1
|
-
class CreateDelayedJobs < ActiveRecord::Migration
|
1
|
+
class CreateDelayedJobs < ActiveRecord::Migration<%= migration_version %>
|
2
2
|
def self.up
|
3
3
|
create_table :delayed_jobs, force: true do |table|
|
4
4
|
table.integer :priority, default: 0, null: false # Allows some jobs to jump to the front of the queue
|
@@ -5,18 +5,9 @@ require "rails/generators/active_record"
|
|
5
5
|
|
6
6
|
# Extend the DelayedJobGenerator so that it creates an AR migration
|
7
7
|
module DelayedJob
|
8
|
-
class UpgradeGenerator <
|
9
|
-
include Rails::Generators::Migration
|
10
|
-
extend NextMigrationVersion
|
11
|
-
|
12
|
-
source_paths << File.join(File.dirname(__FILE__), "templates")
|
13
|
-
|
8
|
+
class UpgradeGenerator < ActiveRecordGenerator
|
14
9
|
def create_migration_file
|
15
|
-
migration_template "upgrade_migration.rb", "db/migrate/add_queue_to_delayed_jobs.rb"
|
16
|
-
end
|
17
|
-
|
18
|
-
def self.next_migration_number(dirname)
|
19
|
-
ActiveRecord::Generators::Base.next_migration_number dirname
|
10
|
+
migration_template "upgrade_migration.rb", "db/migrate/add_queue_to_delayed_jobs.rb", migration_version: migration_version
|
20
11
|
end
|
21
12
|
end
|
22
13
|
end
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: delayed_job_active_record
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 4.1.
|
4
|
+
version: 4.1.2
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Brian Ryckbost
|
@@ -10,7 +10,7 @@ authors:
|
|
10
10
|
autorequire:
|
11
11
|
bindir: bin
|
12
12
|
cert_chain: []
|
13
|
-
date:
|
13
|
+
date: 2017-05-27 00:00:00.000000000 Z
|
14
14
|
dependencies:
|
15
15
|
- !ruby/object:Gem::Dependency
|
16
16
|
name: activerecord
|
@@ -21,7 +21,7 @@ dependencies:
|
|
21
21
|
version: '3.0'
|
22
22
|
- - "<"
|
23
23
|
- !ruby/object:Gem::Version
|
24
|
-
version: '5.
|
24
|
+
version: '5.2'
|
25
25
|
type: :runtime
|
26
26
|
prerelease: false
|
27
27
|
version_requirements: !ruby/object:Gem::Requirement
|
@@ -31,7 +31,7 @@ dependencies:
|
|
31
31
|
version: '3.0'
|
32
32
|
- - "<"
|
33
33
|
- !ruby/object:Gem::Version
|
34
|
-
version: '5.
|
34
|
+
version: '5.2'
|
35
35
|
- !ruby/object:Gem::Dependency
|
36
36
|
name: delayed_job
|
37
37
|
requirement: !ruby/object:Gem::Requirement
|
@@ -93,7 +93,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
93
93
|
version: '0'
|
94
94
|
requirements: []
|
95
95
|
rubyforge_project:
|
96
|
-
rubygems_version: 2.
|
96
|
+
rubygems_version: 2.6.11
|
97
97
|
signing_key:
|
98
98
|
specification_version: 4
|
99
99
|
summary: ActiveRecord backend for DelayedJob
|