File tree Expand file tree Collapse file tree 2 files changed +7
-0
lines changed Expand file tree Collapse file tree 2 files changed +7
-0
lines changed Original file line number Diff line number Diff line change @@ -63,6 +63,7 @@ impl Manager {
63
63
AllocationInfo :: new (
64
64
* five_tuple,
65
65
alloc. username . text . clone ( ) ,
66
+ alloc. relay_addr ,
66
67
#[ cfg( feature = "metrics" ) ]
67
68
alloc. relayed_bytes . load ( Ordering :: Acquire ) ,
68
69
) ,
Original file line number Diff line number Diff line change @@ -45,6 +45,9 @@ pub struct AllocationInfo {
45
45
/// Username of this [`Allocation`].
46
46
pub username : String ,
47
47
48
+ /// Relay address of this [`Allocation`].
49
+ pub relay_addr : SocketAddr ,
50
+
48
51
/// Relayed bytes with this [`Allocation`].
49
52
#[ cfg( feature = "metrics" ) ]
50
53
pub relayed_bytes : usize ,
@@ -55,11 +58,13 @@ impl AllocationInfo {
55
58
pub fn new (
56
59
five_tuple : FiveTuple ,
57
60
username : String ,
61
+ relay_addr : SocketAddr ,
58
62
#[ cfg( feature = "metrics" ) ] relayed_bytes : usize ,
59
63
) -> Self {
60
64
Self {
61
65
five_tuple,
62
66
username,
67
+ relay_addr,
63
68
#[ cfg( feature = "metrics" ) ]
64
69
relayed_bytes,
65
70
}
@@ -255,6 +260,7 @@ impl Allocation {
255
260
. send ( AllocationInfo {
256
261
five_tuple : self . five_tuple ,
257
262
username : self . username . text . clone ( ) ,
263
+ relay_addr : self . relay_addr ,
258
264
#[ cfg( feature = "metrics" ) ]
259
265
relayed_bytes : self . relayed_bytes . load ( Ordering :: Acquire ) ,
260
266
} )
You can’t perform that action at this time.
0 commit comments