Closed atimin closed 3 years ago
^ ok, not sure .. it looks weird. I've gone through the config and log lines, and it seems the initial rawsocket and wamp opening handshakes succeed (and it then fails upon the first call), but just to be sure: if you comment out everything after the session has "joined realm", and let it sit idle, does that work fine?
Thank you for the response. Unfortunately, not. I reduce the program:
boost::asio::io_service io;
TcpResolver resolver(io);
TcpResolver::query q(parser.host(), parser.port());
auto results = resolver.resolve(q);
auto endpoint = results.begin()->endpoint();
auto debug = static_cast<std::string>(log_level) == "DEBUG";
auto transport =
std::make_shared<autobahn::wamp_tcp_transport>(io, endpoint, debug);
auto session = std::make_shared<autobahn::wamp_session>(io, debug);
transport->attach(
std::static_pointer_cast<autobahn::wamp_transport_handler>(session));
boost::future<void> connect_future;
boost::future<void> start_future;
boost::future<void> join_future;
connect_future = transport->connect().then([&](auto started) {
try {
started.get();
} catch (const std::exception& e) {
LOG_ERROR() << e.what();
io.stop();
return;
}
LOG_INFO() << "Connected with " << wamp_router;
start_future = session->start().then([&](auto started) {
try {
started.get();
} catch (const std::exception& e) {
LOG_ERROR() << e.what();
io.stop();
return;
}
LOG_INFO() << "Start WAMP session";
join_future =
session->join(static_cast<std::string>("adt"))
.then([&](boost::future<uint64_t> joined) {
try {
LOG_INFO() << "joined realm: " << joined.get();
} catch (const std::exception& e) {
LOG_ERROR() << e.what();
io.stop();
return;
}
});
});
});
io.run();
LOG_INFO() << "Graceful exit";
return 0;
And have the same error in the router's logs
ok, in this case, I would first further bisect the problem - you could try these included examples:
c++ caller vs c++ callee, and the second shows websocket vs rawsocket
the other path to explore is to tune up log level in crossbar to find out why it runs into "WAMP ProtocolError - aborting connection" .. what is the client sending that is a protocol error?
This is the logs with level trace:
crossbar_1 | 2021-06-01T14:19:12+0000 [Router 21 crossbar.router.protocol.WampRawSocketServerFactory] WampRawSocketServerFactory.buildProtocol(addr=IPv4Address(type='TCP', host='172.22.0.1', port=47710))
crossbar_1 | 2021-06-01T14:19:12+0000 [Router 21 crossbar.router.protocol.WampRawSocketServerFactory] WampRawSocketServerFactory.buildProtocol() -> proto=<crossbar.router.protocol.WampRawSocketServerProtocol object at 0x7fc9688791d0>, max_message_size=16777216, MAX_LENGTH=16777216
crossbar_1 | 2021-06-01T14:19:12+0000 [Router 21 crossbar.router.protocol.WampRawSocketServerProtocol] WampRawSocketServerProtocol.connectionMade()
crossbar_1 | 2021-06-01T14:19:12+0000 [Router 21 crossbar.router.protocol.WampRawSocketServerProtocol] WampRawSocketServerProtocol: opening handshake received - 0x7ff20000
crossbar_1 | 2021-06-01T14:19:12+0000 [Router 21 crossbar.router.protocol.WampRawSocketServerProtocol] WampRawSocketServerProtocol: correct magic byte received
crossbar_1 | 2021-06-01T14:19:12+0000 [Router 21 crossbar.router.protocol.WampRawSocketServerProtocol] WampRawSocketServerProtocol: client requests us to send out most 16777216 bytes per message
crossbar_1 | 2021-06-01T14:19:12+0000 [Router 21 crossbar.router.protocol.WampRawSocketServerProtocol] WampRawSocketServerProtocol: client wants to use serializer '2'
crossbar_1 | 2021-06-01T14:19:12+0000 [Router 21 crossbar.router.protocol.WampRawSocketServerProtocol] WampRawSocketServerProtocol._on_handshake_complete(): calling <bound method RouterSession.onOpen of <crossbar.router.session.RouterSession object at 0x7fc968968f90>>
crossbar_1 | 2021-06-01T14:19:12+0000 [Router 21 crossbar.router.session.RouterSession] Client session connected - transport: {'type': 'rawsocket', 'protocol': 'wamp.2.msgpack', 'peer': 'tcp4:172.22.0.1:47710', 'channel_id': '0000000000000000000000000000000000000000000000000000000000000000'}
crossbar_1 | 2021-06-01T14:19:12+0000 [Router 21 crossbar.router.protocol.WampRawSocketServerProtocol] WampRawSocketServerProtocol._on_handshake_complete(): <crossbar.router.session.RouterSession object at 0x7fc968968f90> started (res=None).
crossbar_1 | 2021-06-01T14:19:12+0000 [Router 21 crossbar.router.protocol.WampRawSocketServerProtocol] WampRawSocketServerProtocol: opening handshake completed: <autobahn.wamp.serializer.MsgPackSerializer object at 0x7fc96889d510>
crossbar_1 | 2021-06-01T14:19:12+0000 [Router 21 crossbar.router.protocol.WampRawSocketServerProtocol] WampRawSocketServerProtocol.stringReceived(): RX 9301a361647493a6617574686964a0ab617574686d6574686f647390a5726f6c657394aa7375627363726962657290a97075626c697368657290a663616c6c656591a8666561747572657391ac63616c6c5f74696d656f7574c3a663616c6c657291a8666561747572657391ac63616c6c5f74696d656f7574c3 octets
crossbar_1 | 2021-06-01T14:19:12+0000 [Router 21 crossbar.router.protocol.WampRawSocketServerProtocol] WampRawSocketServerProtocol.stringReceived: WAMP ProtocolError - aborting connection!
crossbar_1 | invalid serialization of WAMP message: ExtraData unpack(b) received extra data.
crossbar_1 | 2021-06-01T14:19:12+0000 [Router 21 crossbar.router.protocol.WampRawSocketServerProtocol] WampRawSocketServerProtocol.connectionLost(reason="[Failure instance: Traceback (failure with no frames): <class 'twisted.internet.error.ConnectionAborted'>: Connection was aborted locally using ITCPTransport.abortConnection.
crossbar_1 | ]"
crossbar_1 | 2021-06-01T14:19:12+0000 [Router 21 crossbar.router.session.RouterSession] RouterSession.onClose(was_clean=False)
I'm trying to build the examples.
Okay, I've built the examples and have the same problem for caller.cpp:
crossbar_1 | 2021-06-01T14:30:39+0000 [Router 21 crossbar.router.protocol.WampRawSocketServerFactory] WampRawSocketServerFactory.buildProtocol(addr=IPv4Address(type='TCP', host='172.22.0.1', port=47876))
crossbar_1 | 2021-06-01T14:30:39+0000 [Router 21 crossbar.router.protocol.WampRawSocketServerFactory] WampRawSocketServerFactory.buildProtocol() -> proto=<crossbar.router.protocol.WampRawSocketServerProtocol object at 0x7fc9688594d0>, max_message_size=16777216, MAX_LENGTH=16777216
crossbar_1 | 2021-06-01T14:30:39+0000 [Router 21 crossbar.router.protocol.WampRawSocketServerProtocol] WampRawSocketServerProtocol.connectionMade()
crossbar_1 | 2021-06-01T14:30:39+0000 [Router 21 crossbar.router.protocol.WampRawSocketServerProtocol] WampRawSocketServerProtocol: opening handshake received - 0x7ff20000
crossbar_1 | 2021-06-01T14:30:39+0000 [Router 21 crossbar.router.protocol.WampRawSocketServerProtocol] WampRawSocketServerProtocol: correct magic byte received
crossbar_1 | 2021-06-01T14:30:39+0000 [Router 21 crossbar.router.protocol.WampRawSocketServerProtocol] WampRawSocketServerProtocol: client requests us to send out most 16777216 bytes per message
crossbar_1 | 2021-06-01T14:30:39+0000 [Router 21 crossbar.router.protocol.WampRawSocketServerProtocol] WampRawSocketServerProtocol: client wants to use serializer '2'
crossbar_1 | 2021-06-01T14:30:39+0000 [Router 21 crossbar.router.protocol.WampRawSocketServerProtocol] WampRawSocketServerProtocol._on_handshake_complete(): calling <bound method RouterSession.onOpen of <crossbar.router.session.RouterSession object at 0x7fc968859950>>
crossbar_1 | 2021-06-01T14:30:39+0000 [Router 21 crossbar.router.session.RouterSession] Client session connected - transport: {'type': 'rawsocket', 'protocol': 'wamp.2.msgpack', 'peer': 'tcp4:172.22.0.1:47876', 'channel_id': '0000000000000000000000000000000000000000000000000000000000000000'}
crossbar_1 | 2021-06-01T14:30:39+0000 [Router 21 crossbar.router.protocol.WampRawSocketServerProtocol] WampRawSocketServerProtocol._on_handshake_complete(): <crossbar.router.session.RouterSession object at 0x7fc968859950> started (res=None).
crossbar_1 | 2021-06-01T14:30:39+0000 [Router 21 crossbar.router.protocol.WampRawSocketServerProtocol] WampRawSocketServerProtocol: opening handshake completed: <autobahn.wamp.serializer.MsgPackSerializer object at 0x7fc968859790>
crossbar_1 | 2021-06-01T14:30:39+0000 [Router 21 crossbar.router.protocol.WampRawSocketServerProtocol] WampRawSocketServerProtocol.stringReceived(): RX 9301a361647493a6617574686964a0a5726f6c657394a97075626c697368657290a663616c6c657291a8666561747572657391ac63616c6c5f74696d656f7574c3aa7375627363726962657290a663616c6c656591a8666561747572657391ac63616c6c5f74696d656f7574c3ab617574686d6574686f647390 octets
crossbar_1 | 2021-06-01T14:30:39+0000 [Router 21 crossbar.router.protocol.WampRawSocketServerProtocol] WampRawSocketServerProtocol.stringReceived: WAMP ProtocolError - aborting connection!
crossbar_1 | invalid serialization of WAMP message: ExtraData unpack(b) received extra data.
crossbar_1 | 2021-06-01T14:30:39+0000 [Router 21 crossbar.router.protocol.WampRawSocketServerProtocol] WampRawSocketServerProtocol.connectionLost(reason="[Failure instance: Traceback (failure with no frames): <class 'twisted.internet.error.ConnectionAborted'>: Connection was aborted locally using ITCPTransport.abortConnection.
crossbar_1 | ]"
crossbar_1 | 2021-06-01T14:30:39+0000 [Router 21 crossbar.router.session.RouterSession] RouterSession.onClose(was_clean=False)
for websocket_calee.cpp
crossbar_1 | msgpack.exceptions.ExtraData: unpack(b) received extra data.
crossbar_1 |
crossbar_1 | During handling of the above exception, another exception occurred:
crossbar_1 |
crossbar_1 | Traceback (most recent call last):
crossbar_1 | File "/usr/local/lib/python3.7/site-packages/autobahn/wamp/websocket.py", line 88, in onMessage
crossbar_1 | for msg in self._serializer.unserialize(payload, isBinary):
crossbar_1 | File "/usr/local/lib/python3.7/site-packages/autobahn/wamp/serializer.py", line 277, in unserialize
crossbar_1 | raise ProtocolError("invalid serialization of WAMP message: {0} {1}".format(type(e).__name__, e))
crossbar_1 | autobahn.wamp.exception.ProtocolError: invalid serialization of WAMP message: ExtraData unpack(b) received extra data.
crossbar_1 |
crossbar_1 | 2021-06-01T14:29:03+0000 [Router 21 crossbar.router.protocol.WampWebSocketServerProtocol] Failing WAMP-over-WebSocket transport: code=1002, reason="WAMP Protocol Error (invalid serialization of WAMP message: ExtraData unpack(b) received extra data.)"
crossbar_1 | 2021-06-01T14:29:03+0000 [Router 21 crossbar.router.protocol.WampWebSocketServerProtocol] failing WebSocket connection (code=1002): "WAMP Protocol Error (invalid serialization of WAMP message: ExtraData unpack(b) received extra data.)"
crossbar_1 | 2021-06-01T14:29:03+0000 [Router 21 crossbar.router.protocol.WampWebSocketServerProtocol] dropping connection to peer tcp4:172.22.0.1:60624 with abort=True
crossbar_1 | 2021-06-01T14:29:03+0000 [Router 21 crossbar.router.protocol.WampWebSocketServerProtocol] Connection to/from tcp4:172.22.0.1:60624 was aborted locally
crossbar_1 | 2021-06-01T14:29:03+0000 [Router 21 crossbar.router.protocol.WampWebSocketServerProtocol] _connectionLost: [Failure instance: Traceback (failure with no frames): <class 'twisted.internet.error.ConnectionAborted'>: Connection was aborted locally using ITCPTransport.abortConnection.
crossbar_1 | ]
crossbar_1 | 2021-06-01T14:29:03+0000 [Router 21 crossbar.router.protocol.WampWebSocketServerProtocol] WAMP-over-WebSocket transport lost: wasClean=True, code=1002, reason="WAMP Protocol Error (invalid serialization of WAMP message: ExtraData unpack(b) received extra data.)"
crossbar_1 | 2021-06-01T14:29:03+0000 [Router 21 crossbar.router.session.RouterSession] RouterSession.onClose(was_clean=True)
crossbar_1 | 2021-06-01T14:30:39+0000 [Router 21 crossbar.router.protocol.WampRawSocketServerFactory] WampRawSocketServerFactory.buildProtocol(addr=IPv4Address(type='TCP', host='172.22.0.1', port=47876))
crossbar_1 | 2021-06-01T14:30:39+0000 [Router 21 crossbar.router.protocol.WampRawSocketServerFactory] WampRawSocketServerFactory.buildProtocol() -> proto=<crossbar.router.protocol.WampRawSocketServerProtocol object at 0x7fc9688594d0>, max_message_size=16777216, MAX_LENGTH=16777216
crossbar_1 | 2021-06-01T14:30:39+0000 [Router 21 crossbar.router.protocol.WampRawSocketServerProtocol] WampRawSocketServerProtocol.connectionMade()
crossbar_1 | 2021-06-01T14:30:39+0000 [Router 21 crossbar.router.protocol.WampRawSocketServerProtocol] WampRawSocketServerProtocol: opening handshake received - 0x7ff20000
crossbar_1 | 2021-06-01T14:30:39+0000 [Router 21 crossbar.router.protocol.WampRawSocketServerProtocol] WampRawSocketServerProtocol: correct magic byte received
crossbar_1 | 2021-06-01T14:30:39+0000 [Router 21 crossbar.router.protocol.WampRawSocketServerProtocol] WampRawSocketServerProtocol: client requests us to send out most 16777216 bytes per message
crossbar_1 | 2021-06-01T14:30:39+0000 [Router 21 crossbar.router.protocol.WampRawSocketServerProtocol] WampRawSocketServerProtocol: client wants to use serializer '2'
crossbar_1 | 2021-06-01T14:30:39+0000 [Router 21 crossbar.router.protocol.WampRawSocketServerProtocol] WampRawSocketServerProtocol._on_handshake_complete(): calling <bound method RouterSession.onOpen of <crossbar.router.session.RouterSession object at 0x7fc968859950>>
crossbar_1 | 2021-06-01T14:30:39+0000 [Router 21 crossbar.router.session.RouterSession] Client session connected - transport: {'type': 'rawsocket', 'protocol': 'wamp.2.msgpack', 'peer': 'tcp4:172.22.0.1:47876', 'channel_id': '0000000000000000000000000000000000000000000000000000000000000000'}
crossbar_1 | 2021-06-01T14:30:39+0000 [Router 21 crossbar.router.protocol.WampRawSocketServerProtocol] WampRawSocketServerProtocol._on_handshake_complete(): <crossbar.router.session.RouterSession object at 0x7fc968859950> started (res=None).
crossbar_1 | 2021-06-01T14:30:39+0000 [Router 21 crossbar.router.protocol.WampRawSocketServerProtocol] WampRawSocketServerProtocol: opening handshake completed: <autobahn.wamp.serializer.MsgPackSerializer object at 0x7fc968859790>
crossbar_1 | 2021-06-01T14:30:39+0000 [Router 21 crossbar.router.protocol.WampRawSocketServerProtocol] WampRawSocketServerProtocol.stringReceived(): RX 9301a361647493a6617574686964a0a5726f6c657394a97075626c697368657290a663616c6c657291a8666561747572657391ac63616c6c5f74696d656f7574c3aa7375627363726962657290a663616c6c656591a8666561747572657391ac63616c6c5f74696d656f7574c3ab617574686d6574686f647390 octets
crossbar_1 | 2021-06-01T14:30:39+0000 [Router 21 crossbar.router.protocol.WampRawSocketServerProtocol] WampRawSocketServerProtocol.stringReceived: WAMP ProtocolError - aborting connection!
crossbar_1 | invalid serialization of WAMP message: ExtraData unpack(b) received extra data.
crossbar_1 | 2021-06-01T14:30:39+0000 [Router 21 crossbar.router.protocol.WampRawSocketServerProtocol] WampRawSocketServerProtocol.connectionLost(reason="[Failure instance: Traceback (failure with no frames): <class 'twisted.internet.error.ConnectionAborted'>: Connection was aborted locally using ITCPTransport.abortConnection.
crossbar_1 | ]"
crossbar_1 | 2021-06-01T14:30:39+0000 [Router 21 crossbar.router.session.RouterSession] RouterSession.onClose(crossbar_1 | 2021-06-01T14:30:39+0000 [Router 21 crossbar.router.protocol.WampRawSocketServerFactory] WampRawSocketServerFactory.buildProtocol(addr=IPv4Address(type='TCP', host='172.22.0.1', port=47876))
crossbar_1 | 2021-06-01T14:30:39+0000 [Router 21 crossbar.router.protocol.WampRawSocketServerFactory] WampRawSocketServerFactory.buildProtocol() -> proto=<crossbar.router.protocol.WampRawSocketServerProtocol object at 0x7fc9688594d0>, max_message_size=16777216, MAX_LENGTH=16777216
crossbar_1 | 2021-06-01T14:30:39+0000 [Router 21 crossbar.router.protocol.WampRawSocketServerProtocol] WampRawSocketServerProtocol.connectionMade()
crossbar_1 | 2021-06-01T14:30:39+0000 [Router 21 crossbar.router.protocol.WampRawSocketServerProtocol] WampRawSocketServerProtocol: opening handshake received - 0x7ff20000
crossbar_1 | 2021-06-01T14:30:39+0000 [Router 21 crossbar.router.protocol.WampRawSocketServerProtocol] WampRawSocketServerProtocol: correct magic byte received
crossbar_1 | 2021-06-01T14:30:39+0000 [Router 21 crossbar.router.protocol.WampRawSocketServerProtocol] WampRawSocketServerProtocol: client requests us to send out most 16777216 bytes per message
crossbar_1 | 2021-06-01T14:30:39+0000 [Router 21 crossbar.router.protocol.WampRawSocketServerProtocol] WampRawSocketServerProtocol: client wants to use serializer '2'
crossbar_1 | 2021-06-01T14:30:39+0000 [Router 21 crossbar.router.protocol.WampRawSocketServerProtocol] WampRawSocketServerProtocol._on_handshake_complete(): calling <bound method RouterSession.onOpen of <crossbar.router.session.RouterSession object at 0x7fc968859950>>
crossbar_1 | 2021-06-01T14:30:39+0000 [Router 21 crossbar.router.session.RouterSession] Client session connected - transport: {'type': 'rawsocket', 'protocol': 'wamp.2.msgpack', 'peer': 'tcp4:172.22.0.1:47876', 'channel_id': '0000000000000000000000000000000000000000000000000000000000000000'}
crossbar_1 | 2021-06-01T14:30:39+0000 [Router 21 crossbar.router.protocol.WampRawSocketServerProtocol] WampRawSocketServerProtocol._on_handshake_complete(): <crossbar.router.session.RouterSession object at 0x7fc968859950> started (res=None).
crossbar_1 | 2021-06-01T14:30:39+0000 [Router 21 crossbar.router.protocol.WampRawSocketServerProtocol] WampRawSocketServerProtocol: opening handshake completed: <autobahn.wamp.serializer.MsgPackSerializer object at 0x7fc968859790>
crossbar_1 | 2021-06-01T14:30:39+0000 [Router 21 crossbar.router.protocol.WampRawSocketServerProtocol] WampRawSocketServerProtocol.stringReceived(): RX 9301a361647493a6617574686964a0a5726f6c657394a97075626c697368657290a663616c6c657291a8666561747572657391ac63616c6c5f74696d656f7574c3aa7375627363726962657290a663616c6c656591a8666561747572657391ac63616c6c5f74696d656f7574c3ab617574686d6574686f647390 octets
crossbar_1 | 2021-06-01T14:30:39+0000 [Router 21 crossbar.router.protocol.WampRawSocketServerProtocol] WampRawSocketServerProtocol.stringReceived: WAMP ProtocolError - aborting connection!
crossbar_1 | invalid serialization of WAMP message: ExtraData unpack(b) received extra data.
crossbar_1 | 2021-06-01T14:30:39+0000 [Router 21 crossbar.router.protocol.WampRawSocketServerProtocol] WampRawSocketServerProtocol.connectionLost(reason="[Failure instance: Traceback (failure with no frames): <class 'twisted.internet.error.ConnectionAborted'>: Connection was aborted locally using ITCPTransport.abortConnection.
crossbar_1 | ]"
crossbar_1 | 2021-06-01T14:30:39+0000 [Router 21 crossbar.router.session.RouterSession] RouterSession.onClose(was_clean=False)
was_clean=False)
I guess something with Msgpack. I've installed it by using apt install
command on ubuntu-20.04. Maybe the version is not proper. Btw. I didn't find them in cmake log, however I manged to build the example:
16:24 $ cmake ..
CMake Deprecation Warning at CMakeLists.txt:1 (cmake_minimum_required):
Compatibility with CMake < 2.8.12 will be removed from a future version of
CMake.
Update the VERSION argument <min> value or use a ...<max> suffix to tell
CMake that the project does not need compatibility with older versions.
-- The C compiler identification is GNU 9.3.0
-- The CXX compiler identification is GNU 9.3.0
-- Detecting C compiler ABI info
-- Detecting C compiler ABI info - done
-- Check for working C compiler: /usr/bin/cc - skipped
-- Detecting C compile features
-- Detecting C compile features - done
-- Detecting CXX compiler ABI info
-- Detecting CXX compiler ABI info - done
-- Check for working CXX compiler: /usr/bin/c++ - skipped
-- Detecting CXX compile features
-- Detecting CXX compile features - done
-- Looking for pthread.h
-- Looking for pthread.h - found
-- Performing Test CMAKE_HAVE_LIBC_PTHREAD
-- Performing Test CMAKE_HAVE_LIBC_PTHREAD - Failed
-- Looking for pthread_create in pthreads
-- Looking for pthread_create in pthreads - not found
-- Looking for pthread_create in pthread
-- Looking for pthread_create in pthread - found
-- Found Threads: TRUE
-- Found OpenSSL: /usr/lib/x86_64-linux-gnu/libcrypto.so (found version "1.1.1f")
-- Found Boost: /usr/lib/x86_64-linux-gnu/cmake/Boost-1.71.0/BoostConfig.cmake (found version "1.71.0") found components: program_options system thread random
-- AUTOBAHN_BUILD_EXAMPLES: ON
-- AUTOBAHN_USE_LIBCXX: ON
-- CMAKE_ROOT: /snap/cmake/876/share/cmake-3.20
-- CMAKE_INSTALL_PREFIX: /usr/local
-- Boost_INCLUDE_DIRS: /usr/include
-- Boost_LIBRARIES: Boost::program_optionsBoost::systemBoost::threadBoost::random
-- msgpack_INCLUDE_DIRS:
-- msgpack_LIBRARIES:
-- websocketpp_INCLUDE_DIRS:
-- websocketpp_LIBRARIES:
-- Configuring done
-- Generating done
-- Build files have been written to: /home/atimin/Projects/AnomalyDetectionTrainer/core/cmake-build-debug/_deps/autobahn-src/build
yes, this is raised from here https://github.com/crossbario/autobahn-python/blob/fd5530cecff0be210b148bddf1e984ed31d2863c/autobahn/wamp/serializer.py#L276
and this is trying to deserialize in python msgpack from wire bytes .. and that fails with some low level msgpack serialization/deserialization issue. since you have JS working as well, I would first suspect msgpack on c++ side is going wrong somehow ...
Yep, that was the reason. I've reinstalled msgpack from sources and it's working now. Thank you fro your help!
great, glad it works for you now!
Hello, everyone :wave:
I'm trying to use C++ to call a WAMP procedure, but faced a problem. I can't join a WAMP session.
This is a debug log on the client side:
this is the error message on the router side:
Crossbar.io srotuer configuration:
I'm using crossbar.io router from the last Docker image and autobahn from master branch.
The full code of my program:
I also tried the Python and JS clients, they work perfectly. Unfortunately (or fortunately :slightly_smiling_face: ) , we need C++ client and I'd appreciate your help.