Skip to content

Self-contained distributed software platform for building stateful, massively real-time streaming applications that run on any Java 8+ VM.

Notifications You must be signed in to change notification settings

swimos/swim-runtime-java

Repository files navigation

Swim Java Runtime

The Swim backend runtime provides a self-contained application server for hosting stateful Web Agents. The runtime provides Web Agent applications with:

  • Compute Scheduling: Each Web Agent runs in a long-lived logical compute process that executes arbitrary application code in response to real-time state changes, scheduled timers, and other system events.
  • State Management: The program state of each agent is preserved locally between operations. Processing latencies are measured in nanoseconds—the time needed to access local memory.
  • Local Persistence: Unused state is transparently persisted to local disks, when available. Web Agents pick up where they left off afte a restart. And vastly more data than fits in main memory can be maintained as agent state.
  • Cache Coherence: Web Agents operate on locally materialized views of remote states. Real-time changes made to one view of a shared state propagate to all other linked views with ping latency. A cache coherent streaming memory model ensures that all views consistently converge to the same state.

Documentation

Runtime

To embed the Swim backend runtime in a Java application, add the swim-runtime library as a dependency of the project.

Gradle

compile group: 'org.swimos', name: 'swim-runtime', version: '4.1.0-SNAPSHOT'

Maven

<dependency>
  <groupId>org.swimos</groupId>
  <artifactId>swim-runtime</artifactId>
  <version>4.1.0-SNAPSHOT</version>
</dependency>

Development

The Swim backend stack runs on any Java 11+ JVM. Depending only on the minimal java.base module, it has no other Java library dependencies.

Build Environment

Install a Java 11+ JDK, such as OpenJDK or GraalVM. The stack is built with Gradle, which can be invoked via the included gradlew script.

Compiling sources

./gradlew compileJava

Running unit tests

./gradlew test

Building API docs

./gradlew :javadoc

Contributing

Take a look at the Contributing Guide to learn about our submission process, coding standards, and more.

About

Self-contained distributed software platform for building stateful, massively real-time streaming applications that run on any Java 8+ VM.

Resources

Stars

Watchers

Forks

Packages

No packages published

Languages