eventq_base 0.1.7 → 1.0.0

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: eefbf7df4ff3259efe80a510ffe2a31b6349c81d
4
- data.tar.gz: 7f730d84057a574205d8864484c6c4617f00d684
3
+ metadata.gz: cacecc1f7bf0edd18550582340b11ab229b06a88
4
+ data.tar.gz: d7c62b57ec15a60cb185507c17dd7d8d4507fc68
5
5
  SHA512:
6
- metadata.gz: 3dd2effd983f32758c5ca8c8884b827fe6d650169f7425494ed57744e3fabdf371e692065026be752a237c830e5f8fadbb46a3825b6d7c0aba9ebb1b4be27993
7
- data.tar.gz: 651d52bea02e8a1d368e225ab9ef2f6fd5147cc27e606342da1dd9a8dd266daa3aad105d6358eef8c135299d9e716d3297e79cb26278f3369bc6c6305a5849b4
6
+ metadata.gz: 60ba2868d29385675776bd8a99aabc3f67fee287a6d487054a99ad2a2a9c56478b8ad3e0bdeab3da7044ecbc6bca9c86ae630518ac03e8704312fd762fc491e5
7
+ data.tar.gz: 6425de9a3c46d5851d897056fb10787e22a180752e86301ac3f36042c5d0a899d7e8d91f8a5fb4b80abee591975003526e619aa204dd9e304a9590ad889e2f1a
data/lib/eventq_base.rb CHANGED
@@ -1,9 +1,10 @@
1
- require_relative '../lib/eventq_base/version'
2
- require_relative '../lib/eventq_base/queue'
3
- require_relative '../lib/eventq_base/exchange'
4
- require_relative '../lib/eventq_base/queue_message'
5
- require_relative '../lib/eventq_base/queue_worker'
6
- require_relative '../lib/eventq_base/event_raised_exchange'
7
- require_relative '../lib/eventq_base/event_raised_queue'
8
- require_relative '../lib/eventq_base/subscription_manager'
9
- require_relative '../lib/eventq_base/eventq_client'
1
+ require_relative 'eventq_base/version'
2
+ require_relative 'eventq_base/queue'
3
+ require_relative 'eventq_base/exchange'
4
+ require_relative 'eventq_base/queue_message'
5
+ require_relative 'eventq_base/message_args'
6
+ require_relative 'eventq_base/queue_worker_contract'
7
+ require_relative 'eventq_base/event_raised_exchange'
8
+ require_relative 'eventq_base/event_raised_queue'
9
+ require_relative 'eventq_base/subscription_manager_contract'
10
+ require_relative 'eventq_base/eventq_client_contract'
@@ -1,5 +1,7 @@
1
- class EventRaisedExchange < Exchange
2
- def initialize
3
- @name = 'eventq.eventraised.ex'
1
+ module EventQ
2
+ class EventRaisedExchange < Exchange
3
+ def initialize
4
+ @name = 'eventq.eventraised.ex'
5
+ end
4
6
  end
5
- end
7
+ end
@@ -1,5 +1,7 @@
1
- class EventRaisedQueue < Queue
2
- def initialize
3
- @name = 'eventq.eventraised'
1
+ module EventQ
2
+ class EventRaisedQueue < Queue
3
+ def initialize
4
+ @name = 'eventq.eventraised'
5
+ end
4
6
  end
5
- end
7
+ end
@@ -0,0 +1,9 @@
1
+ module EventQ
2
+ class EventQClientContract
3
+
4
+ def raise(event_type, event)
5
+
6
+ end
7
+
8
+ end
9
+ end
@@ -1,3 +1,5 @@
1
- class Exchange
2
- attr_accessor :name
3
- end
1
+ module EventQ
2
+ class Exchange
3
+ attr_accessor :name
4
+ end
5
+ end
@@ -0,0 +1,12 @@
1
+ module EventQ
2
+ class MessageArgs
3
+ attr_reader :type
4
+ attr_reader :retry_attempts
5
+ attr_accessor :abort
6
+
7
+ def initialize(type, retry_attempts)
8
+ @type = type
9
+ @retry_attempts = retry_attempts
10
+ end
11
+ end
12
+ end
@@ -1,14 +1,16 @@
1
- class Queue
2
- attr_accessor :name
3
- attr_accessor :allow_retry
4
- attr_accessor :retry_delay
5
- attr_accessor :max_retry_attempts
1
+ module EventQ
2
+ class Queue
3
+ attr_accessor :name
4
+ attr_accessor :allow_retry
5
+ attr_accessor :retry_delay
6
+ attr_accessor :max_retry_attempts
6
7
 
7
- def initialize
8
- @allow_retry = false
9
- #default retry delay is 30 seconds
10
- @retry_delay = 30000
11
- #default max retry attempts is 5
12
- @max_retry_attempts = 5
8
+ def initialize
9
+ @allow_retry = false
10
+ #default retry delay is 30 seconds
11
+ @retry_delay = 30000
12
+ #default max retry attempts is 5
13
+ @max_retry_attempts = 5
14
+ end
13
15
  end
14
- end
16
+ end
@@ -1,11 +1,13 @@
1
- class QueueMessage
2
- attr_accessor :retry_attempts
3
- attr_accessor :type
4
- attr_accessor :content
5
- attr_accessor :created
1
+ module EventQ
2
+ class QueueMessage
3
+ attr_accessor :retry_attempts
4
+ attr_accessor :type
5
+ attr_accessor :content
6
+ attr_accessor :created
6
7
 
