feat: Add request start time context key and update middleware

- Introduced a new constant `ContextKeyRequestStartTime` to store the request start time in the context, enhancing request tracking.
- Updated the `Distribute` middleware to set the request start time in the context using the new constant.
- Modified the `GenRelayInfo` function to retrieve the request start time from the context, ensuring accurate timing information is used in relay operations.
This commit is contained in:
CalciumIon committed 2024-12-23 20:48:10 +08:00
1 parent 424af80c77
commit 72be58523c
3 files changed
+13 -6

No files matched your search

+4
View File
@@ -1 +1,5 @@
package constant
const (
ContextKeyRequestStartTime = "request_start_time"
)