aboutsummaryrefslogtreecommitdiffstats
path: root/src/plugins/hs_apps
diff options
context:
space:
mode:
authorFlorin Coras <fcoras@cisco.com>2019-11-19 17:23:22 -0800
committerFlorin Coras <florin.coras@gmail.com>2019-11-20 02:12:32 +0000
commit3bbbf0dbd367fd8611f9f390a2c6e31a89ce08a9 (patch)
tree6390f285aaf43d448ed341afe9f125901058bfc1 /src/plugins/hs_apps
parent331c428a9c5f4686a9102eba9715233cceb43d55 (diff)
session: fix transport proto unformat
Type: fix Change-Id: I38a5cbd53b278c21142bac4ee1bbe5dc8bcaaac9 Signed-off-by: Florin Coras <fcoras@cisco.com>
Diffstat (limited to 'src/plugins/hs_apps')
-rw-r--r--src/plugins/hs_apps/echo_client.c15
1 files changed, 12 insertions, 3 deletions
diff --git a/src/plugins/hs_apps/echo_client.c b/src/plugins/hs_apps/echo_client.c
index 0f8d9c5f748..ba9785cd547 100644
--- a/src/plugins/hs_apps/echo_client.c
+++ b/src/plugins/hs_apps/echo_client.c
@@ -727,8 +727,14 @@ echo_clients_connect (vlib_main_t * vm, u32 n_clients)
a->uri = (char *) ecm->connect_uri;
a->api_context = i;
a->app_index = ecm->app_index;
+
+ vlib_worker_thread_barrier_sync (vm);
if ((rv = vnet_connect_uri (a)))
- return clib_error_return (0, "connect returned: %d", rv);
+ {
+ vlib_worker_thread_barrier_release (vm);
+ return clib_error_return (0, "connect returned: %d", rv);
+ }
+ vlib_worker_thread_barrier_release (vm);
/* Crude pacing for call setups */
if ((i % 16) == 0)
@@ -870,7 +876,8 @@ echo_clients_command_fn (vlib_main_t * vm,
if ((rv = parse_uri ((char *) ecm->connect_uri, &sep)))
return clib_error_return (0, "Uri parse error: %d", rv);
ecm->transport_proto = sep.transport_proto;
- ecm->is_dgram = (sep.transport_proto == TRANSPORT_PROTO_UDP);
+ ecm->is_dgram = (sep.transport_proto == TRANSPORT_PROTO_UDP
+ || sep.transport_proto == TRANSPORT_PROTO_UDPC);
#if ECHO_CLIENT_PTHREAD
echo_clients_start_tx_pthread ();
@@ -903,7 +910,9 @@ echo_clients_command_fn (vlib_main_t * vm,
/* Fire off connect requests */
time_before_connects = vlib_time_now (vm);
if ((error = echo_clients_connect (vm, n_clients)))
- goto cleanup;
+ {
+ goto cleanup;
+ }
/* Park until the sessions come up, or ten seconds elapse... */
vlib_process_wait_for_event_or_clock (vm, syn_timeout);