kuzzle 2.16.7 → 2.16.11
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +11 -0
- package/lib/api/controllers/adminController.js +4 -3
- package/lib/api/controllers/authController.js +2 -2
- package/lib/api/request/kuzzleRequest.d.ts +11 -11
- package/lib/api/request/kuzzleRequest.js +34 -48
- package/lib/cluster/workers/IDCardRenewer.js +11 -2
- package/lib/config/default.config.d.ts +13 -0
- package/lib/config/default.config.js +363 -362
- package/lib/config/index.js +7 -5
- package/lib/core/backend/backendConfig.d.ts +3 -3
- package/lib/core/backend/backendConfig.js +2 -2
- package/lib/core/network/protocols/httpwsProtocol.js +4 -0
- package/lib/core/plugin/pluginContext.d.ts +10 -1
- package/lib/core/plugin/pluginContext.js +2 -0
- package/lib/core/security/securityLoader.js +1 -1
- package/lib/core/security/tokenRepository.js +7 -10
- package/lib/core/shared/repository.js +1 -1
- package/lib/model/security/profile.js +10 -10
- package/lib/model/security/role.js +3 -3
- package/lib/service/cache/redis.js +33 -0
- package/lib/types/InternalLogger.d.ts +25 -0
- package/lib/types/InternalLogger.js +23 -0
- package/lib/types/PasswordPolicy.d.ts +77 -0
- package/lib/types/PasswordPolicy.js +3 -0
- package/lib/types/ProfileDefinition.d.ts +48 -0
- package/lib/types/ProfileDefinition.js +3 -0
- package/lib/types/RoleDefinition.d.ts +27 -0
- package/lib/types/RoleDefinition.js +3 -0
- package/lib/types/config/DumpConfiguration.d.ts +42 -0
- package/lib/types/config/DumpConfiguration.js +3 -0
- package/lib/types/config/HttpConfiguration.d.ts +43 -0
- package/lib/types/config/HttpConfiguration.js +9 -0
- package/lib/types/config/KuzzleConfiguration.d.ts +123 -0
- package/lib/types/config/KuzzleConfiguration.js +3 -0
- package/lib/types/config/LimitsConfiguration.d.ts +111 -0
- package/lib/types/config/LimitsConfiguration.js +3 -0
- package/lib/types/config/PluginsConfiguration.d.ts +177 -0
- package/lib/types/config/PluginsConfiguration.js +3 -0
- package/lib/types/config/SecurityConfiguration.d.ts +182 -0
- package/lib/types/config/SecurityConfiguration.js +3 -0
- package/lib/types/config/ServerConfiguration.d.ts +195 -0
- package/lib/types/config/ServerConfiguration.js +3 -0
- package/lib/types/config/ServicesConfiguration.d.ts +41 -0
- package/lib/types/config/ServicesConfiguration.js +3 -0
- package/lib/types/config/StorageService/StorageServiceElasticsearchConfiguration.d.ts +217 -0
- package/lib/types/config/StorageService/StorageServiceElasticsearchConfiguration.js +3 -0
- package/lib/types/config/internalCache/InternalCacheRedisConfiguration.d.ts +111 -0
- package/lib/types/config/internalCache/InternalCacheRedisConfiguration.js +3 -0
- package/lib/types/config/publicCache/PublicCacheRedisConfiguration.d.ts +31 -0
- package/lib/types/config/publicCache/PublicCacheRedisConfiguration.js +3 -0
- package/lib/types/index.d.ts +17 -0
- package/lib/types/index.js +17 -0
- package/package-lock.json +367 -377
- package/package.json +20 -19
|
@@ -0,0 +1,195 @@
|
|
|
1
|
+
import { JSONObject } from '../../../index';
|
|
2
|
+
export declare type ServerConfiguration = {
|
|
3
|
+
/**
|
|
4
|
+
* The maximum size of an incoming request.
|
|
5
|
+
*
|
|
6
|
+
* Units can be expressed in bytes ("b" or none), kilobytes ("kb"),
|
|
7
|
+
* megabytes ("mb"), gigabytes ("gb") or terabytes ("tb").
|
|
8
|
+
*
|
|
9
|
+
* @default "1mb"
|
|
10
|
+
*/
|
|
11
|
+
maxRequestSize: string;
|
|
12
|
+
/**
|
|
13
|
+
* The listening port for HTTP and WebSocket protocols.
|
|
14
|
+
*
|
|
15
|
+
* @default 7512
|
|
16
|
+
*/
|
|
17
|
+
port: number;
|
|
18
|
+
/**
|
|
19
|
+
* Configuration section for Kuzzle access logs.
|
|
20
|
+
*/
|
|
21
|
+
logs: {
|
|
22
|
+
/**
|
|
23
|
+
* An array of Winston transports configurations to output access
|
|
24
|
+
* logs.
|
|
25
|
+
*
|
|
26
|
+
* Possible transport types are: console, file, elasticsearch and syslog.
|
|
27
|
+
*
|
|
28
|
+
* Please refer to https://github.com/winstonjs/winston/blob/master/docs/transports.md
|
|
29
|
+
* for more information on transports configuration.
|
|
30
|
+
*
|
|
31
|
+
* @default
|
|
32
|
+
*
|
|
33
|
+
* [
|
|
34
|
+
{
|
|
35
|
+
transport: 'console',
|
|
36
|
+
level: 'info',
|
|
37
|
+
stderrLevels: [],
|
|
38
|
+
silent: true
|
|
39
|
+
}
|
|
40
|
+
]
|
|
41
|
+
*
|
|
42
|
+
*/
|
|
43
|
+
transports: JSONObject[];
|
|
44
|
+
/**
|
|
45
|
+
* Access log format.
|
|
46
|
+
*
|
|
47
|
+
* Currently supported are "combined" (=Apache combined logs format)
|
|
48
|
+
* and "logstash".
|
|
49
|
+
*
|
|
50
|
+
* "logstash" will output the whole request input to JSON, ready to
|
|
51
|
+
* be consumed by logstash agent.
|
|
52
|
+
*
|
|
53
|
+
* @default "combined"
|
|
54
|
+
*/
|
|
55
|
+
accessLogFormat: 'combined' | 'logstash';
|
|
56
|
+
/**
|
|
57
|
+
* The offset to use as the client ip, from the FORWARDED-FOR chain,
|
|
58
|
+
* beginning from the right (0 = the ip address of the last
|
|
59
|
+
* client|proxy which connected to Kuzzle.
|
|
60
|
+
*
|
|
61
|
+
* @default 0
|
|
62
|
+
*/
|
|
63
|
+
accessLogIpOffset: number;
|
|
64
|
+
};
|
|
65
|
+
/**
|
|
66
|
+
* protocols accepted by Kuzzle.
|
|
67
|
+
* protocols can be extended and configured in this section.
|
|
68
|
+
*/
|
|
69
|
+
protocols: {
|
|
70
|
+
http: {
|
|
71
|
+
/**
|
|
72
|
+
* Enable support for compressed requests, using the Content-Encoding header
|
|
73
|
+
* Currently supported compression algorithms: gzip, deflate, identity
|
|
74
|
+
* Note: "identity" is always an accepted value, even if compression support is disabled
|
|
75
|
+
*
|
|
76
|
+
* @default true
|
|
77
|
+
*/
|
|
78
|
+
allowCompression: boolean;
|
|
79
|
+
/**
|
|
80
|
+
* Set to "false" to disable HTTP support
|
|
81
|
+
*
|
|
82
|
+
* @default true
|
|
83
|
+
*/
|
|
84
|
+
enabled: boolean;
|
|
85
|
+
/**
|
|
86
|
+
* Maximum number of encoding layers that can be applied to an http message, using the Content-Encoding header.
|
|
87
|
+
* This parameter is meant to prevent abuses by setting an abnormally large number
|
|
88
|
+
* of encodings, forcing Kuzzle to allocate as many decoders to handle the incoming request.
|
|
89
|
+
*
|
|
90
|
+
* @default 3
|
|
91
|
+
*/
|
|
92
|
+
maxEncodingLayers: number;
|
|
93
|
+
/**
|
|
94
|
+
* Maximum size of requests sent via http forms
|
|
95
|
+
*
|
|
96
|
+
* @default "1MB"
|
|
97
|
+
*/
|
|
98
|
+
maxFormFileSize: string;
|
|
99
|
+
};
|
|
100
|
+
mqtt: {
|
|
101
|
+
/**
|
|
102
|
+
* Set to true to enable MQTT support
|
|
103
|
+
*
|
|
104
|
+
* @default false
|
|
105
|
+
*/
|
|
106
|
+
enabled: boolean;
|
|
107
|
+
/**
|
|
108
|
+
* Allow MQTT pub/sub capabilities or restrict to Kuzzle requests only
|
|
109
|
+
*
|
|
110
|
+
* @default false
|
|
111
|
+
*/
|
|
112
|
+
allowPubSub: boolean;
|
|
113
|
+
/**
|
|
114
|
+
* Switches responseTopic back to a regular public topic
|
|
115
|
+
*
|
|
116
|
+
* @default false
|
|
117
|
+
*/
|
|
118
|
+
developmentMode: boolean;
|
|
119
|
+
/**
|
|
120
|
+
* Delay in ms to apply between a disconnection notification is
|
|
121
|
+
* received and the connection is actually removed
|
|
122
|
+
*
|
|
123
|
+
* @default 250
|
|
124
|
+
*/
|
|
125
|
+
disconnectDelay: number;
|
|
126
|
+
/**
|
|
127
|
+
* Name of the topic listened by the plugin for requests
|
|
128
|
+
*
|
|
129
|
+
* @default 'Kuzzle/request'
|
|
130
|
+
*/
|
|
131
|
+
requestTopic: string;
|
|
132
|
+
/**
|
|
133
|
+
* Name of the topic clients should listen to get requests result
|
|
134
|
+
*
|
|
135
|
+
* @default 'Kuzzle/response'
|
|
136
|
+
*/
|
|
137
|
+
responseTopic: string;
|
|
138
|
+
/**
|
|
139
|
+
* Constructor options passed to underlying MQTT server.
|
|
140
|
+
* See aedes documentation for further reference: https://github.com/moscajs/aedes
|
|
141
|
+
*/
|
|
142
|
+
server: {
|
|
143
|
+
/**
|
|
144
|
+
* @default 1883
|
|
145
|
+
*/
|
|
146
|
+
port: number;
|
|
147
|
+
};
|
|
148
|
+
/**
|
|
149
|
+
* Set to "true" to enable realtime notifications like "TokenExpired" notifications
|
|
150
|
+
*
|
|
151
|
+
* @default true
|
|
152
|
+
*/
|
|
153
|
+
realtimeNotifications: boolean;
|
|
154
|
+
};
|
|
155
|
+
websocket: {
|
|
156
|
+
/**
|
|
157
|
+
* Set to true to enable WebSocket support
|
|
158
|
+
*
|
|
159
|
+
* @default true
|
|
160
|
+
*/
|
|
161
|
+
enabled: boolean;
|
|
162
|
+
/**
|
|
163
|
+
* The maximum time (in milliseconds) without sending or receiving a message from a client.
|
|
164
|
+
* Once reached, the client's socket is forcibly closed.
|
|
165
|
+
* If a client socket is inactive for too long, the server will send a PING request before closing the socket.
|
|
166
|
+
* Minimum value: 1000 (but it's strongly advised to not set a value this low to forcibly close idle client sockets)
|
|
167
|
+
*
|
|
168
|
+
* @default 60000
|
|
169
|
+
*/
|
|
170
|
+
idleTimeout: number;
|
|
171
|
+
/**
|
|
172
|
+
* Enable/Disable per message compression
|
|
173
|
+
*
|
|
174
|
+
* @default false
|
|
175
|
+
*/
|
|
176
|
+
compression: boolean;
|
|
177
|
+
/**
|
|
178
|
+
* The maximum number of messages per second a single socket can
|
|
179
|
+
* submit to the server.
|
|
180
|
+
* @default 0
|
|
181
|
+
*/
|
|
182
|
+
rateLimit: number;
|
|
183
|
+
/**
|
|
184
|
+
* Set to "true" to enable realtime notifications like "TokenExpired" notifications
|
|
185
|
+
*
|
|
186
|
+
* @default true
|
|
187
|
+
*/
|
|
188
|
+
realtimeNotifications: boolean;
|
|
189
|
+
};
|
|
190
|
+
};
|
|
191
|
+
/**
|
|
192
|
+
* @default true
|
|
193
|
+
*/
|
|
194
|
+
strictSdkVersion: boolean;
|
|
195
|
+
};
|
|
@@ -0,0 +1,41 @@
|
|
|
1
|
+
import { PublicCacheRedisConfiguration, InternalCacheConfiguration, StorageServiceElasticsearch } from '../index';
|
|
2
|
+
export declare type ServicesConfiguration = {
|
|
3
|
+
common: {
|
|
4
|
+
/**
|
|
5
|
+
* Time in ms after which a service is considered failing if
|
|
6
|
+
* it has not init.
|
|
7
|
+
*
|
|
8
|
+
* @default 120000
|
|
9
|
+
*/
|
|
10
|
+
defaultInitTimeout: number;
|
|
11
|
+
/**
|
|
12
|
+
* Default interval in ms between Kuzzle tries to init
|
|
13
|
+
* the service again on first failure.
|
|
14
|
+
*
|
|
15
|
+
* @default 1000
|
|
16
|
+
*/
|
|
17
|
+
retryInterval: number;
|
|
18
|
+
};
|
|
19
|
+
/**
|
|
20
|
+
* The database engine used for Kuzzle internal index
|
|
21
|
+
*/
|
|
22
|
+
internalCache: InternalCacheConfiguration;
|
|
23
|
+
memoryStorage: PublicCacheRedisConfiguration;
|
|
24
|
+
/**
|
|
25
|
+
* The database engine used for Kuzzle internal index
|
|
26
|
+
*/
|
|
27
|
+
internalIndex: {
|
|
28
|
+
/**
|
|
29
|
+
* Maximum amount of time (in milliseconds)
|
|
30
|
+
* to wait for a concurrent database bootstrap
|
|
31
|
+
*
|
|
32
|
+
* @default 60000
|
|
33
|
+
*/
|
|
34
|
+
bootstrapLockTimeout: number;
|
|
35
|
+
};
|
|
36
|
+
/**
|
|
37
|
+
* The default storage layer is Elasticsearch and it is
|
|
38
|
+
* currently the only storage layer we support.
|
|
39
|
+
*/
|
|
40
|
+
storageEngine: StorageServiceElasticsearch;
|
|
41
|
+
};
|
|
@@ -0,0 +1,217 @@
|
|
|
1
|
+
import { JSONObject } from '../../../../index';
|
|
2
|
+
export declare type StorageServiceElasticsearch = {
|
|
3
|
+
/**
|
|
4
|
+
* @default ['storageEngine']
|
|
5
|
+
*/
|
|
6
|
+
aliases: string[];
|
|
7
|
+
/**
|
|
8
|
+
* @default "elasticsearch"
|
|
9
|
+
*/
|
|
10
|
+
backend: 'elasticsearch';
|
|
11
|
+
/**
|
|
12
|
+
* Elasticsearch constructor options. Use this field to specify your
|
|
13
|
+
* Elasticsearch config options, this object is passed through to the
|
|
14
|
+
* Elasticsearch constructor and can contain all options/keys outlined here:
|
|
15
|
+
* @see https://www.elastic.co/guide/en/elasticsearch/client/javascript-api/current/client-configuration.html
|
|
16
|
+
*
|
|
17
|
+
*/
|
|
18
|
+
client: JSONObject;
|
|
19
|
+
/**
|
|
20
|
+
* Default policy against new fields that are not referenced in the
|
|
21
|
+
* collection mapping.
|
|
22
|
+
* The value of this configuration will change Elasticsearch behavior
|
|
23
|
+
* on fields that are not declared in the collection mapping.
|
|
24
|
+
* - "true": Stores document and update the collection mapping with
|
|
25
|
+
* inferred type
|
|
26
|
+
* - "false": Stores document and does not update the collection
|
|
27
|
+
* mapping (field are not indexed)
|
|
28
|
+
* - "strict": Rejects document
|
|
29
|
+
* @see https://www.elastic.co/guide/en/elasticsearch/reference/7.4/dynamic-mapping.html
|
|
30
|
+
*/
|
|
31
|
+
commonMapping: {
|
|
32
|
+
/**
|
|
33
|
+
* @default "false"
|
|
34
|
+
*/
|
|
35
|
+
dynamic: 'true' | 'false' | 'strict';
|
|
36
|
+
properties: {
|
|
37
|
+
_kuzzle_info: {
|
|
38
|
+
properties: {
|
|
39
|
+
/**
|
|
40
|
+
* @default
|
|
41
|
+
*
|
|
42
|
+
* [
|
|
43
|
+
* {
|
|
44
|
+
* type: 'keyword',
|
|
45
|
+
* }
|
|
46
|
+
* ]
|
|
47
|
+
*/
|
|
48
|
+
author: {
|
|
49
|
+
type: string;
|
|
50
|
+
};
|
|
51
|
+
/**
|
|
52
|
+
* @default
|
|
53
|
+
*
|
|
54
|
+
* [
|
|
55
|
+
* {
|
|
56
|
+
* type: 'date',
|
|
57
|
+
* }
|
|
58
|
+
* ]
|
|
59
|
+
*/
|
|
60
|
+
createdAt: {
|
|
61
|
+
type: string;
|
|
62
|
+
};
|
|
63
|
+
/**
|
|
64
|
+
* @default
|
|
65
|
+
*
|
|
66
|
+
* [
|
|
67
|
+
* {
|
|
68
|
+
* type: 'keyword',
|
|
69
|
+
* }
|
|
70
|
+
* ]
|
|
71
|
+
*/
|
|
72
|
+
updater: {
|
|
73
|
+
type: string;
|
|
74
|
+
};
|
|
75
|
+
/**
|
|
76
|
+
* @default
|
|
77
|
+
*
|
|
78
|
+
* [
|
|
79
|
+
* {
|
|
80
|
+
* type: 'date',
|
|
81
|
+
* }
|
|
82
|
+
* ]
|
|
83
|
+
*/
|
|
84
|
+
updatedAt: {
|
|
85
|
+
type: string;
|
|
86
|
+
};
|
|
87
|
+
};
|
|
88
|
+
};
|
|
89
|
+
};
|
|
90
|
+
};
|
|
91
|
+
internalIndex: {
|
|
92
|
+
/**
|
|
93
|
+
* @default "kuzzle"
|
|
94
|
+
*/
|
|
95
|
+
name: string;
|
|
96
|
+
collections: {
|
|
97
|
+
users: {
|
|
98
|
+
/**
|
|
99
|
+
* @default 'false'
|
|
100
|
+
*/
|
|
101
|
+
dynamic: 'true' | 'false' | 'strict';
|
|
102
|
+
properties: {
|
|
103
|
+
/**
|
|
104
|
+
* @default
|
|
105
|
+
*
|
|
106
|
+
* [
|
|
107
|
+
* {
|
|
108
|
+
* type: 'keyword',
|
|
109
|
+
* }
|
|
110
|
+
* ]
|
|
111
|
+
*/
|
|
112
|
+
profileIds: {
|
|
113
|
+
type: string;
|
|
114
|
+
};
|
|
115
|
+
};
|
|
116
|
+
};
|
|
117
|
+
profiles: {
|
|
118
|
+
dynamic: 'false';
|
|
119
|
+
properties: {
|
|
120
|
+
tags: {
|
|
121
|
+
type: 'keyword';
|
|
122
|
+
};
|
|
123
|
+
policies: {
|
|
124
|
+
properties: {
|
|
125
|
+
roleId: {
|
|
126
|
+
type: 'keyword';
|
|
127
|
+
};
|
|
128
|
+
restrictedTo: {
|
|
129
|
+
type: 'nested';
|
|
130
|
+
properties: {
|
|
131
|
+
index: {
|
|
132
|
+
type: 'keyword';
|
|
133
|
+
};
|
|
134
|
+
collections: {
|
|
135
|
+
type: 'keyword';
|
|
136
|
+
};
|
|
137
|
+
};
|
|
138
|
+
};
|
|
139
|
+
};
|
|
140
|
+
};
|
|
141
|
+
};
|
|
142
|
+
};
|
|
143
|
+
roles: {
|
|
144
|
+
dynamic: 'false';
|
|
145
|
+
properties: {
|
|
146
|
+
tags: {
|
|
147
|
+
type: 'keyword';
|
|
148
|
+
};
|
|
149
|
+
controllers: {
|
|
150
|
+
dynamic: 'false';
|
|
151
|
+
properties: Record<string, unknown>;
|
|
152
|
+
};
|
|
153
|
+
};
|
|
154
|
+
};
|
|
155
|
+
validations: {
|
|
156
|
+
properties: {
|
|
157
|
+
index: {
|
|
158
|
+
type: 'keyword';
|
|
159
|
+
};
|
|
160
|
+
collection: {
|
|
161
|
+
type: 'keyword';
|
|
162
|
+
};
|
|
163
|
+
validations: {
|
|
164
|
+
dynamic: 'false';
|
|
165
|
+
properties: Record<string, unknown>;
|
|
166
|
+
};
|
|
167
|
+
};
|
|
168
|
+
};
|
|
169
|
+
config: {
|
|
170
|
+
dynamic: 'false';
|
|
171
|
+
properties: Record<string, unknown>;
|
|
172
|
+
};
|
|
173
|
+
'api-keys': {
|
|
174
|
+
dynamic: 'false';
|
|
175
|
+
properties: {
|
|
176
|
+
userId: {
|
|
177
|
+
type: 'keyword';
|
|
178
|
+
};
|
|
179
|
+
hash: {
|
|
180
|
+
type: 'keyword';
|
|
181
|
+
};
|
|
182
|
+
description: {
|
|
183
|
+
type: 'text';
|
|
184
|
+
};
|
|
185
|
+
expiresAt: {
|
|
186
|
+
type: 'long';
|
|
187
|
+
};
|
|
188
|
+
ttl: {
|
|
189
|
+
type: 'keyword';
|
|
190
|
+
};
|
|
191
|
+
token: {
|
|
192
|
+
type: 'keyword';
|
|
193
|
+
};
|
|
194
|
+
};
|
|
195
|
+
};
|
|
196
|
+
installations: {
|
|
197
|
+
dynamic: 'strict';
|
|
198
|
+
properties: {
|
|
199
|
+
description: {
|
|
200
|
+
type: 'text';
|
|
201
|
+
};
|
|
202
|
+
handler: {
|
|
203
|
+
type: 'text';
|
|
204
|
+
};
|
|
205
|
+
installedAt: {
|
|
206
|
+
type: 'date';
|
|
207
|
+
};
|
|
208
|
+
};
|
|
209
|
+
};
|
|
210
|
+
};
|
|
211
|
+
};
|
|
212
|
+
maxScrollDuration: '1m';
|
|
213
|
+
defaults: {
|
|
214
|
+
onUpdateConflictRetries: 0;
|
|
215
|
+
scrollTTL: '15s';
|
|
216
|
+
};
|
|
217
|
+
};
|
|
@@ -0,0 +1,111 @@
|
|
|
1
|
+
export declare type InternalCacheConfiguration = {
|
|
2
|
+
/**
|
|
3
|
+
* The cache service relies on Redis sample settings for Redis service (see also https://github.com/luin/ioredis)
|
|
4
|
+
*
|
|
5
|
+
* 1. using a single Redis database:
|
|
6
|
+
* * node:
|
|
7
|
+
* * host:
|
|
8
|
+
* The host on which Redis can be reached.
|
|
9
|
+
* Can take an IP address, an URI or a hostname
|
|
10
|
+
* * port:
|
|
11
|
+
* The port on which Redis is running its database:
|
|
12
|
+
* * (optional, deprecated) database:
|
|
13
|
+
* ID of the redis database (default: 0)
|
|
14
|
+
* NOTE: this option is deprecated and will be removed in Kuzzle v3.
|
|
15
|
+
* Use 'options.db' instead. If both options are set, then
|
|
16
|
+
* "options.db" will take precedence.
|
|
17
|
+
* * (optional) options:
|
|
18
|
+
* Redis specific options compatible with IORedis.
|
|
19
|
+
* See Redis client constructor available options:
|
|
20
|
+
* https://github.com/luin/ioredis/blob/master/API.md#new-redisport-host-options
|
|
21
|
+
*
|
|
22
|
+
* 2. using a master/slaves Redis instance with Redis sentinels
|
|
23
|
+
* (cf. http://redis.io/topics/sentinel):
|
|
24
|
+
* * node:
|
|
25
|
+
* * sentinels:
|
|
26
|
+
* array of sentinels instances:
|
|
27
|
+
* * host:
|
|
28
|
+
* Host name/address of the sentinel server
|
|
29
|
+
* Can be an IP address, an URI or a hostname
|
|
30
|
+
* * port:
|
|
31
|
+
* Network port opened by Redis on the sentinel server
|
|
32
|
+
* * name:
|
|
33
|
+
* Group of Redis instances composed of a master and one
|
|
34
|
+
* or more slaves
|
|
35
|
+
* * (optional, deprecated) database:
|
|
36
|
+
* ID of the redis database (default: 0)
|
|
37
|
+
* NOTE: this option is deprecated and will be removed in Kuzzle v3.
|
|
38
|
+
* Use 'options.db' instead. If both options are set, then
|
|
39
|
+
* "options.db" will take precedence.
|
|
40
|
+
* * (optional) options:
|
|
41
|
+
* Redis specific options compatible with IORedis.
|
|
42
|
+
* See Redis client constructor available options:
|
|
43
|
+
* https://github.com/luin/ioredis/blob/master/API.md#redis--eventemitter
|
|
44
|
+
*
|
|
45
|
+
* 3. using a redis cluster (cf. http://redis.io/topics/cluster-spec):
|
|
46
|
+
* * nodes: array of master nodes of the cluster
|
|
47
|
+
* * host:
|
|
48
|
+
* Host name/address of a redis cluster node
|
|
49
|
+
* Can be an IP address, an URI or a hostname
|
|
50
|
+
* * port:
|
|
51
|
+
* Network port opened by the redis cluster node
|
|
52
|
+
* * (optional, deprecated) database:
|
|
53
|
+
* ID of the redis database (default: 0)
|
|
54
|
+
* NOTE: this option is deprecated and will be removed in Kuzzle v3.
|
|
55
|
+
* Use 'options.db' instead. If both options are set, then
|
|
56
|
+
* "options.db" will take precedence.
|
|
57
|
+
* * (optional) options:
|
|
58
|
+
* Redis specific options compatible with IORedis.
|
|
59
|
+
* See Redis client constructor available options:
|
|
60
|
+
* https://github.com/luin/ioredis/blob/master/API.md#new-redisport-host-options
|
|
61
|
+
* * (optional) clusterOptions:
|
|
62
|
+
* Redis Cluster specific options compatible with IORedis.
|
|
63
|
+
* See Redis Cluster client constructor available options:
|
|
64
|
+
* https://github.com/luin/ioredis/blob/master/API.md#new-clusterstartupnodes-options
|
|
65
|
+
* * (optional) overrideDnsLookup:
|
|
66
|
+
* Only available when using a Redis Cluster config.
|
|
67
|
+
* Use with caution: if set to true, it makes Kuzzle skip DNS validation for TLS certificates
|
|
68
|
+
* This is the only way to connect to an AWS Elasticache Cluster with TLS encryption.
|
|
69
|
+
* See: https://github.com/luin/ioredis#special-note-aws-elasticache-clusters-with-tls
|
|
70
|
+
*/
|
|
71
|
+
/**
|
|
72
|
+
* @default 'redis'
|
|
73
|
+
*/
|
|
74
|
+
backend: 'redis';
|
|
75
|
+
clusterOptions: {
|
|
76
|
+
/**
|
|
77
|
+
* @default true
|
|
78
|
+
*/
|
|
79
|
+
enableReadyCheck: boolean;
|
|
80
|
+
};
|
|
81
|
+
/**
|
|
82
|
+
* @default 0
|
|
83
|
+
*/
|
|
84
|
+
database: number;
|
|
85
|
+
node: {
|
|
86
|
+
/**
|
|
87
|
+
* @default "localhost"
|
|
88
|
+
*/
|
|
89
|
+
host: string;
|
|
90
|
+
/**
|
|
91
|
+
* @default 6379
|
|
92
|
+
*/
|
|
93
|
+
port: number;
|
|
94
|
+
};
|
|
95
|
+
/**
|
|
96
|
+
* * (optional) options:
|
|
97
|
+
* Redis specific options compatible with IORedis.
|
|
98
|
+
* See Redis client constructor available options:
|
|
99
|
+
* https://github.com/luin/ioredis/blob/master/API.md#new-redisport-host-options
|
|
100
|
+
*
|
|
101
|
+
*/
|
|
102
|
+
options?: Record<string, unknown>;
|
|
103
|
+
/**
|
|
104
|
+
* Only available when using a Redis Cluster config.
|
|
105
|
+
* Use with caution: if set to true, it makes Kuzzle skip DNS validation for TLS certificates
|
|
106
|
+
* This is the only way to connect to an AWS Elasticache Cluster with TLS encryption.
|
|
107
|
+
* See: https://github.com/luin/ioredis#special-note-aws-elasticache-clusters-with-tls
|
|
108
|
+
* @default false
|
|
109
|
+
*/
|
|
110
|
+
overrideDnsLookup: boolean;
|
|
111
|
+
};
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
export declare type PublicCacheRedisConfiguration = {
|
|
2
|
+
/**
|
|
3
|
+
* @default 'redis'
|
|
4
|
+
*/
|
|
5
|
+
backend: 'redis';
|
|
6
|
+
clusterOptions: {
|
|
7
|
+
/**
|
|
8
|
+
* @default true
|
|
9
|
+
*/
|
|
10
|
+
enableReadyCheck: boolean;
|
|
11
|
+
};
|
|
12
|
+
/**
|
|
13
|
+
* @default 5
|
|
14
|
+
*/
|
|
15
|
+
database: number;
|
|
16
|
+
node: {
|
|
17
|
+
/**
|
|
18
|
+
* @default 'localhost'
|
|
19
|
+
*/
|
|
20
|
+
host: string;
|
|
21
|
+
/**
|
|
22
|
+
* @default 6379
|
|
23
|
+
*/
|
|
24
|
+
port: number;
|
|
25
|
+
};
|
|
26
|
+
options?: Record<string, unknown>;
|
|
27
|
+
/**
|
|
28
|
+
* @default false
|
|
29
|
+
*/
|
|
30
|
+
overrideDnsLookup: boolean;
|
|
31
|
+
};
|
package/lib/types/index.d.ts
CHANGED
|
@@ -8,7 +8,24 @@ export * from './EventHandler';
|
|
|
8
8
|
export * from './User';
|
|
9
9
|
export * from './Token';
|
|
10
10
|
export * from './Global';
|
|
11
|
+
export * from './PasswordPolicy';
|
|
12
|
+
export * from './config/KuzzleConfiguration';
|
|
13
|
+
export * from './config/ServerConfiguration';
|
|
14
|
+
export * from './config/ServicesConfiguration';
|
|
15
|
+
export * from './config/SecurityConfiguration';
|
|
16
|
+
export * from './config/HttpConfiguration';
|
|
17
|
+
export * from './config/PluginsConfiguration';
|
|
18
|
+
export * from './RoleDefinition';
|
|
19
|
+
export * from './ProfileDefinition';
|
|
20
|
+
export * from './Plugin';
|
|
21
|
+
export * from './config/LimitsConfiguration';
|
|
22
|
+
export * from './RoleDefinition';
|
|
23
|
+
export * from './ProfileDefinition';
|
|
11
24
|
export * from './realtime/RealtimeScope';
|
|
12
25
|
export * from './realtime/RealtimeUsers';
|
|
13
26
|
export * from './realtime/RoomList';
|
|
14
27
|
export * from './KuzzleDocument';
|
|
28
|
+
export * from './config/publicCache/PublicCacheRedisConfiguration';
|
|
29
|
+
export * from './config/internalCache/InternalCacheRedisConfiguration';
|
|
30
|
+
export * from './config/StorageService/StorageServiceElasticsearchConfiguration';
|
|
31
|
+
export * from './config/DumpConfiguration';
|
package/lib/types/index.js
CHANGED
|
@@ -40,8 +40,25 @@ __exportStar(require("./EventHandler"), exports);
|
|
|
40
40
|
__exportStar(require("./User"), exports);
|
|
41
41
|
__exportStar(require("./Token"), exports);
|
|
42
42
|
__exportStar(require("./Global"), exports);
|
|
43
|
+
__exportStar(require("./PasswordPolicy"), exports);
|
|
44
|
+
__exportStar(require("./config/KuzzleConfiguration"), exports);
|
|
45
|
+
__exportStar(require("./config/ServerConfiguration"), exports);
|
|
46
|
+
__exportStar(require("./config/ServicesConfiguration"), exports);
|
|
47
|
+
__exportStar(require("./config/SecurityConfiguration"), exports);
|
|
48
|
+
__exportStar(require("./config/HttpConfiguration"), exports);
|
|
49
|
+
__exportStar(require("./config/PluginsConfiguration"), exports);
|
|
50
|
+
__exportStar(require("./RoleDefinition"), exports);
|
|
51
|
+
__exportStar(require("./ProfileDefinition"), exports);
|
|
52
|
+
__exportStar(require("./Plugin"), exports);
|
|
53
|
+
__exportStar(require("./config/LimitsConfiguration"), exports);
|
|
54
|
+
__exportStar(require("./RoleDefinition"), exports);
|
|
55
|
+
__exportStar(require("./ProfileDefinition"), exports);
|
|
43
56
|
__exportStar(require("./realtime/RealtimeScope"), exports);
|
|
44
57
|
__exportStar(require("./realtime/RealtimeUsers"), exports);
|
|
45
58
|
__exportStar(require("./realtime/RoomList"), exports);
|
|
46
59
|
__exportStar(require("./KuzzleDocument"), exports);
|
|
60
|
+
__exportStar(require("./config/publicCache/PublicCacheRedisConfiguration"), exports);
|
|
61
|
+
__exportStar(require("./config/internalCache/InternalCacheRedisConfiguration"), exports);
|
|
62
|
+
__exportStar(require("./config/StorageService/StorageServiceElasticsearchConfiguration"), exports);
|
|
63
|
+
__exportStar(require("./config/DumpConfiguration"), exports);
|
|
47
64
|
//# sourceMappingURL=index.js.map
|