feat(worker): net.Conn implementation to count Bytes Read and Written
This commit introduces a new net.Conn implementation (countingConn) that will keep track of bytes read and written for a particular client connection. This is then implemented into the worker code using interface composition. Refs: #2501
This commit is contained in:
1 parent
f114e20c6d
commit
1bb80624b8
7 files changed
+261
-17
No files matched your search
@@ -7,7 +7,6 @@ import (
|
||||
"sync"
|
||||
|
||||
"github.com/hashicorp/boundary/internal/daemon/worker/session"
|
||||
"nhooyr.io/websocket"
|
||||
)
|
||||
|
||||
// Config provides the core parameters needed for a worker to create a proxy between
|
||||
@@ -20,7 +19,7 @@ type Config struct {
|
||||
// there are any load balancers or proxies between the user and the worker,
|
||||
// then it will be the address of the last one before the worker.
|
||||
ClientAddress *net.TCPAddr
|
||||
ClientConn *websocket.Conn
|
||||
ClientConn net.Conn
|
||||
RemoteEndpoint string
|
||||
|
||||
Session session.Session
|
||||
|
||||
Reference in new issue
Block a user