summaryrefslogtreecommitdiffstats
path: root/src/plugins
diff options
context:
space:
mode:
authorFlorin Coras <fcoras@cisco.com>2023-12-21 19:41:12 -0800
committerDave Barach <vpp@barachs.net>2024-01-09 17:07:54 +0000
commit97fef28a0bd700d6ac6d8325e8a4335614d95bec (patch)
treec2cd572c8d0c9674dc21c4341aa9cb3adeebda1d /src/plugins
parent7428eaa4a1ae55052825cdc6c0a9ae6c4f8748ac (diff)
session: make app listener pool global
One less pointer chase when accepting sessions. Type: improvement Signed-off-by: Florin Coras <fcoras@cisco.com> Change-Id: I20dbb21d15d4a703f76e3b12f04a6f5b5d2a3cd8
Diffstat (limited to 'src/plugins')
-rw-r--r--src/plugins/unittest/session_test.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/src/plugins/unittest/session_test.c b/src/plugins/unittest/session_test.c
index 70b3b32a2e4..96c2465f7fc 100644
--- a/src/plugins/unittest/session_test.c
+++ b/src/plugins/unittest/session_test.c
@@ -1625,6 +1625,7 @@ session_test_proxy (vlib_main_t * vm, unformat_input_t * input)
u16 lcl_port = 1234, rmt_port = 4321;
app_namespace_t *app_ns;
int verbose = 0, error = 0;
+ app_listener_t *al;
while (unformat_check_input (input) != UNFORMAT_END_OF_INPUT)
{
@@ -1699,8 +1700,9 @@ session_test_proxy (vlib_main_t * vm, unformat_input_t * input)
SESSION_TEST ((tc != 0), "lookup 1.2.3.4 1234 5.6.7.8 4321 should be "
"successful");
s = listen_session_get (tc->s_index);
- SESSION_TEST ((s->app_index == server_index), "lookup should return"
- " the server");
+ al = app_listener_get (s->al_index);
+ SESSION_TEST ((al->app_index == server_index), "lookup should return"
+ " the server");
tc = session_lookup_connection_wt4 (0, &rmt_ip, &rmt_ip, lcl_port, rmt_port,
TRANSPORT_PROTO_TCP, 0, &is_filtered);