aboutsummaryrefslogtreecommitdiff
path: root/src/core
Commit message (Collapse)AuthorAge
...
* url: add nng_url_resolve_portGarrett D'Amore2024-12-06
| | | | | | This API exists to support tests and similar cases where port 0 is used to choose a dynamic port. Once the port is bound, and an actual value is known, it can be patched in using this API.
* sockfd: check the result of nni_aio_scheduleGarrett D'Amore2024-12-03
| | | | This fixes a possible failure condition on teardown.
* tests: void instead of empty parameter listGarrett D'Amore2024-12-01
|
* tests: convert synch test to NUTS.Garrett D'Amore2024-11-30
| | | | | While here we added a test for nng_cv_wake1 to demonstrate it does not fall afoul of the thundering herd.
* Remove all the get_ptr option accessors.Garrett D'Amore2024-11-24
| | | | | Temporarily we have removed access to the peer alt names, but that was never used and was not tested (it also didn't work with WolfSSL.)
* Remove all the set_ptr option functions.Garrett D'Amore2024-11-24
| | | | | This hopefully ensures that we have good typed functions instead of just passing around pointers blithely.
* Remove the NNG_OPT_IPC_SECURITY_DESCRIPTOR option.Garrett D'Amore2024-11-24
| | | | | | | | This is now replaced with nng_listener_set_security_descriptor and nng_stream_listener_set_security_descriptor functions. We may elect to remove these entirely, but for named pipe users they are probably still quite useful. Moving towards UNIX domain sockets would obsolete this functionality.
* socket: fds can never be negativeGarrett D'Amore2024-11-23
|
* tests: add listener and dialer testsGarrett D'Amore2024-11-23
|
* listener: add listener_create_url and listen_urlGarrett D'Amore2024-11-23
|
* dialers: add nng_dial_url and nng_dialer_create_urlGarrett D'Amore2024-11-23
| | | | | This allows a URL object to be used for dialing, which may be easier than using a string if you already have the URL object.
* Add nni_url_clone_inline.Garrett D'Amore2024-11-23
| | | | | The idea is to allow nng_dialer_create_url() and such to avoid having to reparse a URL that we already have.
* url: add huge url testsGarrett D'Amore2024-11-23
|
* Remove u_rawurl member of URL.Garrett D'Amore2024-11-23
| | | | | This means that most URLs can now be used without any allocations needed. It eliminates some failure paths.
* core: remove NNG_OPT_URL entirelyGarrett D'Amore2024-11-23
|
* dialer/listener: don't allocate before we have a transportGarrett D'Amore2024-11-23
| | | | This permits removal of an extra bit of clean up.
* test: sock_test should not use NNG_OPT_URLGarrett D'Amore2024-11-23
|
* Fix socket:// hostname should be null, and add test caseGarrett D'Amore2024-11-22
|
* Select transport using raw URL string.Garrett D'Amore2024-11-22
| | | | | | This is done so that we can provide transport specific logic for URL parsing later (we're going to want this for ZeroTier for example.)
* Fix leak on bad URLGarrett D'Amore2024-11-22
|
* Introduce nng_listener_get_url and nng_dialer_get_url.Garrett D'Amore2024-11-21
| | | | This is intended to replace NNG_OPT_URL.
* Inline dialer URL.Garrett D'Amore2024-11-21
|
* Collect the bound port as part of the URL at bind time.Garrett D'Amore2024-11-21
| | | | This is a step on cleaning up our logic around NNG_OPT_URL.
* Use 32-bit port numbers.Garrett D'Amore2024-11-21
| | | | | While TCP and UDP port numbers are 16-bits, ZT uses a larger (24-bit) port number.
* Avoid extra allocs for listener url.Garrett D'Amore2024-11-21
|
* Add new nni_url_parse_inline, and add more test cases for coverage.Garrett D'Amore2024-11-18
| | | | The inline parsing will be used internally to avoid some allocations.
* url: Use NNG_EINVAL for parse failuresGarrett D'Amore2024-11-18
|
* Introduce accessors for nng_url struct and make it opaque.Garrett D'Amore2024-11-18
| | | | | This provides safety by ensuring that applications do not depend on the size or layout of nng_url itself.
* Merge internal and external URL APIs. No need forGarrett D'Amore2024-11-18
| | | | the separation of nni_url and nng_url.
* URL refactor part 1.Garrett D'Amore2024-11-18
| | | | | | | This eliminates most (but not all) of the dynamic allocations associated with URL objects. A number of convenience fields on the URL are removed, but we are able to use common buffer for most of the details.
* More url work. Undocument rawurl, and stop using it stats and logs.Garrett D'Amore2024-11-17
| | | | | | | Also expose nng_url_sprintf() for users who need it. This avoids some need to do dynamic memory on some things. Soon the entirety of nng_url will be allocation free in the usual case.
* nni_url_sprintfGarrett D'Amore2024-11-17
|
* URL u_port should be a number not a string.Garrett D'Amore2024-11-17
| | | | | | | | | | | The idea here is to reduce the dynamic allocations used for URLs, and also the back and forth with parsing begin strings and port numbers. We always resolve to a port number, and this is easier for everyone. The real goal in the long term is to eliminate dynamic allocation of the URL fields altogether, but that requires a little more work. This is a step in the right direction.
* intern URL schemeGarrett D'Amore2024-11-17
|
* fix parsing bug in abstract URLsGarrett D'Amore2024-11-17
|
* remove NNG_OPT_SOCKNAME (and socket names altogether)Garrett D'Amore2024-11-17
| | | | | | | | This functionality was provided principally for libnanomsg compatibility. This saves some memory and eliminates some pointless functionality. While here, updated the socket options documentation to remove references to options already removed.
* init test coverage improvementsGarrett D'Amore2024-11-11
|
* refactor initialization/finalizationGarrett D'Amore2024-11-11
| | | | | | | | | Applications must now call nng_init(), but they can supply a set of parameters optionally. The code is now safe for multiple libraries to do this concurrently, meaning nng_fini no longer can race against another instance starting up. The nni_init checks on all public APIs are removed now.
* TLS configuration changed to use discret _set_tls and _get_tls functions.Garrett D'Amore2024-11-09
| | | | This is simpler, and more reliable than using socket options.
* Add zero test for errorGarrett D'Amore2024-11-05
|
* remove nni_plat_println - we have nni_plat_printf which is good enoughGarrett D'Amore2024-11-05
|
* logging: better debug & test logsGarrett D'Amore2024-11-04
| | | | | | Don't emit the log for date change unless we are in debug mode. Emit a newline when starting a new NUTS test. Change the default log level - it was too noisy.
* Socket option handling clean ups for endpoints.Garrett D'Amore2024-11-03
| | | | | | | The framework for saving and replaying socket options was left over, and should not be used. But we do need to send the initial socket options to endpoints when creating them, so we have support for that in a cleaner fashion that does not require memory allocations.
* Remove NNI_TYPE_OPAQUE altogether.Garrett D'Amore2024-11-03
| | | | | | | | This also fixes a couple of minor bugs -- changing the socket name could be incorrect as the termination was not applied properly, and the ZeroTier code got a change -- note that it is only possible in this revised version to pass a single moon ID for ZT orbit. The ZT code is a bit stale, and untested anyway.
* Remove untyped nng_socket_get and nng_socket_set.Garrett D'Amore2024-11-03
|
* Remove untyped nng_dialer_get/set and nng_listener_get/set.Garrett D'Amore2024-11-03
|
* Remove untyped stream option functions.Garrett D'Amore2024-11-03
| | | | | The underlying stream APIs have no need for untyped accessors. Another step on the road to removal of NNI_TYPE_OPAQUE.
* Remove untyped nng_pipe_get, support for untyped sockaddr set.Garrett D'Amore2024-11-03
| | | | This is a step on the path to removing unsafe untyped option accesses.
* Replace NNG_OPT_SUB_SUBSCRIBE/UNSUBSCRIBE with functions.Garrett D'Amore2024-11-03
| | | | | The main purpose is to eliminate the NNI_TYPE_OPAQUE options, by putting these into their own first class, protocol-specific, functions.
* Replace `NNG_OPT_RAW` with `nng_socket_raw`.Garrett D'Amore2024-11-02
| | | | Similar to the other identities, this simplifies code a bit.