kiqstand 1.0.0 → 1.1.0

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.
@@ -0,0 +1,7 @@
1
+ ---
2
+ SHA1:
3
+ metadata.gz: 673aba8f089c697f0801a40928efc551fbef1361
4
+ data.tar.gz: c9c4b952e4f57f9cb916602979dfae9f0de34f30
5
+ SHA512:
6
+ metadata.gz: 4f41f2dc13667d57decece25e3dbf9d7ddd0033a8c2f6c96986225cbf7a1471cd590cb7c190ed3b05be0fd9c780150e43571b66b92efcb9b052f9a5a0cfcd07d
7
+ data.tar.gz: 108f871a278dbf29e02df4263e3e8cd6084585d4c071c68909b89fd0491f875b71e67e5bc950cded4cc11bd8bf04a80ada513bed310010bc09b3acf998f9a267
data/LICENSE CHANGED
@@ -1,4 +1,4 @@
1
- Copyright (c) 2009-2012 Durran Jordan
1
+ Copyright (c) 2012-2013 Durran Jordan
2
2
 
3
3
  Permission is hereby granted, free of charge, to any person obtaining
4
4
  a copy of this software and associated documentation files (the
data/README.md CHANGED
@@ -8,7 +8,8 @@ Compatibility
8
8
 
9
9
  Kiqstand is tested against MRI 1.9.3, 2.0.0.
10
10
 
11
- Kiqstand requires at least Mongoid 3.0.3, and Moped 1.2.0.
11
+ Use Kiqstand 1.0.x with Mongoid 3.0.x
12
+ Use Kiqstand 1.1.x with Mongoid 3.1.x
12
13
 
13
14
  Documentation
14
15
  -------------
@@ -38,7 +39,7 @@ end
38
39
  License
39
40
  -------
40
41
 
41
- Copyright (c) 2012 Durran Jordan
42
+ Copyright (c) 2012-2013 Durran Jordan
42
43
 
43
44
  Permission is hereby granted, free of charge, to any person obtaining
44
45
  a copy of this software and associated documentation files (the
@@ -2,26 +2,25 @@
2
2
  module Kiqstand
3
3
 
4
4
  # This is the middleware for ensuring Moped sessions are diconnected after
5
- # a worker runs.
5
+ # a worker runs, and that the identity map is cleared.
6
6
  class Middleware
7
7
 
8
8
  # Ensures that after each worker runs, the identity map is cleared in case
9
9
  # it was accidentally enabled in this environment, and each session
10
10
  # disconnects it's nodes.
11
+ #
12
+ # @example Execute the worker.
13
+ # worker.call
14
+ #
15
+ # @param [ Array ] args The arguments for the worker.
16
+ #
17
+ # @since 1.0.0
11
18
  def call(*args)
12
19
  yield
13
20
  ensure
14
21
  if defined?(::Mongoid)
15
22
  ::Mongoid::IdentityMap.clear
16
- disconnect_sessions
17
- end
18
- end
19
-
20
- private
21
-
22
- def disconnect_sessions
23
- ::Mongoid::Threaded.sessions.each_pair do |_, session|
24
- session.disconnect
23
+ ::Mongoid.disconnect_sessions
25
24
  end
26
25
  end
27
26
  end
@@ -1,4 +1,4 @@
1
1
  # encoding: utf-8
2
2
  module Kiqstand
3
- VERSION = "1.0.0"
3
+ VERSION = "1.1.0"
4
4
  end
metadata CHANGED
@@ -1,49 +1,44 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: kiqstand
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.0
5
- prerelease:
4
+ version: 1.1.0
6
5
  platform: ruby
7
6
  authors:
8
7
  - Durran Jordan
9
8
  autorequire:
10
9
  bindir: bin
11
10
  cert_chain: []
12
- date: 2012-07-29 00:00:00.000000000 Z
11
+ date: 2013-04-09 00:00:00.000000000 Z
13
12
  dependencies:
14
13
  - !ruby/object:Gem::Dependency
15
14
  name: mongoid
16
15
  requirement: !ruby/object:Gem::Requirement
17
- none: false
18
16
  requirements:
19
17
  - - ~>
20
18
  - !ruby/object:Gem::Version
21
- version: '3.0'
19
+ version: '3.1'
22
20
  type: :runtime
23
21
  prerelease: false
24
22
  version_requirements: !ruby/object:Gem::Requirement
25
- none: false
26
23
  requirements:
27
24
  - - ~>
28
25
  - !ruby/object:Gem::Version
29
- version: '3.0'
26
+ version: '3.1'
30
27
  - !ruby/object:Gem::Dependency
31
28
  name: moped
32
29
  requirement: !ruby/object:Gem::Requirement
33
- none: false
34
30
  requirements:
35
31
  - - ~>
36
32
  - !ruby/object:Gem::Version
37
- version: '1.2'
33
+ version: '1.4'
38
34
  type: :runtime
39
35
  prerelease: false
40
36
  version_requirements: !ruby/object:Gem::Requirement
41
- none: false
42
37
  requirements:
43
38
  - - ~>
44
39
  - !ruby/object:Gem::Version
45
- version: '1.2'
46
- description: Mongoid 3 Middleware for Sidekiq
40
+ version: '1.4'
41
+ description: Mongoid Middleware for Sidekiq
47
42
  email:
48
43
  - durran@gmail.com
49
44
  executables: []
@@ -59,29 +54,25 @@ files:
59
54
  - Rakefile
60
55
  homepage: http://mongoid.org
61
56
  licenses: []
57
+ metadata: {}
62
58
  post_install_message:
63
59
  rdoc_options: []
64
60
  require_paths:
65
61
  - lib
66
62
  required_ruby_version: !ruby/object:Gem::Requirement
67
- none: false
68
63
  requirements:
69
- - - ! '>='
64
+ - - '>='
70
65
  - !ruby/object:Gem::Version
71
66
  version: '0'
72
- segments:
73
- - 0
74
- hash: 2502054094086232256
75
67
  required_rubygems_version: !ruby/object:Gem::Requirement
76
- none: false
77
68
  requirements:
78
- - - ! '>='
69
+ - - '>='
79
70
  - !ruby/object:Gem::Version
80
71
  version: 1.3.6
81
72
  requirements: []
82
73
  rubyforge_project: kiqstand
83
- rubygems_version: 1.8.24
74
+ rubygems_version: 2.0.3
84
75
  signing_key:
85
- specification_version: 3
86
- summary: Mongoid 3 Middleware for Sidekiq
76
+ specification_version: 4
77
+ summary: Mongoid Middleware for Sidekiq
87
78
  test_files: []