Caching
const users = await userRepository
.createQueryBuilder("user")
.cache(true) // Enable caching
.getMany()const dataSource = new DataSource({
type: "mysql",
host: "localhost",
port: 3306,
username: "test",
password: "test",
database: "test",
cache: {
type: "redis",
options: {
host: "localhost",
port: 6379,
},
},
})Last updated