aboutsummaryrefslogtreecommitdiff
path: root/src/sp/reconnect_stress_test.c
diff options
context:
space:
mode:
authorGarrett D'Amore <garrett@damore.org>2025-01-01 12:44:02 -0800
committerGarrett D'Amore <garrett@damore.org>2025-01-01 12:44:02 -0800
commit0d23af92531b7c0dd6d7b74c73c1a8c4811c7d13 (patch)
tree2dc9ded3dfc724df42a360a9f2de359f406e537f /src/sp/reconnect_stress_test.c
parentf8a2abaf931557030fd6e6683617c6a7877eebf7 (diff)
downloadnng-0d23af92531b7c0dd6d7b74c73c1a8c4811c7d13.tar.gz
nng-0d23af92531b7c0dd6d7b74c73c1a8c4811c7d13.tar.bz2
nng-0d23af92531b7c0dd6d7b74c73c1a8c4811c7d13.zip
protocols: move content from the protocols to nng.h
This should simplify things for developers. Just one header to include in most cases now.
Diffstat (limited to 'src/sp/reconnect_stress_test.c')
-rw-r--r--src/sp/reconnect_stress_test.c13
1 files changed, 5 insertions, 8 deletions
diff --git a/src/sp/reconnect_stress_test.c b/src/sp/reconnect_stress_test.c
index 578e34bd..685f8b98 100644
--- a/src/sp/reconnect_stress_test.c
+++ b/src/sp/reconnect_stress_test.c
@@ -1,4 +1,5 @@
//
+// Copyright 2025 Staysail Systems, Inc. <info@staysail.tech>
// Copyright 2024 Aleksei Solovev <solovalex@gmail.com>
//
// This software is supplied under the terms of the MIT License, a
@@ -10,10 +11,6 @@
#include <assert.h>
#include <core/nng_impl.h>
#include <nng/nng.h>
-#include <nng/protocol/reqrep0/rep.h>
-#include <nng/protocol/reqrep0/req.h>
-#include <nng/protocol/survey0/respond.h>
-#include <nng/protocol/survey0/survey.h>
#include <nuts.h>
@@ -187,7 +184,7 @@ void
surveyor_open(struct work *w)
{
w->start = ping_start;
- NUTS_PASS(nng_surveyor_open(&w->socket));
+ NUTS_PASS(nng_surveyor0_open(&w->socket));
NUTS_PASS(nng_socket_set_ms(
w->socket, NNG_OPT_SURVEYOR_SURVEYTIME, SURVEY_TIMEOUT_MS));
NUTS_PASS(nng_aio_alloc(&w->aio, ping_cb, w));
@@ -198,7 +195,7 @@ void
respondent_open(struct work *w)
{
w->start = echo_start;
- NUTS_PASS(nng_respondent_open(&w->socket));
+ NUTS_PASS(nng_respondent0_open(&w->socket));
NUTS_PASS(nng_aio_alloc(&w->aio, echo_cb, w));
nni_atomic_init(&w->received);
}
@@ -207,7 +204,7 @@ void
req_open(struct work *w)
{
w->start = ping_start;
- NUTS_PASS(nng_req_open(&w->socket));
+ NUTS_PASS(nng_req0_open(&w->socket));
NUTS_PASS(nng_aio_alloc(&w->aio, ping_cb, w));
nni_atomic_init(&w->received);
}
@@ -216,7 +213,7 @@ void
rep_open(struct work *w)
{
w->start = echo_start;
- NUTS_PASS(nng_rep_open(&w->socket));
+ NUTS_PASS(nng_rep0_open(&w->socket));
NUTS_PASS(nng_aio_alloc(&w->aio, echo_cb, w));
nni_atomic_init(&w->received);
}