An open API service indexing awesome lists of open source software.

https://github.com/redistimeseries/jredistimeseries

Java Client for RedisTimeSeries
https://github.com/redistimeseries/jredistimeseries

java java-client redis timeseries

Last synced: 3 months ago
JSON representation

Java Client for RedisTimeSeries

Awesome Lists containing this project

README

          

[![license](https://img.shields.io/github/license/RedisTimeSeries/JRedisTimeSeries.svg)](https://github.com/RedisTimeSeries/JRedisTimeSeries)
[![GitHub issues](https://img.shields.io/github/release/RedisTimeSeries/JRedisTimeSeries.svg)](https://github.com/RedisTimeSeries/JRedisTimeSeries/releases/latest)
[![Maven Central](https://maven-badges.herokuapp.com/maven-central/com.redislabs/jredistimeseries/badge.svg)](https://maven-badges.herokuapp.com/maven-central/com.redislabs/jredistimeseries)
[![Javadocs](https://www.javadoc.io/badge/com.redislabs/jredistimeseries.svg)](https://www.javadoc.io/doc/com.redislabs/jredistimeseries)
[![Codecov](https://codecov.io/gh/RedisTimeSeries/JRedisTimeSeries/branch/master/graph/badge.svg)](https://codecov.io/gh/RedisTimeSeries/JRedisTimeSeries)
[![Language grade: Java](https://img.shields.io/lgtm/grade/java/g/RedisTimeSeries/JRedisTimeSeries.svg?logo=lgtm&logoWidth=18)](https://lgtm.com/projects/g/RedisTimeSeries/JRedisTimeSeries/context:java)
[![Known Vulnerabilities](https://snyk.io/test/github/RedisTimeSeries/JRedisTimeSeries/badge.svg?targetFile=pom.xml)](https://snyk.io/test/github/RedisTimeSeries/JRedisTimeSeries?targetFile=pom.xml)

# JRedisTimeSeries
[![Forum](https://img.shields.io/badge/Forum-RedisTimeSeries-blue)](https://forum.redislabs.com/c/modules/redistimeseries)
[![Discord](https://img.shields.io/discord/697882427875393627?style=flat-square)](https://discord.gg/KExRgMb)

Java Client for RedisTimeSeries

## Deprecation notice

As of [Jedis 4.2.0](https://github.com/redis/jedis), this library is deprecated. Its features have been merged into Jedis. Please install it either [from maven](https://mvnrepository.com/artifact/redis.clients/jedis) or [the repo](https://github.com/redis/jedis).

### Official Releases

```xml


com.redislabs
jredistimeseries
1.4.0


```

### Snapshots

```xml


snapshots-repo
https://oss.sonatype.org/content/repositories/snapshots


```

and

```xml


com.redislabs
jredistimeseries
1.5.0-SNAPSHOT


```

# Example: Using the Java Client

```java
RedisTimeSeries rts = new RedisTimeSeries("localhost", 6379);

Map labels = new HashMap<>();
labels.put("country", "US");
labels.put("cores", "8");
rts.create("cpu1", 60*10 /*10min*/, labels);

rts.create("cpu1-avg", 60*10 /*10min*/, null);
rts.createRule("cpu1", Aggregation.AVG, 60 /*1min*/, "cpu1-avg");

rts.add("cpu1", System.currentTimeMillis()/1000 /* time sec */, 80.0);

// Get all the timeseries in US in the last 10min average per min
rts.mrange(System.currentTimeMillis()/1000 - 10*60, System.currentTimeMillis()/1000, Aggregation.AVG, 60, "country=US")
```