marples 1.0.4 → 1.0.5

Sign up to get free protection for your applications and to get access to all the features.
data/.gitignore CHANGED
@@ -2,3 +2,5 @@
2
2
  .bundle
3
3
  Gemfile.lock
4
4
  pkg/*
5
+ *iml
6
+ .rakeTasks
@@ -33,18 +33,20 @@ module Marples
33
33
  end
34
34
 
35
35
  def when application, object_type, action
36
- logger.debug "Listening for #{application} notifiying us of #{action} #{object_type}"
36
+ logger.info "Listening for #{application} notifiying us of #{action} #{object_type}"
37
37
  destination = destination_for application, object_type, action
38
38
  logger.debug "Underlying destination is #{destination}"
39
39
  transport.subscribe destination do |message|
40
- logger.debug "Received message #{message.headers['message-id']} from #{destination}"
41
- logger.debug "Message body: #{message.body}"
40
+ logger.info "Received message #{message.headers['message-id']} from #{destination}"
41
+ #logger.debug "Message body: #{message.body}"
42
42
  hash = Hash.from_xml message.body
43
- logger.debug "Constructed hash: #{hash.inspect}"
43
+ #logger.debug "Constructed hash: #{hash.inspect}"
44
44
  attributes = hash.values[0]
45
- logger.debug "Yielding hash: #{attributes.inspect}"
45
+ #logger.debug "Yielding hash: #{attributes.inspect}"
46
+ logger.info("About to yield")
47
+
46
48
  yield attributes
47
- logger.debug "Finished processing message #{message.headers['message-id']}"
49
+ logger.info "Finished processing message #{message.headers['message-id']}"
48
50
  end
49
51
  end
50
52
 
@@ -56,12 +58,11 @@ module Marples
56
58
  raise "Provide Marples::Client with a client_name to publish messages"
57
59
  end
58
60
  destination = destination_for client_name, object_type, action
59
- logger.debug "Using transport #{transport}"
61
+ #logger.debug "Using transport #{transport}"
60
62
  logger.debug "Sending XML to #{destination}"
61
63
  payload = generate_payload_for object
62
- logger.debug "XML: #{payload}"
64
+ #logger.debug "XML: #{payload}"
63
65
  transport.publish destination, payload
64
- logger.debug "Message sent"
65
66
  end
66
67
  private :publish
67
68
 
@@ -1,3 +1,3 @@
1
1
  module Marples
2
- VERSION = "1.0.4"
2
+ VERSION = "1.0.5"
3
3
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: marples
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.0.4
4
+ version: 1.0.5
5
5
  prerelease:
6
6
  platform: ruby
7
7
  authors:
@@ -10,11 +10,11 @@ authors:
10
10
  autorequire:
11
11
  bindir: bin
12
12
  cert_chain: []
13
- date: 2011-12-02 00:00:00.000000000Z
13
+ date: 2011-12-20 00:00:00.000000000Z
14
14
  dependencies:
15
15
  - !ruby/object:Gem::Dependency
16
16
  name: null_logger
17
- requirement: &70125815622680 !ruby/object:Gem::Requirement
17
+ requirement: &70142564751640 !ruby/object:Gem::Requirement
18
18
  none: false
19
19
  requirements:
20
20
  - - ! '>='
@@ -22,10 +22,10 @@ dependencies:
22
22
  version: '0'
23
23
  type: :runtime
24
24
  prerelease: false
25
- version_requirements: *70125815622680
25
+ version_requirements: *70142564751640
26
26
  - !ruby/object:Gem::Dependency
27
27
  name: activesupport
28
- requirement: &70125815621380 !ruby/object:Gem::Requirement
28
+ requirement: &70142564750780 !ruby/object:Gem::Requirement
29
29
  none: false
30
30
  requirements:
31
31
  - - ! '>='
@@ -33,10 +33,10 @@ dependencies:
33
33
  version: '0'
34
34
  type: :runtime
35
35
  prerelease: false
36
- version_requirements: *70125815621380
36
+ version_requirements: *70142564750780
37
37
  - !ruby/object:Gem::Dependency
38
38
  name: i18n
39
- requirement: &70125815620380 !ruby/object:Gem::Requirement
39
+ requirement: &70142564750000 !ruby/object:Gem::Requirement
40
40
  none: false
41
41
  requirements:
42
42
  - - ! '>='
@@ -44,10 +44,10 @@ dependencies:
44
44
  version: '0'
45
45
  type: :runtime
46
46
  prerelease: false
47
- version_requirements: *70125815620380
47
+ version_requirements: *70142564750000
48
48
  - !ruby/object:Gem::Dependency
49
49
  name: rake
50
- requirement: &70125815619300 !ruby/object:Gem::Requirement
50
+ requirement: &70142564748880 !ruby/object:Gem::Requirement
51
51
  none: false
52
52
  requirements:
53
53
  - - ! '>='
@@ -55,10 +55,10 @@ dependencies:
55
55
  version: '0'
56
56
  type: :development
57
57
  prerelease: false
58
- version_requirements: *70125815619300
58
+ version_requirements: *70142564748880
59
59
  - !ruby/object:Gem::Dependency
60
60
  name: activerecord
61
- requirement: &70125815618520 !ruby/object:Gem::Requirement
61
+ requirement: &70142564741580 !ruby/object:Gem::Requirement
62
62
  none: false
63
63
  requirements:
64
64
  - - ! '>='
@@ -66,10 +66,10 @@ dependencies:
66
66
  version: '0'
67
67
  type: :development
68
68
  prerelease: false
69
- version_requirements: *70125815618520
69
+ version_requirements: *70142564741580
70
70
  - !ruby/object:Gem::Dependency
71
71
  name: activerecord-nulldb-adapter
72
- requirement: &70125815617880 !ruby/object:Gem::Requirement
72
+ requirement: &70142564740720 !ruby/object:Gem::Requirement
73
73
  none: false
74
74
  requirements:
75
75
  - - ! '>='
@@ -77,7 +77,7 @@ dependencies:
77
77
  version: '0'
78
78
  type: :development
79
79
  prerelease: false
80
- version_requirements: *70125815617880
80
+ version_requirements: *70142564740720
81
81
  description: Message destination arbiter
82
82
  email:
83
83
  - craig@barkingiguana.com