Skip to content

Commit

Permalink
Give the status check events a bus id
Browse files Browse the repository at this point in the history
  • Loading branch information
coolo committed Nov 14, 2018
1 parent 6bf4ab9 commit 0b6b357
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 4 deletions.
4 changes: 0 additions & 4 deletions src/api/app/models/event/status_check.rb
Original file line number Diff line number Diff line change
Expand Up @@ -2,9 +2,5 @@ module Event
class StatusCheck < Base
self.abstract_class = true
payload_keys :who, :name, :short_description, :state, :url

def originator
payload_address('who')
end
end
end
4 changes: 4 additions & 0 deletions src/api/app/models/event/status_check_for_published.rb
Original file line number Diff line number Diff line change
Expand Up @@ -2,5 +2,9 @@ module Event
class StatusCheckForPublished < StatusCheck
self.description = 'Status Check for Published Repository Created'
payload_keys :project, :repository, :uuid

def self.message_bus_routing_key
'published.status_report'
end
end
end
4 changes: 4 additions & 0 deletions src/api/app/models/event/status_check_for_request.rb
Original file line number Diff line number Diff line change
@@ -1,5 +1,9 @@
module Event
class StatusCheckForRequest < StatusCheck
payload_keys :number

def self.message_bus_routing_key
'request.status_report'
end
end
end

0 comments on commit 0b6b357

Please sign in to comment.