Package io.sisu.nng.aio

Asynchronous primitives for scaling Java NNG

This package provides all the bindings and logic required for utilizing Sockets in a thread-safe, concurrent fashion through three different APIs:

  • blocking, synchronous calls for receive, send, and sleep events on a Context
  • a CompletableFuture-based asynchronous api for the same
  • a callback-oriented, event-based approach using AioCallback

Concurrency is achieved via the underlying nng library's aio framework meaning you can build highly concurrent applications using only a fraction of Java's concurrency capabilities (like CompletableFutures or CountDownLatches).