patient_http 1.6.0 → 1.7.0

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.
Files changed (50) hide show
  1. checksums.yaml +4 -4
  2. data/ARCHITECTURE.md +8 -7
  3. data/CHANGELOG.md +39 -0
  4. data/README.md +540 -514
  5. data/VERSION +1 -1
  6. data/lib/patient_http/callback_args.rb +53 -48
  7. data/lib/patient_http/callback_validator.rb +11 -7
  8. data/lib/patient_http/class_helper.rb +6 -7
  9. data/lib/patient_http/client.rb +28 -22
  10. data/lib/patient_http/client_pool.rb +134 -39
  11. data/lib/patient_http/completion_executor.rb +20 -20
  12. data/lib/patient_http/configuration.rb +367 -119
  13. data/lib/patient_http/connection_endpoint.rb +150 -0
  14. data/lib/patient_http/encryptor.rb +28 -18
  15. data/lib/patient_http/error.rb +24 -18
  16. data/lib/patient_http/external_storage.rb +42 -38
  17. data/lib/patient_http/http_error.rb +30 -26
  18. data/lib/patient_http/http_headers.rb +57 -26
  19. data/lib/patient_http/immediate_retries.rb +98 -0
  20. data/lib/patient_http/inline_task_handler.rb +15 -10
  21. data/lib/patient_http/lifecycle_manager.rb +39 -40
  22. data/lib/patient_http/outgoing_request.rb +25 -23
  23. data/lib/patient_http/payload.rb +28 -26
  24. data/lib/patient_http/payload_store/active_record_store.rb +31 -34
  25. data/lib/patient_http/payload_store/base.rb +42 -46
  26. data/lib/patient_http/payload_store/file_store.rb +22 -26
  27. data/lib/patient_http/payload_store/redis_store.rb +28 -34
  28. data/lib/patient_http/payload_store/s3_store.rb +25 -28
  29. data/lib/patient_http/payload_store.rb +2 -0
  30. data/lib/patient_http/processor.rb +111 -79
  31. data/lib/patient_http/processor_observer.rb +65 -59
  32. data/lib/patient_http/rails/engine.rb +13 -8
  33. data/lib/patient_http/redirect_error.rb +50 -41
  34. data/lib/patient_http/redirect_helper.rb +38 -38
  35. data/lib/patient_http/request.rb +70 -46
  36. data/lib/patient_http/request_error.rb +47 -42
  37. data/lib/patient_http/request_helper.rb +142 -119
  38. data/lib/patient_http/request_preparer.rb +13 -10
  39. data/lib/patient_http/request_task.rb +113 -84
  40. data/lib/patient_http/request_template.rb +87 -64
  41. data/lib/patient_http/response.rb +58 -52
  42. data/lib/patient_http/response_reader.rb +66 -65
  43. data/lib/patient_http/secret_manager.rb +34 -30
  44. data/lib/patient_http/secret_reference.rb +33 -26
  45. data/lib/patient_http/synchronous_executor.rb +67 -95
  46. data/lib/patient_http/task_handler.rb +23 -19
  47. data/lib/patient_http/time_helper.rb +8 -8
  48. data/lib/patient_http.rb +311 -186
  49. data/patient_http.gemspec +3 -2
  50. metadata +20 -4
data/patient_http.gemspec CHANGED
@@ -37,10 +37,11 @@ Gem::Specification.new do |spec|
37
37
 
38
38
  spec.require_paths = ["lib"]
39
39
 
40
- spec.required_ruby_version = ">= 3.2"
40
+ spec.required_ruby_version = ">= 3.3"
41
41
 
42
42
  spec.add_dependency "async", "~> 2.0"
43
- spec.add_dependency "async-http", "~> 0.60"
43
+ spec.add_dependency "async-http", "~> 0.99"
44
44
  spec.add_dependency "concurrent-ruby", "~> 1.2"
45
45
  spec.add_dependency "logger"
46
+ spec.add_dependency "protocol-http", "~> 0.66"
46
47
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: patient_http
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.6.0
4
+ version: 1.7.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Brian Durand
@@ -29,14 +29,14 @@ dependencies:
29
29
  requirements:
30
30
  - - "~>"
31
31
  - !ruby/object:Gem::Version
32
- version: '0.60'
32
+ version: '0.99'
33
33
  type: :runtime
34
34
  prerelease: false
35
35
  version_requirements: !ruby/object:Gem::Requirement
36
36
  requirements:
37
37
  - - "~>"
38
38
  - !ruby/object:Gem::Version
39
- version: '0.60'
39
+ version: '0.99'
40
40
  - !ruby/object:Gem::Dependency
41
41
  name: concurrent-ruby
42
42
  requirement: !ruby/object:Gem::Requirement
@@ -65,6 +65,20 @@ dependencies:
65
65
  - - ">="
66
66
  - !ruby/object:Gem::Version
67
67
  version: '0'
68
+ - !ruby/object:Gem::Dependency
69
+ name: protocol-http
70
+ requirement: !ruby/object:Gem::Requirement
71
+ requirements:
72
+ - - "~>"
73
+ - !ruby/object:Gem::Version
74
+ version: '0.66'
75
+ type: :runtime
76
+ prerelease: false
77
+ version_requirements: !ruby/object:Gem::Requirement
78
+ requirements:
79
+ - - "~>"
80
+ - !ruby/object:Gem::Version
81
+ version: '0.66'
68
82
  description: This gem provides a dedicated async HTTP processor that uses Ruby's Fiber
69
83
  scheduler for non-blocking I/O. Application threads hand off HTTP requests to the
70
84
  processor and return immediately. The processor handles hundreds of concurrent HTTP
@@ -91,11 +105,13 @@ files:
91
105
  - lib/patient_http/client_pool.rb
92
106
  - lib/patient_http/completion_executor.rb
93
107
  - lib/patient_http/configuration.rb
108
+ - lib/patient_http/connection_endpoint.rb
94
109
  - lib/patient_http/encryptor.rb
95
110
  - lib/patient_http/error.rb
96
111
  - lib/patient_http/external_storage.rb
97
112
  - lib/patient_http/http_error.rb
98
113
  - lib/patient_http/http_headers.rb
114
+ - lib/patient_http/immediate_retries.rb
99
115
  - lib/patient_http/inline_task_handler.rb
100
116
  - lib/patient_http/lifecycle_manager.rb
101
117
  - lib/patient_http/outgoing_request.rb
@@ -139,7 +155,7 @@ required_ruby_version: !ruby/object:Gem::Requirement
139
155
  requirements:
140
156
  - - ">="
141
157
  - !ruby/object:Gem::Version
142
- version: '3.2'
158
+ version: '3.3'
143
159
  required_rubygems_version: !ruby/object:Gem::Requirement
144
160
  requirements:
145
161
  - - ">="