Module: Digdag::Client::Session

Included in:
Digdag::Client
Defined in:
lib/digdag_client/client/session.rb

Instance Method Summary collapse

Instance Method Details

#get_session(id) ⇒ Object



12
13
14
# File 'lib/digdag_client/client/session.rb', line 12

def get_session(id)
  get("sessions/#{id}")
end

#get_session_attempts(id, last_id) ⇒ Object



16
17
18
19
20
21
22
# File 'lib/digdag_client/client/session.rb', line 16

def get_session_attempts(id, last_id)
  options = {}
  if last_id
    options[:last_id] = last_id
  end
  get("sessions/#{id}/attempts", options)
end

#get_sessions(last_id = nil) ⇒ Object



4
5
6
7
8
9
10
# File 'lib/digdag_client/client/session.rb', line 4

def get_sessions(last_id = nil)
  options = {}
  if last_id
    options[:last_id] = last_id
  end
  get('sessions', options)['sessions']
end