fix metadata
This commit is contained in:
@ -1,9 +1,6 @@
|
||||
package http2
|
||||
|
||||
import (
|
||||
"net/http"
|
||||
"time"
|
||||
|
||||
mdata "github.com/go-gost/gost/pkg/metadata"
|
||||
)
|
||||
|
||||
@ -12,24 +9,12 @@ const (
|
||||
)
|
||||
|
||||
type metadata struct {
|
||||
path string
|
||||
handshakeTimeout time.Duration
|
||||
readHeaderTimeout time.Duration
|
||||
readBufferSize int
|
||||
writeBufferSize int
|
||||
enableCompression bool
|
||||
responseHeader http.Header
|
||||
backlog int
|
||||
backlog int
|
||||
}
|
||||
|
||||
func (l *http2Listener) parseMetadata(md mdata.Metadata) (err error) {
|
||||
const (
|
||||
path = "path"
|
||||
handshakeTimeout = "handshakeTimeout"
|
||||
readHeaderTimeout = "readHeaderTimeout"
|
||||
readBufferSize = "readBufferSize"
|
||||
writeBufferSize = "writeBufferSize"
|
||||
backlog = "backlog"
|
||||
backlog = "backlog"
|
||||
)
|
||||
|
||||
l.md.backlog = mdata.GetInt(md, backlog)
|
||||
|
Reference in New Issue
Block a user