Commit 3b4d416
committed
GH-10830: Refine HTTP RestClient delegation and local client lifecycle
Fixes gh-10830
* refactor nullable `RestClient` HTTP DSL factory methods to delegate via RestClient-first paths and remove duplicate fallback branches
* add shared `outboundGatewaySpec(...)` helpers in `Http` to centralize URI/String/Expression client selection
* add non-deprecated local constructors in `HttpMessageHandlerSpec` for URI/String/Expression paths
* keep deprecated RestTemplate DSL overloads and add `@SuppressWarnings("removal")` where they intentionally call deprecated constructors
* build local `RestClient` once in `HttpRequestExecutingMessageHandler#doInit()` and stop rebuilding on each local mutator call
* keep local mutators (`setRequestFactory`, `setErrorHandler`, `setMessageConverters`) applying to local `RestClient.Builder`
* align HTTP proxy test flow with lifecycle semantics by re-initializing after mutator-based setup
* revise HTTP proxy/cookie test fixtures and formatting updates for the current RestClient-backed local behavior
* add `[[x7.1-http-changes]]` section to `whats-new.adoc` documenting HTTP 7.1 updates
Signed-off-by: Arun Sethumadhavan <mailaruns@gmail.com>1 parent 223c120 commit 3b4d416
6 files changed
Lines changed: 62 additions & 45 deletions
File tree
- spring-integration-http/src
- main/java/org/springframework/integration/http
- dsl
- outbound
- test/java/org/springframework/integration/http
- dsl
- outbound
Lines changed: 27 additions & 17 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
90 | 90 | | |
91 | 91 | | |
92 | 92 | | |
| 93 | + | |
93 | 94 | | |
94 | 95 | | |
95 | 96 | | |
| |||
103 | 104 | | |
104 | 105 | | |
105 | 106 | | |
106 | | - | |
107 | | - | |
108 | | - | |
| 107 | + | |
109 | 108 | | |
110 | 109 | | |
111 | 110 | | |
| |||
117 | 116 | | |
118 | 117 | | |
119 | 118 | | |
| 119 | + | |
120 | 120 | | |
121 | 121 | | |
122 | 122 | | |
| |||
130 | 130 | | |
131 | 131 | | |
132 | 132 | | |
133 | | - | |
134 | | - | |
135 | | - | |
| 133 | + | |
136 | 134 | | |
137 | 135 | | |
138 | 136 | | |
| |||
178 | 176 | | |
179 | 177 | | |
180 | 178 | | |
| 179 | + | |
181 | 180 | | |
182 | 181 | | |
183 | 182 | | |
| |||
194 | 193 | | |
195 | 194 | | |
196 | 195 | | |
197 | | - | |
198 | | - | |
199 | | - | |
| 196 | + | |
200 | 197 | | |
201 | 198 | | |
202 | 199 | | |
| |||
247 | 244 | | |
248 | 245 | | |
249 | 246 | | |
| 247 | + | |
250 | 248 | | |
251 | 249 | | |
252 | 250 | | |
| |||
260 | 258 | | |
261 | 259 | | |
262 | 260 | | |
263 | | - | |
264 | | - | |
265 | | - | |
| 261 | + | |
266 | 262 | | |
267 | 263 | | |
268 | 264 | | |
| |||
274 | 270 | | |
275 | 271 | | |
276 | 272 | | |
| 273 | + | |
277 | 274 | | |
278 | 275 | | |
279 | 276 | | |
| |||
287 | 284 | | |
288 | 285 | | |
289 | 286 | | |
290 | | - | |
291 | | - | |
292 | | - | |
| 287 | + | |
293 | 288 | | |
294 | 289 | | |
295 | 290 | | |
| |||
335 | 330 | | |
336 | 331 | | |
337 | 332 | | |
| 333 | + | |
338 | 334 | | |
339 | 335 | | |
340 | 336 | | |
| |||
351 | 347 | | |
352 | 348 | | |
353 | 349 | | |
354 | | - | |
| 350 | + | |
| 351 | + | |
| 352 | + | |
| 353 | + | |
| 354 | + | |
| 355 | + | |
| 356 | + | |
| 357 | + | |
| 358 | + | |
| 359 | + | |
| 360 | + | |
| 361 | + | |
| 362 | + | |
| 363 | + | |
| 364 | + | |
355 | 365 | | |
356 | | - | |
| 366 | + | |
357 | 367 | | |
358 | 368 | | |
359 | 369 | | |
| |||
Lines changed: 14 additions & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
49 | 49 | | |
50 | 50 | | |
51 | 51 | | |
| 52 | + | |
| 53 | + | |
| 54 | + | |
| 55 | + | |
| 56 | + | |
| 57 | + | |
| 58 | + | |
| 59 | + | |
| 60 | + | |
| 61 | + | |
| 62 | + | |
| 63 | + | |
| 64 | + | |
52 | 65 | | |
53 | 66 | | |
54 | 67 | | |
| |||
72 | 85 | | |
73 | 86 | | |
74 | 87 | | |
75 | | - | |
| 88 | + | |
76 | 89 | | |
77 | 90 | | |
78 | 91 | | |
| |||
Lines changed: 2 additions & 9 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
200 | 200 | | |
201 | 201 | | |
202 | 202 | | |
203 | | - | |
204 | | - | |
205 | | - | |
206 | | - | |
207 | 203 | | |
208 | 204 | | |
209 | 205 | | |
| |||
220 | 216 | | |
221 | 217 | | |
222 | 218 | | |
223 | | - | |
224 | 219 | | |
225 | 220 | | |
226 | 221 | | |
| |||
229 | 224 | | |
230 | 225 | | |
231 | 226 | | |
| 227 | + | |
232 | 228 | | |
233 | 229 | | |
234 | 230 | | |
235 | 231 | | |
236 | | - | |
237 | | - | |
238 | | - | |
| 232 | + | |
239 | 233 | | |
240 | 234 | | |
241 | 235 | | |
| |||
248 | 242 | | |
249 | 243 | | |
250 | 244 | | |
251 | | - | |
252 | 245 | | |
253 | 246 | | |
254 | 247 | | |
| |||
Lines changed: 8 additions & 8 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
136 | 136 | | |
137 | 137 | | |
138 | 138 | | |
139 | | - | |
140 | | - | |
141 | | - | |
142 | | - | |
| 139 | + | |
| 140 | + | |
| 141 | + | |
| 142 | + | |
143 | 143 | | |
144 | 144 | | |
145 | 145 | | |
| |||
199 | 199 | | |
200 | 200 | | |
201 | 201 | | |
202 | | - | |
203 | | - | |
204 | | - | |
205 | | - | |
| 202 | + | |
| 203 | + | |
| 204 | + | |
| 205 | + | |
206 | 206 | | |
207 | 207 | | |
208 | 208 | | |
| |||
Lines changed: 1 addition & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
131 | 131 | | |
132 | 132 | | |
133 | 133 | | |
| 134 | + | |
134 | 135 | | |
135 | 136 | | |
136 | 137 | | |
| |||
Lines changed: 10 additions & 10 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
92 | 92 | | |
93 | 93 | | |
94 | 94 | | |
95 | | - | |
| 95 | + | |
96 | 96 | | |
97 | | - | |
| 97 | + | |
98 | 98 | | |
99 | | - | |
| 99 | + | |
100 | 100 | | |
101 | | - | |
102 | | - | |
103 | | - | |
| 101 | + | |
| 102 | + | |
| 103 | + | |
104 | 104 | | |
105 | 105 | | |
106 | 106 | | |
| |||
114 | 114 | | |
115 | 115 | | |
116 | 116 | | |
117 | | - | |
118 | | - | |
119 | | - | |
120 | | - | |
| 117 | + | |
| 118 | + | |
| 119 | + | |
| 120 | + | |
121 | 121 | | |
122 | 122 | | |
123 | 123 | | |
| |||
0 commit comments