aws_lambda_ric 3.2.0 → 3.2.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: aebcc51bb69e0146bf4fe0c2361e55967d773569e9a75b5edfee8e59926dca71
4
- data.tar.gz: ee94ca25bd713f8dca2a08a876b6b8e9512a02953ade9d14cfa79c38b3eaee4b
3
+ metadata.gz: a32b2e9a2c95af59f7e0de80897fa13b66eb4ebfcec16724442838dac7da1252
4
+ data.tar.gz: 8f4705a87e4cd1965367be9bf20f42e23bdb3f93fd4bcc51678b0a98f91bdf83
5
5
  SHA512:
6
- metadata.gz: 29f94ab802c88332d74581db2303c2b64b9864a3a5a2abdef0bdc7e1c4df810ed4248790d371d0dd55d934765928972a27a0b11976c66c86f468465b2bf62bb5
7
- data.tar.gz: 82dada5e5cab9d9e85e0d0d44f65e8ccfbada3a633a491ccf25fb32b8ed0e812355be7c8fe6fa973c38e6cd0e6efeca81bf9b4a914f9a7d42b453fac50c35a57
6
+ metadata.gz: 2bb5a3df6adcb041e44ec97a9e9c7c7298d563d470ded5bb315a726f91bc3ede4ad5a12edee8394d1a9b8f2d957e7358009f591f4f9768377d9ea0171decfeff
7
+ data.tar.gz: 43ff3130747ab3851c0a8d322098151de3d2f9452ff379fb0b506fe324786b69a42627cf47bfc6f8fdef377dd0962d776b11d6ab4d4f8a2d22d6a3678d44cf3e
@@ -20,7 +20,7 @@ class RapidClient
20
20
  def next_invocation
21
21
  next_invocation_uri = URI(@server_address + '/runtime/invocation/next')
22
22
  begin
23
- http = Net::HTTP.new(next_invocation_uri.host, next_invocation_uri.port)
23
+ http = build_client(next_invocation_uri)
24
24
  http.read_timeout = LONG_TIMEOUT_MS
25
25
  resp = http.start do |connection|
26
26
  connection.get(next_invocation_uri.path, { 'User-Agent' => @user_agent })
@@ -49,7 +49,7 @@ class RapidClient
49
49
  if content_type == 'application/unknown'
50
50
  response_object = response_object.read
51
51
  end
52
- Net::HTTP.post(
52
+ post(
53
53
  response_uri,
54
54
  response_object,
55
55
  { 'Content-Type' => content_type, 'User-Agent' => @user_agent }
@@ -64,7 +64,7 @@ class RapidClient
64
64
  begin
65
65
  headers = { 'Lambda-Runtime-Function-Error-Type' => error.runtime_error_type, 'User-Agent' => @user_agent }
66
66
  headers['Lambda-Runtime-Function-XRay-Error-Cause'] = xray_cause if xray_cause.bytesize < MAX_HEADER_SIZE_BYTES
67
- Net::HTTP.post(
67
+ post(
68
68
  response_uri,
69
69
  error_object.to_json,
70
70
  headers
@@ -77,7 +77,7 @@ class RapidClient
77
77
  def send_init_error(error_object:, error:)
78
78
  uri = URI("#{@server_address}/runtime/init/error")
79
79
  begin
80
- Net::HTTP.post(
80
+ post(
81
81
  uri,
82
82
  error_object.to_json,
83
83
  { 'Lambda-Runtime-Function-Error-Type' => error.runtime_error_type, 'User-Agent' => @user_agent }
@@ -86,4 +86,19 @@ class RapidClient
86
86
  raise LambdaErrors::LambdaRuntimeInitError.new(e)
87
87
  end
88
88
  end
89
+
90
+ private
91
+
92
+ # The Runtime API endpoint must never be proxied. The nil proxy argument
93
+ # disables Net::HTTP's default :ENV proxy resolution, which would otherwise
94
+ # route calls through a customer-configured PROXY.
95
+ def build_client(uri)
96
+ Net::HTTP.new(uri.host, uri.port, nil)
97
+ end
98
+
99
+ def post(uri, body, headers)
100
+ build_client(uri).start do |connection|
101
+ connection.post(uri.path, body, headers)
102
+ end
103
+ end
89
104
  end
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module AwsLambdaRIC
4
- VERSION = '3.2.0'
4
+ VERSION = '3.2.1'
5
5
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: aws_lambda_ric
3
3
  version: !ruby/object:Gem::Version
4
- version: 3.2.0
4
+ version: 3.2.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - AWS Lambda
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2026-04-15 00:00:00.000000000 Z
11
+ date: 2026-10-01 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: logger