Hibernate secondary level cache & Scalability

I’m building cloud native application using spring & hibernate.

Hibernate second level cache effectively reduces the load on the RDB.

But default secondary cache is using replication cache. it is make not effective to scalability.

So I want to use an in-memory database. Is there a good solution for this or a good way to replace the secondary cache?