Commit 19c6674
committed
Merge upstream/develop into feat/request_size
Resolves conflicts from upstream's ConfigBeanFactory refactor
(c977f82) by adapting maxMessageSize logic to the new model:
- Add maxMessageSize fields to NodeConfig.HttpConfig/JsonRpcConfig.
- Add reference.conf defaults for the two new keys, using human-readable
4M form (consistent with the human-readable input the parsing layer
already accepts; numeric byte form would require operators to do
mental math).
- Inside NodeConfig.fromConfig, pre-normalize the three maxMessageSize
paths (rpc/http/jsonrpc): parse via Config.getMemorySize so values
like "4m" / "128MB" become numeric bytes before ConfigBeanFactory's
primitive int/long binding, and validate non-negative and
<= Integer.MAX_VALUE so failures point at the user-facing config
path. This matches BlockConfig.fromConfig's validation-in-fromConfig
convention and keeps Args.applyNodeConfig as a pure
bean-to-PARAMETER bridge.
- Drop ConfigKey.java (deleted upstream); the two
NODE_*_MAX_MESSAGE_SIZE constants are no longer needed since keys
are derived from bean field names.
Tests: ArgsTest (18), NodeConfigTest (29), SizeLimitHandlerTest,
UtilTest, JsonrpcServiceTest all pass under the merged tree;
framework checkstyleMain and checkstyleTest pass.147 files changed
Lines changed: 11268 additions & 3884 deletions
File tree
- .github/workflows
- chainbase/src/main/java/org/tron/core
- db
- store
- common/src
- main
- java/org/tron
- common/parameter
- core/config
- args
- resources
- test/java/org/tron/core/config/args
- crypto/src/main/java/org/tron/keystore
- docs
- framework/src
- main/java/org/tron
- core
- config/args
- trie
- keystore
- program
- test
- java/org/tron
- common
- backup
- logsfilter
- capsule
- runtime/vm
- utils
- core
- actuator
- utils
- capsule/utils
- config/args
- db2
- db
- event
- exception
- jsonrpc
- net
- messagehandler
- peer
- services
- pbft
- services
- filter
- ratelimiter/adaptor
- tire
- utils
- witness
- keystore
- keystroe
- program
- resources
- plugins
- src
- main/java/common/org/tron/plugins
- test/java/org/tron/plugins
- leveldb
- rocksdb
Some content is hidden
Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
279 | 279 | | |
280 | 280 | | |
281 | 281 | | |
| 282 | + | |
| 283 | + | |
| 284 | + | |
| 285 | + | |
| 286 | + | |
| 287 | + | |
| 288 | + | |
| 289 | + | |
| 290 | + | |
| 291 | + | |
| 292 | + | |
| 293 | + | |
| 294 | + | |
| 295 | + | |
| 296 | + | |
| 297 | + | |
| 298 | + | |
| 299 | + | |
| 300 | + | |
| 301 | + | |
| 302 | + | |
| 303 | + | |
| 304 | + | |
| 305 | + | |
| 306 | + | |
| 307 | + | |
| 308 | + | |
| 309 | + | |
| 310 | + | |
| 311 | + | |
| 312 | + | |
| 313 | + | |
| 314 | + | |
| 315 | + | |
| 316 | + | |
| 317 | + | |
| 318 | + | |
| 319 | + | |
| 320 | + | |
| 321 | + | |
| 322 | + | |
| 323 | + | |
| 324 | + | |
| 325 | + | |
| 326 | + | |
| 327 | + | |
| 328 | + | |
| 329 | + | |
| 330 | + | |
| 331 | + | |
| 332 | + | |
| 333 | + | |
| 334 | + | |
| 335 | + | |
| 336 | + | |
| 337 | + | |
| 338 | + | |
| 339 | + | |
| 340 | + | |
| 341 | + | |
| 342 | + | |
| 343 | + | |
282 | 344 | | |
283 | 345 | | |
284 | 346 | | |
| |||
288 | 350 | | |
289 | 351 | | |
290 | 352 | | |
| 353 | + | |
291 | 354 | | |
292 | 355 | | |
293 | 356 | | |
| |||
300 | 363 | | |
301 | 364 | | |
302 | 365 | | |
| 366 | + | |
303 | 367 | | |
304 | 368 | | |
305 | 369 | | |
306 | 370 | | |
307 | 371 | | |
308 | 372 | | |
309 | 373 | | |
310 | | - | |
| 374 | + | |
311 | 375 | | |
312 | 376 | | |
313 | 377 | | |
| |||
329 | 393 | | |
330 | 394 | | |
331 | 395 | | |
332 | | - | |
| 396 | + | |
333 | 397 | | |
334 | 398 | | |
335 | 399 | | |
| |||
340 | 404 | | |
341 | 405 | | |
342 | 406 | | |
343 | | - | |
344 | | - | |
345 | | - | |
346 | | - | |
347 | | - | |
348 | | - | |
349 | | - | |
350 | | - | |
351 | | - | |
352 | | - | |
| 407 | + | |
| 408 | + | |
| 409 | + | |
| 410 | + | |
| 411 | + | |
| 412 | + | |
| 413 | + | |
| 414 | + | |
| 415 | + | |
| 416 | + | |
353 | 417 | | |
354 | | - | |
| 418 | + | |
355 | 419 | | |
356 | 420 | | |
357 | 421 | | |
| |||
361 | 425 | | |
362 | 426 | | |
363 | 427 | | |
| 428 | + | |
| 429 | + | |
| 430 | + | |
| 431 | + | |
| 432 | + | |
| 433 | + | |
364 | 434 | | |
365 | | - | |
| 435 | + | |
366 | 436 | | |
367 | 437 | | |
368 | 438 | | |
369 | | - | |
| 439 | + | |
370 | 440 | | |
| 441 | + | |
371 | 442 | | |
372 | 443 | | |
373 | 444 | | |
| |||
376 | 447 | | |
377 | 448 | | |
378 | 449 | | |
379 | | - | |
| 450 | + | |
380 | 451 | | |
381 | 452 | | |
382 | 453 | | |
383 | | - | |
| 454 | + | |
384 | 455 | | |
| 456 | + | |
| 457 | + | |
385 | 458 | | |
386 | 459 | | |
387 | 460 | | |
| |||
391 | 464 | | |
392 | 465 | | |
393 | 466 | | |
394 | | - | |
395 | | - | |
396 | | - | |
397 | | - | |
398 | | - | |
399 | | - | |
400 | | - | |
401 | | - | |
| 467 | + | |
| 468 | + | |
| 469 | + | |
402 | 470 | | |
403 | 471 | | |
404 | 472 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
147 | 147 | | |
148 | 148 | | |
149 | 149 | | |
150 | | - | |
| 150 | + | |
151 | 151 | | |
152 | 152 | | |
153 | 153 | | |
| |||
161 | 161 | | |
162 | 162 | | |
163 | 163 | | |
164 | | - | |
| 164 | + | |
165 | 165 | | |
166 | 166 | | |
167 | 167 | | |
| |||
196 | 196 | | |
197 | 197 | | |
198 | 198 | | |
199 | | - | |
| 199 | + | |
200 | 200 | | |
201 | 201 | | |
202 | 202 | | |
| |||
This file was deleted.
Lines changed: 15 additions & 3 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
76 | 76 | | |
77 | 77 | | |
78 | 78 | | |
| 79 | + | |
| 80 | + | |
| 81 | + | |
| 82 | + | |
| 83 | + | |
| 84 | + | |
| 85 | + | |
| 86 | + | |
| 87 | + | |
| 88 | + | |
79 | 89 | | |
80 | 90 | | |
| 91 | + | |
| 92 | + | |
| 93 | + | |
| 94 | + | |
81 | 95 | | |
82 | 96 | | |
83 | | - | |
84 | | - | |
85 | | - | |
| 97 | + | |
86 | 98 | | |
87 | 99 | | |
88 | 100 | | |
| |||
Lines changed: 3 additions & 7 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
62 | 62 | | |
63 | 63 | | |
64 | 64 | | |
65 | | - | |
66 | | - | |
67 | | - | |
68 | 65 | | |
69 | 66 | | |
70 | 67 | | |
71 | 68 | | |
72 | 69 | | |
73 | | - | |
74 | 70 | | |
75 | | - | |
76 | | - | |
77 | | - | |
| 71 | + | |
78 | 72 | | |
| 73 | + | |
| 74 | + | |
79 | 75 | | |
80 | 76 | | |
81 | 77 | | |
Lines changed: 12 additions & 0 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
74 | 74 | | |
75 | 75 | | |
76 | 76 | | |
| 77 | + | |
| 78 | + | |
| 79 | + | |
| 80 | + | |
| 81 | + | |
| 82 | + | |
77 | 83 | | |
78 | 84 | | |
79 | 85 | | |
| |||
93 | 99 | | |
94 | 100 | | |
95 | 101 | | |
| 102 | + | |
| 103 | + | |
| 104 | + | |
| 105 | + | |
| 106 | + | |
| 107 | + | |
96 | 108 | | |
97 | 109 | | |
Lines changed: 2 additions & 1 deletion
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
48 | 48 | | |
49 | 49 | | |
50 | 50 | | |
51 | | - | |
| 51 | + | |
| 52 | + | |
52 | 53 | | |
53 | 54 | | |
54 | 55 | | |
| |||
0 commit comments