Class: CanvasSync::LiveEvents::BaseHandler

Inherits:
Job
  • Object
show all
Defined in:
lib/canvas_sync/live_events/base_handler.rb

Overview

Deprecated

Instance Attribute Summary collapse

Attributes inherited from Job

#job_log

Instance Method Summary collapse

Methods inherited from Job

#create_job_log, #report_checker_wait_time, #update_or_create_model

Instance Attribute Details

#metadataObject

Returns the value of attribute metadata.



8
9
10
# File 'lib/canvas_sync/live_events/base_handler.rb', line 8

def 
  
end

#payloadObject

Returns the value of attribute payload.



7
8
9
# File 'lib/canvas_sync/live_events/base_handler.rb', line 7

def payload
  @payload
end

#raw_payloadObject

Returns the value of attribute raw_payload.



6
7
8
# File 'lib/canvas_sync/live_events/base_handler.rb', line 6

def raw_payload
  @raw_payload
end

Instance Method Details

#perform(event_payload) ⇒ Object



10
11
12
13
14
15
# File 'lib/canvas_sync/live_events/base_handler.rb', line 10

def perform(event_payload)
  @raw_payload = event_payload
   = HashWithIndifferentAccess.new(event_payload["metadata"])
  @payload = HashWithIndifferentAccess.new(event_payload["body"])
  process_with_retry
end