talentbox-delayed_job_sequel 4.0.0 → 4.0.1

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 4f8e892e566b9bc3eb6eb7a1f2d35d94ffbde5a5
4
- data.tar.gz: 2bba9ee791fa8e372ad39080a328be34655d8d69
3
+ metadata.gz: d45ac6c7bc184fb66e341cc59236553f1115e6e3
4
+ data.tar.gz: 970a765aa1627ffe051f5daeb691ebe67f49dd96
5
5
  SHA512:
6
- metadata.gz: b9f5b3c244e2f6ae39260bd9423901cc3d596bc068234cc290ab9d4881227c3721f2f18c6c9f7159ab7305cf5e213605b9a0e56db588b81858598a0be485a1bf
7
- data.tar.gz: 5df02d82391bf890322db2539d9cf2091ba041543c40aa40cebdf5db540cbb3482babf0179f31c6aaae10cdd68403724ab649e1c5623d699b98307547c232de8
6
+ metadata.gz: 510bb5253ca7c083cdd0106c58f4ded8fc402b7621e9e99d90f33b283937d788cdab16e75bb24eba4aea107fc9e7644b7a84a29454671ca59c52d2974d707de9
7
+ data.tar.gz: 85e338fcc518bd581abca679b5b8a0eec6e643121aa71eace78b6e81a3818ea0d08f2cd1b88550a884319a8a87875c576ff783f186b373f4b0f3895b0b8129d4
data/README.md CHANGED
@@ -5,12 +5,9 @@
5
5
 
6
6
  ## Compatibility
7
7
 
8
- This gem works on Ruby (MRI/CRuby) 1.8.x, 1.9.x and Rubinius (1.8 and 1.9 mode).
8
+ This gem works on Ruby (MRI/CRuby) 1.9.3 and 2.0.x.
9
9
 
10
- But beware, if you're running it on Ruby (MRI/CRuby) 1.8.x or Rubinius in 1.8 mode you need
11
- to use a version of Sequel <= 3.28.0.
12
-
13
- It's strongly recommended to use a Ruby 1.9.x version.
10
+ It's strongly recommended to use a Ruby >= 1.9.3 version.
14
11
 
15
12
  ## Installation
16
13
 
@@ -6,11 +6,6 @@ module Delayed
6
6
  klass.class_eval do
7
7
  if YAML.parser.class.name =~ /syck/i
8
8
  yaml_as "tag:ruby.yaml.org,2002:Sequel"
9
- else
10
- def self.inherited(child)
11
- super
12
- child.yaml_as ['!ruby/Sequel', child.name].join(':')
13
- end
14
9
  end
15
10
  end
16
11
  end
@@ -33,7 +28,6 @@ module Delayed
33
28
  else
34
29
  def encode_with(coder)
35
30
  coder["values"] = @values
36
- coder.tag = ['!ruby/Sequel', self.class.name].join(':')
37
31
  end
38
32
 
39
33
  def init_with(coder)
@@ -47,4 +41,5 @@ module Delayed
47
41
  end
48
42
  end
49
43
  end
44
+
50
45
  Sequel::Model.plugin Delayed::Serialization::Sequel
@@ -1,5 +1,6 @@
1
1
  require 'sequel'
2
2
  require 'delayed_job'
3
3
  require 'delayed/backend/sequel'
4
+ require 'delayed/serialization/sequel'
4
5
 
5
6
  Delayed::Worker.backend = :sequel
@@ -7,17 +7,25 @@ require "rspec"
7
7
  require "logger"
8
8
  require "sequel"
9
9
 
10
+ def jruby?
11
+ (defined?(RUBY_ENGINE) && RUBY_ENGINE=="jruby") || defined?(JRUBY_VERSION)
12
+ end
13
+
10
14
  DB = case ENV["DB"]
11
15
  when "mysql"
12
16
  begin
13
- Sequel.connect :adapter => "mysql2", :database => "delayed_jobs", :test => true
17
+ Sequel.connect adapter: "mysql2", database: "delayed_jobs", test: true
14
18
  rescue Sequel::DatabaseConnectionError
15
19
  system "mysql -e 'CREATE DATABASE IF NOT EXISTS `delayed_jobs` DEFAULT CHARACTER SET utf8 DEFAULT COLLATE utf8_unicode_ci'"
16
20
  retry
17
21
  end
18
22
  when "postgres"
19
23
  begin
20
- Sequel.connect :adapter => "postgres", :database => "delayed_jobs", :test => true
24
+ if jruby?
25
+ Sequel.connect "jdbc:postgresql://localhost/delayed_jobs", test: true
26
+ else
27
+ Sequel.connect adapter: "postgres", database: "delayed_jobs", test: true
28
+ end
21
29
  rescue Sequel::DatabaseConnectionError
22
30
  system "createdb --encoding=UTF8 delayed_jobs"
23
31
  retry
metadata CHANGED
@@ -1,18 +1,18 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: talentbox-delayed_job_sequel
3
3
  version: !ruby/object:Gem::Version
4
- version: 4.0.0
4
+ version: 4.0.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Jonathan Tron
8
- autorequire:
8
+ autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2013-10-29 00:00:00.000000000 Z
11
+ date: 2014-02-04 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: sequel
15
- requirement: !ruby/object:Gem::Requirement
15
+ version_requirements: !ruby/object:Gem::Requirement
16
16
  requirements:
