2022-01-20 04:41:25 -07:00
|
|
|
// Copyright 2021 The Gitea Authors. All rights reserved.
|
2022-11-27 11:20:29 -07:00
|
|
|
// SPDX-License-Identifier: MIT
|
2022-01-20 04:41:25 -07:00
|
|
|
|
|
|
|
package routing
|
|
|
|
|
|
|
|
import (
|
|
|
|
"net/http"
|
|
|
|
"sync"
|
|
|
|
"time"
|
|
|
|
)
|
|
|
|
|
|
|
|
type requestRecord struct {
|
|
|
|
// index of the record in the records map
|
|
|
|
index uint64
|
|
|
|
|
|
|
|
// immutable fields
|
|
|
|
startTime time.Time
|
|
|
|
request *http.Request
|
|
|
|
responseWriter http.ResponseWriter
|
|
|
|
|
|
|
|
// mutex
|
|
|
|
lock sync.RWMutex
|
|
|
|
|
|
|
|
// mutable fields
|
|
|
|
isLongPolling bool
|
|
|
|
funcInfo *FuncInfo
|
2023-07-04 12:36:08 -06:00
|
|
|
panicError any
|
2022-01-20 04:41:25 -07:00
|
|
|
}
|