7
- def initialize
8
- @retry_attempts = 0
9
- @created = DateTime.now
8
+ def initialize
9
+ @retry_attempts = 0
10
+ @created = DateTime.now
11
+ end
10
12
  end
11
- end
13
+ end
@@ -0,0 +1,23 @@
1
+ module EventQ
2
+ # Contract class for queue workers
3
+ class QueueWorkerContract
4
+
5
+ def start(queue, options = {}, &block)
6
+
7
+ end
8
+
9
+ def stop
10
+
11
+ end
12
+
13
+ def on_retry_exceeded(&block)
14
+
15
+ end
16
+
17
+ def running?
18
+
19
+ end
20
+
21
+ end
22
+ end
23
+
@@ -0,0 +1,13 @@
1
+ module EventQ
2
+ class SubscriptionManagerContract
3
+
4
+ def subscribe(event_type, queue)
5
+
6
+ end
7
+
8
+ def unsubscribe(queue)
9
+
10
+ end
11
+
12
+ end
13
+ end
@@ -1,3 +1,3 @@
1
1
  module EventqBase
2
- VERSION = "0.1.7"
2
+ VERSION = "1.0.0"
3
3
  end
metadata CHANGED
@@ -1,41 +1,41 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: eventq_base
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.7
4
+ version: 1.0.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - vaughanbrittonsage
8
8
  autorequire:
9
9
  bindir: exe
10
10
  cert_chain: []
11
- date: 2016-04-14 00:00:00.000000000 Z
11
+ date: 2016-06-26 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bundler
15
15
  requirement: !ruby/object:Gem::Requirement
16
16
  requirements:
17
- - - "~>"
17
+ - - ~>
18
18
  - !ruby/object:Gem::Version
19
19
  version: '1.11'
20
20
  type: :development
21
21
  prerelease: false
22
22
  version_requirements: !ruby/object:Gem::Requirement
23
23
  requirements:
24
- - - "~>"
24
+ - - ~>
25
25
  - !ruby/object:Gem::Version
26
26
  version: '1.11'
27
27
  - !ruby/object:Gem::Dependency
28
28
  name: rake
29
29
  requirement: !ruby/object:Gem::Requirement
30
30
  requirements:
31
- - - "~>"
31
+ - - ~>
32
32
  - !ruby/object:Gem::Version
33
33
  version: '10.0'
34
34
  type: :development
35
35
  prerelease: false
36
36
  version_requirements: !ruby/object:Gem::Requirement
37
37
  requirements:
38
- - - "~>"
38
+ - - ~>
39
39
  - !ruby/object:Gem::Version
40
40
  version: '10.0'
41
41
  description: This gem contains the base classes and contracts required by any eventq
@@ -48,16 +48,17 @@ extra_rdoc_files: []
48
48
  files:
49
49
  - bin/console
50
50
  - bin/setup
51
- - lib/eventq_base.rb
52
51
  - lib/eventq_base/event_raised_exchange.rb
53
52
  - lib/eventq_base/event_raised_queue.rb
54
- - lib/eventq_base/eventq_client.rb
53
+ - lib/eventq_base/eventq_client_contract.rb
55
54
  - lib/eventq_base/exchange.rb
55
+ - lib/eventq_base/message_args.rb
56
56
  - lib/eventq_base/queue.rb
57
57
  - lib/eventq_base/queue_message.rb
58
- - lib/eventq_base/queue_worker.rb
59
- - lib/eventq_base/subscription_manager.rb
58
+ - lib/eventq_base/queue_worker_contract.rb
59
+ - lib/eventq_base/subscription_manager_contract.rb
60
60
  - lib/eventq_base/version.rb
61
+ - lib/eventq_base.rb
61
62
  homepage: https://github.com/vaughanbrittonsage/eventq
62
63
  licenses:
63
64
  - MIT
@@ -68,19 +69,18 @@ require_paths:
68
69
  - lib
69
70
  required_ruby_version: !ruby/object:Gem::Requirement
70
71
  requirements:
71
- - - ">="
72
+ - - '>='
72
73
  - !ruby/object:Gem::Version
73
74
  version: '0'
74
75
  required_rubygems_version: !ruby/object:Gem::Requirement
75
76
  requirements:
76
- - - ">="
77
+ - - '>='
77
78
  - !ruby/object:Gem::Version
78
79
  version: '0'
79
80
  requirements: []
80
81
  rubyforge_project:
81
- rubygems_version: 2.5.1
82
+ rubygems_version: 2.0.14.1
82
83
  signing_key:
83
84
  specification_version: 4
84
85
  summary: This gem contains the base classes and contracts required by any eventq implementations.
85
86
  test_files: []
86
- has_rdoc:
@@ -1,7 +0,0 @@
1
- class EventQClient
2
-
3
- def raise(event_type, event)
4
-
5
- end
6
-
7
- end
@@ -1,20 +0,0 @@
1
- # Contract class for queue workers
2
- class QueueWorker
3
-
4
- def start(queue, options = {}, &block)
5
-
6
- end
7
-
8
- def stop
9
-
10
- end
11
-
12
- def on_retry_exceeded(&block)
13
-
14
- end
15
-
16
- def running?
17
-
18
- end
19
-
20
- end
@@ -1,11 +0,0 @@
1
- class SubscriptionManager
2
-
3
- def subscribe(event_type, queue)
4
-
5
- end
6
-
7
- def unsubscribe(queue)
8
-
9
- end
10
-
11
- end