beaneater 0.2.0 → 0.2.1
Sign up to get free protection for your applications and to get access to all the features.
- data/CHANGELOG.md +5 -1
- data/README.md +16 -9
- data/lib/beaneater/connection.rb +1 -0
- data/lib/beaneater/version.rb +1 -1
- metadata +91 -99
data/CHANGELOG.md
CHANGED
data/README.md
CHANGED
@@ -31,14 +31,19 @@ Beanstalkd supports the following features out of the box:
|
|
31
31
|
|
32
32
|
| Feature | Description |
|
33
33
|
| ------- | ------------------------------- |
|
34
|
-
| **
|
35
|
-
| **
|
36
|
-
| **
|
37
|
-
| **
|
38
|
-
| **
|
39
|
-
| **
|
40
|
-
| **
|
41
|
-
| **
|
34
|
+
| **Easy Setup** | Quick to install, no files to edit, no settings to tweak. |
|
35
|
+
| **Speed** | Process thousands of jobs per second without breaking a sweat. |
|
36
|
+
| **Client Support** | Client libraries exist for over 21 languages including Python, Ruby, and Go. |
|
37
|
+
| **Tubes** | Supports multiple work queues created automatically on demand. |
|
38
|
+
| **Reliable** | Beanstalk’s reserve, work, delete cycle ensures reliable processing. |
|
39
|
+
| **Scheduling** | Delay enqueuing jobs by a specified interval to be processed later. |
|
40
|
+
| **Priorities** | Important jobs go to the head of the queue and get processed sooner. |
|
41
|
+
| **Persistence** | Jobs are stored in memory for speed, but logged to disk for safe keeping. |
|
42
|
+
| **Scalability** | Client-side federation provides effortless horizontal scalability. |
|
43
|
+
| **Error Handling** | Bury any job which causes an error for later debugging and inspection. |
|
44
|
+
| **Simple Debugging** | Talk directly to the beanstalkd server over telnet to get a handle on your app. |
|
45
|
+
| **Efficiency** | Each beanstalkd process can handle tens of thousands of open connections. |
|
46
|
+
| **Memory Usage** | Use the built-in `ulimit` OS feature to cap beanstalkd's memory consumption. |
|
42
47
|
|
43
48
|
Keep in mind that these features are supported out of the box with beanstalk and requires no special ruby specific logic.
|
44
49
|
In the end, **beanstalk is the ideal job queue** and has the added benefit of being easy to setup and configure.
|
@@ -103,7 +108,7 @@ For a more detailed rundown, check out the __Usage__ section below.
|
|
103
108
|
|
104
109
|
### Configuration
|
105
110
|
|
106
|
-
To setup advanced options for beaneater
|
111
|
+
To setup advanced options for beaneater, you can pass configuration options using:
|
107
112
|
|
108
113
|
```ruby
|
109
114
|
Beaneater.configure do |config|
|
@@ -115,6 +120,8 @@ Beaneater.configure do |config|
|
|
115
120
|
end
|
116
121
|
```
|
117
122
|
|
123
|
+
The above options are all defaults, so only include a configuration block if you need to make changes.
|
124
|
+
|
118
125
|
### Connection
|
119
126
|
|
120
127
|
To interact with a beanstalk queue, first establish a connection by providing a set of addresses:
|
data/lib/beaneater/connection.rb
CHANGED
@@ -49,6 +49,7 @@ module Beaneater
|
|
49
49
|
def transmit(command, options={}, &block)
|
50
50
|
@mutex.lock
|
51
51
|
if telnet_connection
|
52
|
+
command = command.force_encoding('ASCII-8BIT') if command.respond_to?(:force_encoding)
|
52
53
|
options.merge!("String" => command, "FailEOF" => true, "Timeout" => false)
|
53
54
|
parse_response(command, telnet_connection.cmd(options, &block))
|
54
55
|
else # no telnet_connection
|
data/lib/beaneater/version.rb
CHANGED
metadata
CHANGED
@@ -1,118 +1,119 @@
|
|
1
|
-
--- !ruby/object:Gem::Specification
|
1
|
+
--- !ruby/object:Gem::Specification
|
2
2
|
name: beaneater
|
3
|
-
version: !ruby/object:Gem::Version
|
4
|
-
|
3
|
+
version: !ruby/object:Gem::Version
|
4
|
+
version: 0.2.1
|
5
5
|
prerelease:
|
6
|
-
segments:
|
7
|
-
- 0
|
8
|
-
- 2
|
9
|
-
- 0
|
10
|
-
version: 0.2.0
|
11
6
|
platform: ruby
|
12
|
-
authors:
|
7
|
+
authors:
|
13
8
|
- Nico Taing
|
14
9
|
autorequire:
|
15
10
|
bindir: bin
|
16
11
|
cert_chain: []
|
17
|
-
|
18
|
-
|
19
|
-
|
20
|
-
- !ruby/object:Gem::Dependency
|
12
|
+
date: 2012-12-01 00:00:00.000000000 Z
|
13
|
+
dependencies:
|
14
|
+
- !ruby/object:Gem::Dependency
|
21
15
|
name: minitest
|
22
|
-
|
16
|
+
requirement: !ruby/object:Gem::Requirement
|
23
17
|
none: false
|
24
|
-
requirements:
|
18
|
+
requirements:
|
25
19
|
- - ~>
|
26
|
-
- !ruby/object:Gem::Version
|
27
|
-
hash: 59
|
28
|
-
segments:
|
29
|
-
- 4
|
30
|
-
- 1
|
31
|
-
- 0
|
20
|
+
- !ruby/object:Gem::Version
|
32
21
|
version: 4.1.0
|
33
22
|
type: :development
|
34
|
-
requirement: *id001
|
35
23
|
prerelease: false
|
36
|
-
|
24
|
+
version_requirements: !ruby/object:Gem::Requirement
|
25
|
+
none: false
|
26
|
+
requirements:
|
27
|
+
- - ~>
|
28
|
+
- !ruby/object:Gem::Version
|
29
|
+
version: 4.1.0
|
30
|
+
- !ruby/object:Gem::Dependency
|
37
31
|
name: rake
|
38
|
-
|
32
|
+
requirement: !ruby/object:Gem::Requirement
|
39
33
|
none: false
|
40
|
-
requirements:
|
41
|
-
- -
|
42
|
-
- !ruby/object:Gem::Version
|
43
|
-
|
44
|
-
segments:
|
45
|
-
- 0
|
46
|
-
version: "0"
|
34
|
+
requirements:
|
35
|
+
- - ! '>='
|
36
|
+
- !ruby/object:Gem::Version
|
37
|
+
version: '0'
|
47
38
|
type: :development
|
48
|
-
requirement: *id002
|
49
39
|
prerelease: false
|
50
|
-
|
40
|
+
version_requirements: !ruby/object:Gem::Requirement
|
41
|
+
none: false
|
42
|
+
requirements:
|
43
|
+
- - ! '>='
|
44
|
+
- !ruby/object:Gem::Version
|
45
|
+
version: '0'
|
46
|
+
- !ruby/object:Gem::Dependency
|
51
47
|
name: mocha
|
52
|
-
|
48
|
+
requirement: !ruby/object:Gem::Requirement
|
53
49
|
none: false
|
54
|
-
requirements:
|
55
|
-
- -
|
56
|
-
- !ruby/object:Gem::Version
|
57
|
-
|
58
|
-
segments:
|
59
|
-
- 0
|
60
|
-
version: "0"
|
50
|
+
requirements:
|
51
|
+
- - ! '>='
|
52
|
+
- !ruby/object:Gem::Version
|
53
|
+
version: '0'
|
61
54
|
type: :development
|
62
|
-
requirement: *id003
|
63
55
|
prerelease: false
|
64
|
-
|
56
|
+
version_requirements: !ruby/object:Gem::Requirement
|
57
|
+
none: false
|
58
|
+
requirements:
|
59
|
+
- - ! '>='
|
60
|
+
- !ruby/object:Gem::Version
|
61
|
+
version: '0'
|
62
|
+
- !ruby/object:Gem::Dependency
|
65
63
|
name: fakeweb
|
66
|
-
|
64
|
+
requirement: !ruby/object:Gem::Requirement
|
67
65
|
none: false
|
68
|
-
requirements:
|
69
|
-
- -
|
70
|
-
- !ruby/object:Gem::Version
|
71
|
-
|
72
|
-
segments:
|
73
|
-
- 0
|
74
|
-
version: "0"
|
66
|
+
requirements:
|
67
|
+
- - ! '>='
|
68
|
+
- !ruby/object:Gem::Version
|
69
|
+
version: '0'
|
75
70
|
type: :development
|
76
|
-
requirement: *id004
|
77
71
|
prerelease: false
|
78
|
-
|
72
|
+
version_requirements: !ruby/object:Gem::Requirement
|
73
|
+
none: false
|
74
|
+
requirements:
|
75
|
+
- - ! '>='
|
76
|
+
- !ruby/object:Gem::Version
|
77
|
+
version: '0'
|
78
|
+
- !ruby/object:Gem::Dependency
|
79
79
|
name: term-ansicolor
|
80
|
-
|
80
|
+
requirement: !ruby/object:Gem::Requirement
|
81
81
|
none: false
|
82
|
-
requirements:
|
83
|
-
- -
|
84
|
-
- !ruby/object:Gem::Version
|
85
|
-
|
86
|
-
segments:
|
87
|
-
- 0
|
88
|
-
version: "0"
|
82
|
+
requirements:
|
83
|
+
- - ! '>='
|
84
|
+
- !ruby/object:Gem::Version
|
85
|
+
version: '0'
|
89
86
|
type: :development
|
90
|
-
requirement: *id005
|
91
87
|
prerelease: false
|
92
|
-
|
88
|
+
version_requirements: !ruby/object:Gem::Requirement
|
89
|
+
none: false
|
90
|
+
requirements:
|
91
|
+
- - ! '>='
|
92
|
+
- !ruby/object:Gem::Version
|
93
|
+
version: '0'
|
94
|
+
- !ruby/object:Gem::Dependency
|
93
95
|
name: json
|
94
|
-
|
96
|
+
requirement: !ruby/object:Gem::Requirement
|
95
97
|
none: false
|
96
|
-
requirements:
|
97
|
-
- -
|
98
|
-
- !ruby/object:Gem::Version
|
99
|
-
|
100
|
-
segments:
|
101
|
-
- 0
|
102
|
-
version: "0"
|
98
|
+
requirements:
|
99
|
+
- - ! '>='
|
100
|
+
- !ruby/object:Gem::Version
|
101
|
+
version: '0'
|
103
102
|
type: :development
|
104
|
-
requirement: *id006
|
105
103
|
prerelease: false
|
104
|
+
version_requirements: !ruby/object:Gem::Requirement
|
105
|
+
none: false
|
106
|
+
requirements:
|
107
|
+
- - ! '>='
|
108
|
+
- !ruby/object:Gem::Version
|
109
|
+
version: '0'
|
106
110
|
description: Simple beanstalkd client for ruby
|
107
|
-
email:
|
111
|
+
email:
|
108
112
|
- nico.taing@gmail.com
|
109
113
|
executables: []
|
110
|
-
|
111
114
|
extensions: []
|
112
|
-
|
113
115
|
extra_rdoc_files: []
|
114
|
-
|
115
|
-
files:
|
116
|
+
files:
|
116
117
|
- .gitignore
|
117
118
|
- .yardopts
|
118
119
|
- CHANGELOG.md
|
@@ -151,40 +152,31 @@ files:
|
|
151
152
|
- test/test_helper.rb
|
152
153
|
- test/tube_test.rb
|
153
154
|
- test/tubes_test.rb
|
154
|
-
homepage:
|
155
|
+
homepage: ''
|
155
156
|
licenses: []
|
156
|
-
|
157
157
|
post_install_message:
|
158
158
|
rdoc_options: []
|
159
|
-
|
160
|
-
require_paths:
|
159
|
+
require_paths:
|
161
160
|
- lib
|
162
|
-
required_ruby_version: !ruby/object:Gem::Requirement
|
161
|
+
required_ruby_version: !ruby/object:Gem::Requirement
|
163
162
|
none: false
|
164
|
-
requirements:
|
165
|
-
- -
|
166
|
-
- !ruby/object:Gem::Version
|
167
|
-
|
168
|
-
|
169
|
-
- 0
|
170
|
-
version: "0"
|
171
|
-
required_rubygems_version: !ruby/object:Gem::Requirement
|
163
|
+
requirements:
|
164
|
+
- - ! '>='
|
165
|
+
- !ruby/object:Gem::Version
|
166
|
+
version: '0'
|
167
|
+
required_rubygems_version: !ruby/object:Gem::Requirement
|
172
168
|
none: false
|
173
|
-
requirements:
|
174
|
-
- -
|
175
|
-
- !ruby/object:Gem::Version
|
176
|
-
|
177
|
-
segments:
|
178
|
-
- 0
|
179
|
-
version: "0"
|
169
|
+
requirements:
|
170
|
+
- - ! '>='
|
171
|
+
- !ruby/object:Gem::Version
|
172
|
+
version: '0'
|
180
173
|
requirements: []
|
181
|
-
|
182
174
|
rubyforge_project:
|
183
175
|
rubygems_version: 1.8.24
|
184
176
|
signing_key:
|
185
177
|
specification_version: 3
|
186
178
|
summary: Simple beanstalkd client for ruby.
|
187
|
-
test_files:
|
179
|
+
test_files:
|
188
180
|
- test/beaneater_test.rb
|
189
181
|
- test/connection_test.rb
|
190
182
|
- test/errors_test.rb
|