erigon-pulse/turbo/debug
Dmytro a63b89334b
added logging for slow RPC requests (#8818)
Changed distribution of httpcfg.HttpCfg to be pointer.
Added new flags:
rpc.slow.log - which is false by default, this flag need to enable
logging slow RPC requests
rpc.slow.log.threshold - which is 100 by default, this flag specify slow
threshold in milliseconds
Updated rpc handler to log slow requests:
- added map[request id] {method, timestamp}
- put every request details to map above
- delete request details from map above
- added time interval check for elements in map and if time difference
is more than given threshold print request id and the method
- app will print slow requests in next cases:
1. As soon as request take more than given threshold
2. Every 20 seconds if request still in process
3. After request finished and it took more than give threshold

---------

Co-authored-by: alex.sharov <AskAlexSharov@gmail.com>
2023-11-28 16:11:39 +07:00
..
api.go e3: optimize incremental hashstate (#6179) 2022-12-03 12:23:01 +07:00
flags.go added logging for slow RPC requests (#8818) 2023-11-28 16:11:39 +07:00
loudpanic_fallback.go move all packages from "internal" folder - to simplify users live (#5857) 2022-10-25 09:58:25 +07:00
loudpanic.go move all packages from "internal" folder - to simplify users live (#5857) 2022-10-25 09:58:25 +07:00
signal_windows.go [devnet] Always select first node, fix configuration mess up between nodes (#7863) 2023-07-10 11:37:55 +01:00
signal.go [devnet] Always select first node, fix configuration mess up between nodes (#7863) 2023-07-10 11:37:55 +01:00
trace_fallback.go move all packages from "internal" folder - to simplify users live (#5857) 2022-10-25 09:58:25 +07:00
trace.go move all packages from "internal" folder - to simplify users live (#5857) 2022-10-25 09:58:25 +07:00