| Commit message (Collapse) | Author | Age |
| |
|
|
|
|
| |
Also, this has refactored the websocket stream test to the new
acutest.h, and includes a much deeper test of fragmentation and
reassembly of websocket streams.
|
| |
|
|
| |
The reqpoll test is now moved into the common req/rep logic.
|
| |
|
|
|
| |
Also, the MONOTONIC_RAW clock on linux is a poor choice for accurate
timing. Use the normal MONOTONIC clock.
|
| | |
|
| | |
|
| | |
|
| | |
|
| | |
|
| | |
|
| | |
|
| | |
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
fixes #1035 Convey is awkward -- consider acutest.h
This represents a rather large effort towards cleaning up our
testing and optional configuration infrastructure.
A separate test library is built by default, which is static, and
includes some useful utilities design to make it easier to write
shorter and more robust (not timing dependent) tests. This also means
that we can cover pretty nearly all the tests (protocols etc.) in
every case, even if the shipped image will be minimized.
Subsystems which are optional can now use a few new macros to configure
what they need see nng_sources_if, nng_headers_if, and nng_defines_if.
This goes a long way to making the distributed CMakefiles a lot simpler.
Additionally, tests for different parts of the tree can now be located
outside of the tests/ tree, so that they can be placed next to the code
that they are testing.
Beyond the enabling work, the work has only begun, but these changes
have resolved the most often failing tests for Darwin in the cloud.
|
| | |
|
| | |
|
| | |
|
| | |
|
| |
|
|
| |
sub0_recv_cb was not calling nni_pollable_raise on sock->recvable.
|
| |
|
|
|
|
|
| |
This also eliminates the enforcement of NNG_OPT_RECVMAXSZ for inproc,
which never really made much sense. This helps inproc go faster.
While here, also clean up the entry point for protocols to support
a drain option, since we don't use that anywhere.
|
| | |
|
| | |
|
| |
|
|
| |
This follow up fixes the test code for above.
|
| | |
|
| | |
|
| | |
|
| |
|
|
|
|
|
|
|
| |
This is a major change, and includes changes to use a polymorphic
stream API for all transports. There have been related bugs fixed
along the way. Additionally the man pages have changed.
The old non-polymorphic APIs are removed now. This is a breaking
change, but the old APIs were never part of any released public API.
|
| | |
|
| | |
|
| |
|
|
|
|
|
|
|
|
|
|
| |
This changes much of the internal API for TCP option handling, and
includes hooks for some of this in various consumers. Note that the
consumers still need to have additional work done to complete them,
which will be part of providing public "raw" TLS and WebSocket APIs.
We would also like to finish addressing the call sites of
nni_tcp_listener_start() that assume the sockaddr is modified --
it would be superior to use the NNG_OPT_LOCADDR option. Thaat will be
addressed in a follow up PR.
|
| |
|
|
|
| |
This also makes some smaller related changes to use the new
nni_type instead of nni_opt_type.
|
| | |
|
| | |
|
| |
|
|
|
|
|
| |
This introduces a basic IPC API, modeled on the TCP API, for direct access.
Only connection options are exposed at present -- we need to add options
for dialers and listeners (and particularly listener settings for
permissions and security attributes.) Documentation is still outstanding,
but a very limited test suite exists.
|
| |
|
|
|
| |
These tests are intended to demonstrate that we are not affected
by the bug described in #821.
|
| |
|
|
| |
fixes #724 set recvmaxsize after listen for tcp.
|
| | |
|
| |
|
|
|
|
|
|
|
|
| |
This change makes embedding nng + nggpp (or other projects depending on
nng) in cmake easier. The header files are moved to a separate include
directory. This also makes installation of the headers easier, and
allows clearer identification of private vs public heade files.
Some additional cleanups were performed by @gedamore, but the main
credit for this change belongs with @gregorburger.
|
| | |
|
| |
|
|
|
|
|
|
|
|
|
| |
This is a significant refactor of the library configuration.
We use the modern package configuration helper, with a template
script that also does the find_package dance for any of our
dependencies.
We also have restructured the code so that most protocols and
transports have their configuration isolated to their own CMakeLists
file, reducing the size of the global CMakeLists file.
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This is the client side only, although the work is structured to
support server applications. The chunked API is for now private,
although the intent to is to make it public for applications who
really want to use it.
Note that chunked transfer encoding puts data through extra copies.
First it copies through the buffering area (because I have to be able
to extract variable length strings from inside the data stream), and then
again to reassemble the chunks into a single unified object.
We do assume that the user wants the entire thing as a single object.
This means that using this to pull unbounded data will just silently
consume all memory. Use caution!
|
| |
|
|
| |
Reported by @TBastiani (with suggested fix). Test validation added.
|
| | |
|
| | |
|
| | |
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
The fix for #715 to address const is still not quite right.
In ISO C, the argv array is just char **. getopt() in POSIX uses
char *const[]. That part is right, but we should then not pass
const char ** in calls. Furthermore, really the optarg should also
not be constified.
This aligns us closer to getopt() and leads to the fewest problems.
This does represent a slight breaking change, but as old code should
still compile and run, we don't think we should bump the API version
for this change. Furthermore, we don't think anyone else is actually
using this API yet.
|
| |
|
|
| |
fixes #709 idhash bug on duplicate add
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This introduces new public APIs for obtaining statistics,
and adds some generic stats for dialers, listeners, pipes, and
sockets. Also added are stats for inproc and pairv1 protocol.
The other protocols and transports will have stats added
incrementally as time goes on.
A simple test program, and man pages are provided for this.
Start by looking at nng_stat(5).
Statistics does have some impact, and they can be disabled by
using the advanced NNG_ENABLE_STATS (setting it to OFF, it's
ON by default) if you need to build a minimized configuration.
|
| |
|
|
|
| |
While here we separate out the dialer and listener options, so
that options for tuning connection are only available for listeners.
|
| |
|
|
|
| |
This adds a couple of new methods, and related documentation
and test cases.
|
| | |
|
| |
|
|
| |
* fixes #634 for tests/tls by explicitly using IPv4 for the "Valid verify works" test
|