Decorative site banner
Project icon

com.io7m.hibiscus

  • About
  • Releases
  • Manual
  • Sources
  • License
  • Issues
Maven Central Version Maven Snapshot Code Coverage

hibiscus


An API specification for simple RPC clients.

Motivation


Many io7m projects implement some form of RPC client. The Hibiscus API is an attempt to define some common interface types so that unrelated projects nevertheless end up with a consistent look and feel across client implementations.

Architecture


architecture

  1. A Configuration is passed to a ClientFactory to produce a Client.
  2. The Client sends ConnectionParameters to the server to log in.
  3. The Server sends back Messages indicating if the login succeeded or failed.
  4. Assuming success, the Client sends Messages to the server to perform operations.
  5. The Server sends Messages in response to Messages.

State


Clients conform to a simple state machine:

state

  1. Clients begin in the DISCONNECTED state.
  2. A Login operation moves the client into the CONNECTING state.
  3. If the login succeeds, the client moves to the CONNECTED state after passing through the CONNECTION_SUCCEEDED state.
  4. If the login fails, the client moves to the DISCONNECTED state after passing through the CONNECTION_FAILED state.

In the CONNECTED state, the client can:

  • Disconnect, moving to the DISCONNECTED state.
  • Send messages, remaining in the CONNECTED state.

A client maintains an internal Transport that performs the actual communication.

Transport


A Transport represents an object that can be used to read and write messages. A Transport exposes the following operations:

  • receive: Read a message from the transport.
  • sendAndForget: Write a message to the transport, potentially discarding any response that might come back.
  • sendAndWait: Write a message to the transport and wait for a response to come back.
  • send: Write a message to the transport but do not wait for a response to come back. The response can be fetched later with receive.

The package includes multiple example transports:

  • EUDP0Transport - A UDP transport
  • ETCP0Transport - A TCP transport
  • EHTTP0Transport - An HTTP transport

Releases & Development Snapshots


Releases


You can subscribe to the atom feed to be notified of project releases.

The most recently released version of the package is 1.0.0.

1.0.0 Release (2024-05-11Z)

  • Initial public release.

The compiled artifacts for the release (and all previous releases) are available on Maven Central.

Maven Modules


<dependency> <group>com.io7m.hibiscus</group> <artifactId>com.io7m.hibiscus.api</artifactId> <version>1.0.0</version> </dependency><dependency> <group>com.io7m.hibiscus</group> <artifactId>com.io7m.hibiscus.examples</artifactId> <version>1.0.0</version> </dependency><dependency> <group>com.io7m.hibiscus</group> <artifactId>com.io7m.hibiscus.tests</artifactId> <version>1.0.0</version> </dependency>

Development Snapshots


At the time of writing, the current unstable development version of the package is 1.0.1-SNAPSHOT.

Development snapshots may be available in the Central Portal Snapshots repository. Snapshots are published to this repository every time the project is built by the project's continuous integration system, but snapshots do expire after around ninety days and so may or may not be available depending on when a build of the package was last triggered.

Manual


This project does not have any user manuals or other documentation beyond what might be present on the page above.

Sources


This project uses Git to manage source code.

Repository: https://www.github.com/io7m-com/hibiscus

$ git clone --recursive https://www.github.com/io7m-com/hibiscus

Issues


This project uses GitHub Issues to track issues.

License


Copyright © 2023 Mark Raynsford <code@io7m.com> https://www.io7m.com Permission to use, copy, modify, and/or distribute this software for any purpose with or without fee is hereby granted, provided that the above copyright notice and this permission notice appear in all copies. THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.

Last Updated 2025-08-09T14:55:57Z