17
17
  - - '>='
18
18
  - !ruby/object:Gem::Version
@@ -20,9 +20,7 @@ dependencies:
20
20
  - - <
21
21
  - !ruby/object:Gem::Version
22
22
  version: '5.0'
23
- type: :runtime
24
- prerelease: false
25
- version_requirements: !ruby/object:Gem::Requirement
23
+ requirement: !ruby/object:Gem::Requirement
26
24
  requirements:
27
25
  - - '>='
28
26
  - !ruby/object:Gem::Version
@@ -30,62 +28,64 @@ dependencies:
30
28
  - - <
31
29
  - !ruby/object:Gem::Version
32
30
  version: '5.0'
31
+ prerelease: false
32
+ type: :runtime
33
33
  - !ruby/object:Gem::Dependency
34
34
  name: delayed_job
35
- requirement: !ruby/object:Gem::Requirement
35
+ version_requirements: !ruby/object:Gem::Requirement
36
36
  requirements:
37
37
  - - ~>
38
38
  - !ruby/object:Gem::Version
39
39
  version: 4.0.0
40
- type: :runtime
41
- prerelease: false
42
- version_requirements: !ruby/object:Gem::Requirement
40
+ requirement: !ruby/object:Gem::Requirement
43
41
  requirements:
44
42
  - - ~>
45
43
  - !ruby/object:Gem::Version
46
44
  version: 4.0.0
45
+ prerelease: false
46
+ type: :runtime
47
47
  - !ruby/object:Gem::Dependency
48
48
  name: tzinfo
49
- requirement: !ruby/object:Gem::Requirement
49
+ version_requirements: !ruby/object:Gem::Requirement
50
50
  requirements:
51
51
  - - '>='
52
52
  - !ruby/object:Gem::Version
53
53
  version: '0'
54
- type: :runtime
55
- prerelease: false
56
- version_requirements: !ruby/object:Gem::Requirement
54
+ requirement: !ruby/object:Gem::Requirement
57
55
  requirements:
58
56
  - - '>='
59
57
  - !ruby/object:Gem::Version
60
58
  version: '0'
59
+ prerelease: false
60
+ type: :runtime
61
61
  - !ruby/object:Gem::Dependency
62
62
  name: rspec
63
- requirement: !ruby/object:Gem::Requirement
63
+ version_requirements: !ruby/object:Gem::Requirement
64
64
  requirements:
65
65
  - - ~>
66
66
  - !ruby/object:Gem::Version
67
67
  version: '2.13'
68
- type: :development
69
- prerelease: false
70
- version_requirements: !ruby/object:Gem::Requirement
68
+ requirement: !ruby/object:Gem::Requirement
71
69
  requirements:
72
70
  - - ~>
73
71
  - !ruby/object:Gem::Version
74
72
  version: '2.13'
73
+ prerelease: false
74
+ type: :development
75
75
  - !ruby/object:Gem::Dependency
76
76
  name: rake
77
- requirement: !ruby/object:Gem::Requirement
77
+ version_requirements: !ruby/object:Gem::Requirement
78
78
  requirements:
79
79
  - - '>='
80
80
  - !ruby/object:Gem::Version
81
81
  version: '0'
82
- type: :development
83
- prerelease: false
84
- version_requirements: !ruby/object:Gem::Requirement
82
+ requirement: !ruby/object:Gem::Requirement
85
83
  requirements:
86
84
  - - '>='
87
85
  - !ruby/object:Gem::Version
88
86
  version: '0'
87
+ prerelease: false
88
+ type: :development
89
89
  description: Sequel backend for DelayedJob, originally authored by Tobias Luetke
90
90
  email:
91
91
  - jonathan@tron.name
@@ -94,20 +94,20 @@ extensions: []
94
94
  extra_rdoc_files:
95
95
  - README.md
96
96
  files:
97
+ - lib/delayed_job_sequel.rb
97
98
  - lib/delayed/backend/sequel.rb
98
99
  - lib/delayed/serialization/sequel.rb
99
- - lib/delayed_job_sequel.rb
100
100
  - lib/generators/delayed_job/sequel_generator.rb
101
101
  - lib/generators/delayed_job/templates/migration.rb
102
+ - spec/spec_helper.rb
102
103
  - spec/delayed/backend/sequel_spec.rb
103
104
  - spec/delayed/serialization/sequel_spec.rb
104
- - spec/spec_helper.rb
105
105
  - LICENSE
106
106
  - README.md
107
107
  homepage: http://github.com/TalentBox/delayed_job_sequel
108
108
  licenses: []
109
109
  metadata: {}
110
- post_install_message:
110
+ post_install_message:
111
111
  rdoc_options:
112
112
  - --main
113
113
  - README.md
@@ -126,12 +126,12 @@ required_rubygems_version: !ruby/object:Gem::Requirement
126
126
  - !ruby/object:Gem::Version
127
127
  version: '0'
128
128
  requirements: []
129
- rubyforge_project:
129
+ rubyforge_project:
130
130
  rubygems_version: 2.1.9
131
- signing_key:
131
+ signing_key:
132
132
  specification_version: 4
133
133
  summary: Sequel backend for DelayedJob
134
134
  test_files:
135
+ - spec/spec_helper.rb
135
136
  - spec/delayed/backend/sequel_spec.rb
136
137
  - spec/delayed/serialization/sequel_spec.rb
137
- - spec/spec_helper.rb