Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

vendelieu/re.this

Folders and files

NameName
Last commit message
Last commit date

Latest commit

History

190 Commits

Re.This Logo

Maven Central KDocs
codecov

What is Re.This?

Re.This is a Kotlin Multiplatform Redis client built for coroutine‐based, non‐blocking, high‐performance applications.

  • Raw sockets & connection pooling for rock‐solid throughput
  • ✅ Full support for RESPv2/RESPv3, RedisJSON, Streams, Pub/Sub, and more
  • ✅ Tiny footprint over all targets: JVM, Android, iOS, WASM, Node.js, and other native targets
  • ✅ Сompatible with Valkey/KeyDB — since it shares the same API as Redis.

Designed for modern Kotlin developers seeking a fast, lightweight, and idiomatic Redis integration.

Key Features

  • Complete Command Coverage Strings, Hashes, Lists, Sets, Sorted Sets, Streams, Bitmaps, Geospatial, Transactions, Scripting, Functions, ...
  • Advanced Patterns
    • Pipelining & Transactions DSL
    • Publish/Subscribe with lifecycle management
    • Script & JSON support
  • Multiplatform Targets JVM, Android, iOS, Linux, Windows, macOS, tvOS, watchOS, Node.js, WASM
  • High Performance Optimized for throughput and minimal latency via raw socket I/O

Installation

Add to your build.gradle.kts:

dependencies {
 implementation("eu.vendeli:rethis:0.4.3")
}

Quick Start

suspend fun main() {
 // 1. Initialize client (defaults to localhost:6379)
 val client = ReThis()
 // 2. Simple SET/GET
 client.set("hello", "world")
 println(client.get("hello")) // → "world"
 // 3. Pipeline multiple commands
 val results = client.pipeline {
 set("foo", "bar")
 get("foo")
 }
 println(results) // → [OK, "bar"]
 
 // 4. Transaction
 val txResults = client.transaction {
 set("bar", "baz")
 get("bar")
 }
 println(txResults) // → [OK, "baz"]
 // 5. Pub/Sub example
 client.subscribe("news") { _, msg -> println("Received: $msg") }
}

Benchmarks & Performance

Library Ops/sec
Jedis (pooled) 2,038
Kreds 448
Lettuce 1,747
Rethis 2,171

See more detailed report.

Compatibility & Requirements

  • Java: 17+
  • Redis/Valkey/KeyDB: any modern version (RESPv2/v3)

Resources & Documentation

Acknowledgements

Thanks to all contributors and users—your feedback drives our improvements!

⭐ If you find Re.This helpful, please give it a star on GitHub!

About

Kotlin Multiplatform Redis Client: coroutine-based, DSL-powered, and easy to use.

Topics

Resources

License

Code of conduct

Contributing

Security policy

Stars

Watchers

Forks

Sponsor this project

Packages

Contributors

AltStyle によって変換されたページ (->オリジナル) /