loops 2.0.0

Sign up to get free protection for your applications and to get access to all the features.
Files changed (49) hide show
  1. data/.gitignore +8 -0
  2. data/LICENSE +21 -0
  3. data/README.rdoc +238 -0
  4. data/Rakefile +48 -0
  5. data/VERSION.yml +5 -0
  6. data/bin/loops +16 -0
  7. data/bin/loops-memory-stats +259 -0
  8. data/generators/loops/loops_generator.rb +28 -0
  9. data/generators/loops/templates/app/loops/APP_README +1 -0
  10. data/generators/loops/templates/app/loops/queue_loop.rb +8 -0
  11. data/generators/loops/templates/app/loops/simple_loop.rb +12 -0
  12. data/generators/loops/templates/config/loops.yml +34 -0
  13. data/generators/loops/templates/script/loops +20 -0
  14. data/init.rb +1 -0
  15. data/lib/loops.rb +167 -0
  16. data/lib/loops/autoload.rb +20 -0
  17. data/lib/loops/base.rb +148 -0
  18. data/lib/loops/cli.rb +35 -0
  19. data/lib/loops/cli/commands.rb +124 -0
  20. data/lib/loops/cli/options.rb +273 -0
  21. data/lib/loops/command.rb +36 -0
  22. data/lib/loops/commands/debug_command.rb +8 -0
  23. data/lib/loops/commands/list_command.rb +11 -0
  24. data/lib/loops/commands/start_command.rb +24 -0
  25. data/lib/loops/commands/stats_command.rb +5 -0
  26. data/lib/loops/commands/stop_command.rb +18 -0
  27. data/lib/loops/daemonize.rb +68 -0
  28. data/lib/loops/engine.rb +207 -0
  29. data/lib/loops/errors.rb +6 -0
  30. data/lib/loops/logger.rb +212 -0
  31. data/lib/loops/process_manager.rb +114 -0
  32. data/lib/loops/queue.rb +78 -0
  33. data/lib/loops/version.rb +31 -0
  34. data/lib/loops/worker.rb +101 -0
  35. data/lib/loops/worker_pool.rb +55 -0
  36. data/loops.gemspec +98 -0
  37. data/spec/loop_lock_spec.rb +61 -0
  38. data/spec/loops/base_spec.rb +92 -0
  39. data/spec/loops/cli_spec.rb +156 -0
  40. data/spec/loops_spec.rb +20 -0
  41. data/spec/rails/another_loop.rb +4 -0
  42. data/spec/rails/app/loops/complex_loop.rb +12 -0
  43. data/spec/rails/app/loops/simple_loop.rb +6 -0
  44. data/spec/rails/config.yml +6 -0
  45. data/spec/rails/config/boot.rb +1 -0
  46. data/spec/rails/config/environment.rb +5 -0
  47. data/spec/rails/config/loops.yml +13 -0
  48. data/spec/spec_helper.rb +110 -0
  49. metadata +121 -0
metadata ADDED
@@ -0,0 +1,121 @@
1
+ --- !ruby/object:Gem::Specification
2
+ name: loops
3
+ version: !ruby/object:Gem::Version
4
+ prerelease: false
5
+ segments:
6
+ - 2
7
+ - 0
8
+ - 0
9
+ version: 2.0.0
10
+ platform: ruby
11
+ authors:
12
+ - Alexey Kovyrin
13
+ - Dmytro Shteflyuk
14
+ autorequire:
15
+ bindir: bin
16
+ cert_chain: []
17
+
18
+ date: 2010-03-19 00:00:00 -04:00
19
+ default_executable:
20
+ dependencies: []
21
+
22
+ description: Loops is a small and lightweight framework for Ruby on Rails, Merb and other ruby frameworks created to support simple background loops in your application which are usually used to do some background data processing on your servers (queue workers, batch tasks processors, etc).
23
+ email: alexey@kovyrin.net
24
+ executables:
25
+ - loops
26
+ - loops-memory-stats
27
+ extensions: []
28
+
29
+ extra_rdoc_files:
30
+ - LICENSE
31
+ - README.rdoc
32
+ files:
33
+ - .gitignore
34
+ - LICENSE
35
+ - README.rdoc
36
+ - Rakefile
37
+ - VERSION.yml
38
+ - bin/loops
39
+ - bin/loops-memory-stats
40
+ - generators/loops/loops_generator.rb
41
+ - generators/loops/templates/app/loops/APP_README
42
+ - generators/loops/templates/app/loops/queue_loop.rb
43
+ - generators/loops/templates/app/loops/simple_loop.rb
44
+ - generators/loops/templates/config/loops.yml
45
+ - generators/loops/templates/script/loops
46
+ - init.rb
47
+ - lib/loops.rb
48
+ - lib/loops/autoload.rb
49
+ - lib/loops/base.rb
50
+ - lib/loops/cli.rb
51
+ - lib/loops/cli/commands.rb
52
+ - lib/loops/cli/options.rb
53
+ - lib/loops/command.rb
54
+ - lib/loops/commands/debug_command.rb
55
+ - lib/loops/commands/list_command.rb
56
+ - lib/loops/commands/start_command.rb
57
+ - lib/loops/commands/stats_command.rb
58
+ - lib/loops/commands/stop_command.rb
59
+ - lib/loops/daemonize.rb
60
+ - lib/loops/engine.rb
61
+ - lib/loops/errors.rb
62
+ - lib/loops/logger.rb
63
+ - lib/loops/process_manager.rb
64
+ - lib/loops/queue.rb
65
+ - lib/loops/version.rb
66
+ - lib/loops/worker.rb
67
+ - lib/loops/worker_pool.rb
68
+ - loops.gemspec
69
+ - spec/loop_lock_spec.rb
70
+ - spec/loops/base_spec.rb
71
+ - spec/loops/cli_spec.rb
72
+ - spec/loops_spec.rb
73
+ - spec/rails/another_loop.rb
74
+ - spec/rails/app/loops/complex_loop.rb
75
+ - spec/rails/app/loops/simple_loop.rb
76
+ - spec/rails/config.yml
77
+ - spec/rails/config/boot.rb
78
+ - spec/rails/config/environment.rb
79
+ - spec/rails/config/loops.yml
80
+ - spec/spec_helper.rb
81
+ has_rdoc: true
82
+ homepage: http://github.com/kovyrin/loops
83
+ licenses: []
84
+
85
+ post_install_message:
86
+ rdoc_options:
87
+ - --charset=UTF-8
88
+ require_paths:
89
+ - lib
90
+ required_ruby_version: !ruby/object:Gem::Requirement
91
+ requirements:
92
+ - - ">="
93
+ - !ruby/object:Gem::Version
94
+ segments:
95
+ - 0
96
+ version: "0"
97
+ required_rubygems_version: !ruby/object:Gem::Requirement
98
+ requirements:
99
+ - - ">="
100
+ - !ruby/object:Gem::Version
101
+ segments:
102
+ - 0
103
+ version: "0"
104
+ requirements: []
105
+
106
+ rubyforge_project:
107
+ rubygems_version: 1.3.6
108
+ signing_key:
109
+ specification_version: 3
110
+ summary: Simple background loops framework for ruby
111
+ test_files:
112
+ - spec/loop_lock_spec.rb
113
+ - spec/loops/base_spec.rb
114
+ - spec/loops/cli_spec.rb
115
+ - spec/loops_spec.rb
116
+ - spec/rails/another_loop.rb
117
+ - spec/rails/app/loops/complex_loop.rb
118
+ - spec/rails/app/loops/simple_loop.rb
119
+ - spec/rails/config/boot.rb
120
+ - spec/rails/config/environment.rb
121
+ - spec/spec_helper.rb