const User = require('./user.model');
console.log(entity.plain()); // entityData + id
console.log(entity.firstname)); // 'John'
// Disable cache and read all properties
User.findOne({ email: '[email protected]' }, null, null, { cache: false, readAll: true }) console.log(entity.plain()); // entityData + id
console.log(entity.firstname)); // 'John'
// ttl set to "-1" means to not cache for this store
User.findOne({ email: '[email protected]' }, null, null, { ttl: { memory: -1, redis: 300 } }) console.log(entity.plain()); // entityData + id
console.log(entity.firstname)); // 'John'