respite/README.md
Pat Garrity 87a6fd5398
All checks were successful
/ Build and Release Application (push) Successful in 2m28s
Baseline project from which to work.
2026-05-11 21:28:06 -05:00

68 lines
2.2 KiB
Markdown

# respite
> _respite_
> An interruption in the intensity or amount of something.
This project is a way to disrupt the stress. It is also an in-memory key/value
store.
## At a Glance
- Single instance (no clustered mode)
- Concurrency support and atomic operations
- No Schema
- No Pub/Sub
- Supports specific types
- Supports key and value constraints
- HTTP API
### Supported Key Types
The sizes below omit the size of heap references (64 bits).
| Type | Size in Bytes | Description |
| -------- | ------------- | ---------------------- |
| `int64` | `8` | Signed 64-bit integer. |
| `string` | Variable | UTF-16 |
| `uuid` | `16` | N/A |
| `date` | `8` | Year, month, day. |
### Supported Value Types
The sizes below omit the size of heap references (64 bits). Booleans do not have
precisely defined sizes on the JVM, but 1 byte is typical.
| Type | Size in Bytes | Description |
| -------- | ------------- | ---------------------- |
| `int64` | `8` | Signed 64-bit integer. |
| `string` | Variable | UTF-16 |
| `uuid` | `16` | N/A |
| `date` | `8` | Year, month, day. |
| `bool` | `1` | True/false. |
| `byte` | Variable | Any byte array. |
### Supported Operations
- Get
- Set
- Delete
- Increment
- Decrement
- Compare and Swap
- Insert
- Contains
### Supported Constraints
Any of the following constraints may be applied to a single key space. If any
operation on the key space violates a constraint, that operation fails.
| Constraint | Description |
| ------------------- | -------------------------------------------------------------------------- |
| `single_key_type` | Only the given type is accepted for keys. |
| `single_value_type` | Only the given type is accepted for values. |
| `write_once` | Each key may be written exactly once. Deletes and reassignments will fail. |
## HTTP API
Respite provides an HTTP API that uses JSON to transmit data.