I have EmployeeDto
as an Object
, which is not synced with the database.
I want to put EmployeeDto
inside Redis cache. I have gone through an example where I can see database entity is getting cached using Redis cache but how can we store and retrieve non-database entity in Redis cache?
@Getter
@Setter
public class EmployeeDto {
private long employeeId;
private String requestId;
private String timestamp;
private String employeeName;
}