Module: BatchRequestApi::BatchParallel
Instance Method Summary collapse
Methods included from BatchUtil
#build_response, #get_payload, #setup_env
Instance Method Details
#batch_parallel(env) ⇒ Object
7 8 9 10 11 12 13 14 |
# File 'lib/batch_request_api/batch_parallel.rb', line 7 def batch_parallel(env) requests = get_payload(env) first_request = requests.first # Post and Delete methods do not need any processing set_id_on_record_for_patch(requests) if first_request['method'] == 'PATCH' responses = process_parallel_request(env, first_request, requests) build_response(responses) end |