in lib/aws_lambda_ric/lambda_server.rb [42:58]
def send_response(request_id:, response_object:, content_type: 'application/json')
response_uri = URI(@server_address + "/runtime/invocation/#{request_id}/response")
begin
if content_type == 'application/unknown'
response_object = response_object.read
end
Net::HTTP.post(
response_uri,
response_object,
{ 'Content-Type' => content_type, 'User-Agent' => @user_agent }
)
rescue StandardError => e
raise LambdaErrors::LambdaRuntimeError.new(e)
end
end