Getting less throughput on spring-boot 2 and lettuce

65 views
Skip to first unread message

j.m.r...@gmail.com

unread,
Jul 16, 2020, 2:49:50 AM7/16/20
to lettuce-redis-client-users

Hi All,

I developed an application with spring-boot 1.5.9, spring-data-redis 1.8.9 and lettuce 4.5.0.FINAL. Redis-server version is 6.0.5 I did performance benchmark on my machine for records (each record size is 40 KB) insertion and the throughout is 2857 records inserted per sec.


I upgraded the application to spring-boot 2.3.1, spring-data-redis 2.3.1 and lettuce 5.3.1.FINAL. Redis-server version is 6.0.5. I didn't change the code to create connection. Just upgraded the spring boot. Now when I do benchmark, the performance is reduced lot. i.e., 1000 records (same 40KB) inserted per second.


Do we need to any configuration change after migrating to latest version?

Refer the code to create connection factory below:

@Bean
public LettuceConnectionFactory lettuceConnectionFactory()
{
    return new LettuceConnectionFactory(hostName, port);
}

@Bean
public RedisTemplate<String, Object> redisTemplate(LettuceConnectionFactory lettuceConnectionFactory) 
{
    RedisTemplate<String, Object> template = new RedisTemplate<>();
    template.setConnectionFactory(lettuceConnectionFactory);
    return template;
}

Regards
Razeed

Gowri Sankar Suryanarayana

unread,
Jul 16, 2020, 10:57:07 AM7/16/20
to j.m.r...@gmail.com, lettuce-redis-client-users
Have you checked if the response times from Redis have changed in the 2nd run?

also, you might have to repeat your tests to reduce (or eliminate) noise caused by other applications using Redis
--
A.S.Gowri Sankar


--
You received this message because you are subscribed to the Google Groups "lettuce-redis-client-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to lettuce-redis-clien...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/lettuce-redis-client-users/6aead6b9-37c3-4e5c-aea7-67e8aa2f0caeo%40googlegroups.com.

j.m.r...@gmail.com

unread,
Jul 16, 2020, 12:00:29 PM7/16/20
to lettuce-redis-client-users
I didn't check latency for single request.
No other application is using redis. 
We are planning to migrate our product from spring boot 1.5.9 to latest version. I am doing this testing to make sure that the performance is not degraded.
In the same machine, If I replace the jar with old version (i.e. 1,5,9 version), achieving 2800 inserts per sec.

Note that i didn;t change anything in business logic.
Reply all
Reply to author
Forward
0 new messages