Releases: liaoliaots/nestjs-redis
v7.0.0-alpha.3
7.0.0-alpha.3 - 2022-03-11
BREAKING CHANGES ⚠️
- [cluster] flat
options
inClusterClientOptions
v7:
ClusterModule.forRoot({
readyLog: true,
config: {
nodes: [{ host: '127.0.0.1', port: 16380 }],
enableOfflineQueue: true,
enableReadyCheck: true,
scaleReads: 'all',
redisOptions: { password: 'cluster1' }
}
})
v6:
ClusterModule.forRoot({
readyLog: true,
config: {
nodes: [{ host: '127.0.0.1', port: 16380 }],
options: {
enableOfflineQueue: true,
enableReadyCheck: true,
scaleReads: 'all',
redisOptions: { password: 'cluster1' }
}
}
})
Changed
- update interface comments to be more detailed than the pre version
TESTING
- update cluster.utils.spec.ts, e2e test
v7.0.0-rc.1
7.0.0-rc.1 - 2022-03-10
Changed
- remove
redis-errors
from dependencies, use custom errors instead of it - remove unnecessary
test.ts
Fixed
- fix a worker process failed to exit when testing
NOTE: This version is deprecated.
v7.0.0-alpha.2
7.0.0-alpha.2 - 2022-03-10
Fixed
- fix falsy
0
when usingmemoryThreshold
- update messages
- update code comments
v7.0.0-alpha.1
v6.0.0
6.0.0 - 2022-02-20
BREAKING CHANGES ⚠️
-
remove exports for
RedisStatus
andClusterStatus
, those should be used internally (#189) (531af15) -
change default namespace from
Symbol('default')
to'default'
for best readability of the logs. Please note that you shouldn't have multiple client without a namespace, or with the same namespace, otherwise they will get overridden. (#189) (3849b48)
export const DEFAULT_REDIS_NAMESPACE = 'default'; // redis
export const DEFAULT_CLUSTER_NAMESPACE = 'default'; // cluster
Fixed
- use correct approach instead of
instanceof
to prevent some bugs in realms environment (#189) (08d7ede)
Added
- add
isGlobal
option as the second param to control whether the module is global-scoped and set its default value totrue
(#189) (617d204)
// redis
static forRoot(options: RedisModuleOptions = {}, isGlobal = true): DynamicModule;
static forRootAsync(options: RedisModuleAsyncOptions, isGlobal = true): DynamicModule;
// cluster
static forRoot(options: ClusterModuleOptions, isGlobal = true): DynamicModule;
static forRootAsync(options: ClusterModuleAsyncOptions, isGlobal = true): DynamicModule;
Security
- update npm dependencies
Changed
- update project config: ci, template, eslint, package, docker-compose.yml, etc
- update code comments for
checkHealth
- extract common utils
- update messages for health
- update unit tests and e2e tests
- docs: add v5 docs, update README.md, update redis, cluster, health
v5.2.0
v5.1.1
5.1.1 - 2021-11-19
From version 5.1.1, the release information follows the keep a changelog format to maintain a human readable changelog.
Fixed
- fix missing
PromiseSettledResult
, use polyfill instead of it - fix jest does not exit
Changed
- change nodejs version from 16 to 14
- change es version from es2021 to es2017
- update dependencies
- update hooks
- update docs
v5.1.0
What's Changed
New
- support nestjs 7.x
Maintenance
- update docs
- update ci
v5.0.1
v5.0.0
What's Changed
⚠️ BREAKING CHANGES
- The default redis client will not be created if you do not specify the
config
option.
Migration from v4 to v5
If your redis server does not have a password, the host is 127.0.0.1 and the port is 6379:
v4
The default redis client will be created if you do not specify the config
option:
import { Module } from '@nestjs/common';
import { RedisModule } from '@liaoliaots/nestjs-redis';
@Module({
imports: [RedisModule.forRoot()]
})
export class AppModule {}
v5
The default redis client will not be created if you do not specify the config
option, so you have to specify the config
option:
import { Module } from '@nestjs/common';
import { RedisModule } from '@liaoliaots/nestjs-redis';
@Module({
imports: [RedisModule.forRoot({ closeClient: true, config: { host: '127.0.0.1', port: 6379 } })]
})
export class AppModule {}
Documentation
- update readme menu
- update examples
- update redis