Infinitic is distributed as Maven artifacts through Maven Central. This guide covers installation for both development and production environments.
Prerequisites
Before installing Infinitic, ensure you have:
JDK 17 or higher - Infinitic requires Java 17+
Kotlin or Java project - Infinitic works with both languages
Build tool - Gradle or Maven
Dependencies
Infinitic is organized into several modules. The core modules you’ll need are:
Module Purpose infinitic-clientClient API for starting and managing workflows infinitic-workerWorker runtime for executing services and workflows infinitic-transport-pulsarApache Pulsar transport implementation infinitic-storageStorage implementations (Redis, PostgreSQL, MySQL) infinitic-transport-inMemoryIn-memory transport for testing
Gradle Setup
Configure Gradle with Kotlin DSL
Add Infinitic dependencies to your build.gradle.kts: plugins {
kotlin ( "jvm" ) version "2.1.0"
application
}
repositories {
mavenCentral ()
}
dependencies {
// Core Infinitic dependencies
implementation ( "io.infinitic:infinitic-worker:0.18.2" )
implementation ( "io.infinitic:infinitic-client:0.18.2" )
// Transport (choose one)
implementation ( "io.infinitic:infinitic-transport-pulsar:0.18.2" )
// Storage (choose one or more)
implementation ( "io.infinitic:infinitic-storage:0.18.2" )
// Optional: In-memory transport for testing
testImplementation ( "io.infinitic:infinitic-transport-inMemory:0.18.2" )
// Kotlin coroutines (if using Kotlin)
implementation ( "org.jetbrains.kotlinx:kotlinx-coroutines-core:1.10.1" )
implementation ( "org.jetbrains.kotlinx:kotlinx-coroutines-jdk8:1.10.1" )
// Logging
implementation ( "io.github.oshai:kotlin-logging-jvm:7.0.3" )
implementation ( "org.slf4j:slf4j-simple:2.0.16" )
}
kotlin {
jvmToolchain ( 17 )
}
Make sure you’re using Java 17 or higher via jvmToolchain(17) for compatibility.
Configure Gradle with Groovy DSL
For build.gradle: plugins {
id 'org.jetbrains.kotlin.jvm' version '2.1.0'
id 'application'
}
repositories {
mavenCentral()
}
dependencies {
// Core Infinitic dependencies
implementation 'io.infinitic:infinitic-worker:0.18.2'
implementation 'io.infinitic:infinitic-client:0.18.2'
// Transport
implementation 'io.infinitic:infinitic-transport-pulsar:0.18.2'
// Storage
implementation 'io.infinitic:infinitic-storage:0.18.2'
// Optional: Testing
testImplementation 'io.infinitic:infinitic-transport-inMemory:0.18.2'
// Kotlin coroutines
implementation 'org.jetbrains.kotlinx:kotlinx-coroutines-core:1.10.1'
implementation 'org.jetbrains.kotlinx:kotlinx-coroutines-jdk8:1.10.1'
// Logging
implementation 'io.github.oshai:kotlin-logging-jvm:7.0.3'
implementation 'org.slf4j:slf4j-simple:2.0.16'
}
java {
toolchain {
languageVersion = JavaLanguageVersion . of( 17 )
}
}
Maven Setup
Add Infinitic dependencies to your pom.xml:
< project >
< properties >
< kotlin.version > 2.1.0 </ kotlin.version >
< infinitic.version > 0.18.2 </ infinitic.version >
< maven.compiler.source > 17 </ maven.compiler.source >
< maven.compiler.target > 17 </ maven.compiler.target >
</ properties >
< dependencies >
<!-- Core Infinitic dependencies -->
< dependency >
< groupId > io.infinitic </ groupId >
< artifactId > infinitic-worker </ artifactId >
< version > ${infinitic.version} </ version >
</ dependency >
< dependency >
< groupId > io.infinitic </ groupId >
< artifactId > infinitic-client </ artifactId >
< version > ${infinitic.version} </ version >
</ dependency >
<!-- Transport -->
< dependency >
< groupId > io.infinitic </ groupId >
< artifactId > infinitic-transport-pulsar </ artifactId >
< version > ${infinitic.version} </ version >
</ dependency >
<!-- Storage -->
< dependency >
< groupId > io.infinitic </ groupId >
< artifactId > infinitic-storage </ artifactId >
< version > ${infinitic.version} </ version >
</ dependency >
<!-- Optional: In-memory transport for testing -->
< dependency >
< groupId > io.infinitic </ groupId >
< artifactId > infinitic-transport-inMemory </ artifactId >
< version > ${infinitic.version} </ version >
< scope > test </ scope >
</ dependency >
<!-- Kotlin standard library -->
< dependency >
< groupId > org.jetbrains.kotlin </ groupId >
< artifactId > kotlin-stdlib </ artifactId >
< version > ${kotlin.version} </ version >
</ dependency >
<!-- Kotlin coroutines -->
< dependency >
< groupId > org.jetbrains.kotlinx </ groupId >
< artifactId > kotlinx-coroutines-core </ artifactId >
< version > 1.10.1 </ version >
</ dependency >
< dependency >
< groupId > org.jetbrains.kotlinx </ groupId >
< artifactId > kotlinx-coroutines-jdk8 </ artifactId >
< version > 1.10.1 </ version >
</ dependency >
<!-- Logging -->
< dependency >
< groupId > io.github.oshai </ groupId >
< artifactId > kotlin-logging-jvm </ artifactId >
< version > 7.0.3 </ version >
</ dependency >
< dependency >
< groupId > org.slf4j </ groupId >
< artifactId > slf4j-simple </ artifactId >
< version > 2.0.16 </ version >
</ dependency >
</ dependencies >
< build >
< plugins >
< plugin >
< groupId > org.jetbrains.kotlin </ groupId >
< artifactId > kotlin-maven-plugin </ artifactId >
< version > ${kotlin.version} </ version >
< configuration >
< jvmTarget > 17 </ jvmTarget >
</ configuration >
</ plugin >
</ plugins >
</ build >
</ project >
Ensure Java 17+ is configured via maven.compiler.source and maven.compiler.target.
Snapshot Versions
To use the latest snapshot versions (for testing unreleased features):
repositories {
mavenCentral ()
maven (url = "https://central.sonatype.com/repository/maven-snapshots/" )
}
dependencies {
implementation ( "io.infinitic:infinitic-worker:0.18.2-SNAPSHOT" )
implementation ( "io.infinitic:infinitic-client:0.18.2-SNAPSHOT" )
}
Snapshot versions are unstable and should only be used for development and testing.
Infrastructure Setup
Infinitic requires two external dependencies:
Apache Pulsar (Message Transport)
Infinitic uses Apache Pulsar for reliable message delivery. For development:
# Start Pulsar standalone with Docker
docker run -d \
--name pulsar \
-p 6650:6650 \
-p 8080:8080 \
apachepulsar/pulsar:latest \
bin/pulsar standalone
For production, consider:
Storage (State Persistence)
Infinitic needs storage for workflow state. Supported options:
Redis Fast in-memory storage, great for most use cases. storage :
redis :
host : localhost
port : 6379
PostgreSQL Relational database with ACID guarantees. storage :
postgres :
host : localhost
port : 5432
database : infinitic
username : user
password : pass
MySQL Wide compatibility, good for existing MySQL infrastructure. storage :
mysql :
host : localhost
port : 3306
database : infinitic
username : user
password : pass
Development Setup
For local development, use in-memory storage:
storage :
inMemory :
transport :
pulsar :
brokerServiceUrl : pulsar://localhost:6650
webServiceUrl : http://localhost:8080
tenant : infinitic
namespace : dev
In-memory storage loses all data on restart. Only use it for development and testing.
Configuration
Create an infinitic.yml configuration file:
# Storage configuration
storage :
redis :
host : localhost
port : 6379
# Optional: authentication
# username: myuser
# password: mypass
# Optional: TLS
# ssl: true
# Transport configuration
transport :
pulsar :
brokerServiceUrl : pulsar://localhost:6650
webServiceUrl : http://localhost:8080
tenant : infinitic
namespace : production
# Optional: authentication
# authentication:
# issuerUrl: https://auth.example.com
# privateKey: /path/to/key.pem
# audience: pulsar-audience
# Service configuration
services :
- name : MyService
executor :
class : com.example.MyServiceImpl
concurrency : 10
# Optional: timeouts and retries
# timeout: 60.0
# retry:
# maximumRetries: 3
# Workflow configuration
workflows :
- name : MyWorkflow
executor :
class : com.example.MyWorkflowImpl
concurrency : 10
# State engine configuration
stateEngine :
concurrency : 10
Verify Installation
Create a simple test to verify your setup:
import io.infinitic.clients.InfiniticClient
import io.infinitic.workers.InfiniticWorker
fun main () {
// Test creating a client
val client = InfiniticClient. fromYamlFile ( "infinitic.yml" )
println ( "Client created: ${ client. getName () } " )
client. close ()
// Test creating a worker
val worker = InfiniticWorker. fromYamlFile ( "infinitic.yml" )
println ( "Worker created successfully" )
worker. close ()
println ( "Installation verified!" )
}
Next Steps
Quickstart Guide Build your first workflow in minutes
Configuration Reference Detailed configuration options
Deploy to Production Production deployment best practices
API Reference Complete API documentation
Troubleshooting
Connection Issues
If you can’t connect to Pulsar:
Verify Pulsar is running: docker ps | grep pulsar
Check the broker URL in your config matches Pulsar’s port
Ensure firewall rules allow connections
Storage Issues
If storage connection fails:
Verify your storage service is running
Check credentials and connection strings
Ensure the database/keyspace exists
Version Compatibility
Infinitic 0.18.2 requires:
Java 17 or higher
Kotlin 2.0+ (if using Kotlin)
Apache Pulsar 4.0+ (compatible with 3.x)
Getting Help
If you encounter issues: