euston 1.2.1 → 1.2.2

Sign up to get free protection for your applications and to get access to all the features.
data/euston.gemspec CHANGED
@@ -1,7 +1,7 @@
1
1
  Gem::Specification.new do |s|
2
2
  s.name = 'euston'
3
- s.version = '1.2.1'
4
- s.date = '2011-10-13'
3
+ s.version = '1.2.2'
4
+ s.date = '2011-10-18'
5
5
  s.platform = RUBY_PLATFORM.to_s == 'java' ? 'java' : Gem::Platform::RUBY
6
6
  s.authors = ['Lee Henson', 'Guy Boertje']
7
7
  s.email = ['lee.m.henson@gmail.com', 'guyboertje@gmail.com']
@@ -42,8 +42,8 @@ Gem::Specification.new do |s|
42
42
  s.test_files = `git ls-files -- {test,spec,features}/*`.split("\n")
43
43
  s.executables = `git ls-files -- bin/*`.split("\n").map{ |f| File.basename(f) }
44
44
 
45
- s.add_dependency 'activemodel', '~> 3.0.9'
46
- s.add_dependency 'activesupport', '~> 3.0.9'
45
+ s.add_dependency 'activemodel', '>= 3.0.10'
46
+ s.add_dependency 'activesupport', '>= 3.0.10'
47
47
 
48
48
  s.add_development_dependency 'fuubar', '~> 0.0.0'
49
49
  s.add_development_dependency 'rspec', '~> 2.6.0'
@@ -71,6 +71,9 @@ module Euston
71
71
  return unless entry
72
72
  aggregate = load_aggregate(entry, *args)
73
73
  end
74
+
75
+ raise Euston::Errors::AggregateNotFoundError if aggregate.nil?
76
+
74
77
  aggregate.log = logger
75
78
  aggregate.consume_command( headers, command )
76
79
  end
@@ -18,10 +18,18 @@ module Euston
18
18
  @headers[:id]
19
19
  end
20
20
 
21
+ def id= value
22
+ @headers[:id] = value
23
+ end
24
+
21
25
  def read_attribute_for_validation key
22
26
  @body[key]
23
27
  end
24
28
 
29
+ def type
30
+ @headers[:type]
31
+ end
32
+
25
33
  def to_hash
26
34
  { :headers => headers, :body => @body }
27
35
  end
data/lib/euston/errors.rb CHANGED
@@ -1,5 +1,6 @@
1
1
  module Euston
2
2
  module Errors
3
3
  class InvalidCommandError < StandardError; end
4
+ class AggregateNotFoundError < StandardError; end
4
5
  end
5
6
  end
@@ -1,3 +1,3 @@
1
1
  module Euston
2
- VERSION = "1.2.1"
2
+ VERSION = "1.2.2"
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: euston
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.2.1
4
+ version: 1.2.2
5
5
  prerelease:
6
6
  platform: ruby
7
7
  authors:
@@ -10,33 +10,33 @@ authors:
10
10
  autorequire:
11
11
  bindir: bin
12
12
  cert_chain: []
13
- date: 2011-10-13 00:00:00.000000000 Z
13
+ date: 2011-10-18 00:00:00.000000000 Z
14
14
  dependencies:
15
15
  - !ruby/object:Gem::Dependency
16
16
  name: activemodel
17
- requirement: &81777330 !ruby/object:Gem::Requirement
17
+ requirement: &75071220 !ruby/object:Gem::Requirement
18
18
  none: false
19
19
  requirements:
20
- - - ~>
20
+ - - ! '>='
21
21
  - !ruby/object:Gem::Version
22
- version: 3.0.9
22
+ version: 3.0.10
23
23
  type: :runtime
24
24
  prerelease: false
25
- version_requirements: *81777330
25
+ version_requirements: *75071220
26
26
  - !ruby/object:Gem::Dependency
27
27
  name: activesupport
28
- requirement: &81776220 !ruby/object:Gem::Requirement
28
+ requirement: &75070980 !ruby/object:Gem::Requirement
29
29
  none: false
30
30
  requirements:
31
- - - ~>
31
+ - - ! '>='
32
32
  - !ruby/object:Gem::Version
33
- version: 3.0.9
33
+ version: 3.0.10
34
34
  type: :runtime
35
35
  prerelease: false
36
- version_requirements: *81776220
36
+ version_requirements: *75070980
37
37
  - !ruby/object:Gem::Dependency
38
38
  name: fuubar
39
- requirement: &81775260 !ruby/object:Gem::Requirement
39
+ requirement: &75070750 !ruby/object:Gem::Requirement
40
40
  none: false
41
41
  requirements:
42
42
  - - ~>
@@ -44,10 +44,10 @@ dependencies:
44
44
  version: 0.0.0
45
45
  type: :development
46
46
  prerelease: false
47
- version_requirements: *81775260
47
+ version_requirements: *75070750
48
48
  - !ruby/object:Gem::Dependency
49
49
  name: rspec
50
- requirement: &81774780 !ruby/object:Gem::Requirement
50
+ requirement: &75070520 !ruby/object:Gem::Requirement
51
51
  none: false
52
52
  requirements:
53
53
  - - ~>
@@ -55,10 +55,10 @@ dependencies:
55
55
  version: 2.6.0
56
56
  type: :development
57
57
  prerelease: false
58
- version_requirements: *81774780
58
+ version_requirements: *75070520
59
59
  - !ruby/object:Gem::Dependency
60
60
  name: uuid
61
- requirement: &81774320 !ruby/object:Gem::Requirement
61
+ requirement: &75070290 !ruby/object:Gem::Requirement
62
62
  none: false
63
63
  requirements:
64
64
  - - ~>
@@ -66,7 +66,7 @@ dependencies:
66
66
  version: 2.3.0
67
67
  type: :development
68
68
  prerelease: false
69
- version_requirements: *81774320
69
+ version_requirements: *75070290
70
70
  description: ''
71
71
  email:
72
72
  - lee.m.henson@gmail.com