couchdb-web-node-plugin 1.0.584 → 1.0.586
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/package.json +1 -1
- package/type.d.ts +38 -37
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "couchdb-web-node-plugin",
|
|
3
|
-
"version": "1.0.
|
|
3
|
+
"version": "1.0.586",
|
|
4
4
|
"description": "A couchdb server, model instance conflict handler, rest api, authentication, session management, schema validator and model relation guarantee for webNode.",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"api",
|
package/type.d.ts
CHANGED
|
@@ -18,7 +18,7 @@ export type ChangesMeta = PouchDB.Core.ChangesMeta;
|
|
|
18
18
|
export type ChangesResponseChange<Type extends Mapping<unknown> = Mapping<unknown>> = PouchDB.Core.ChangesResponseChange<Type>;
|
|
19
19
|
export type ChangesStream<Type extends Mapping<unknown> = Mapping<unknown>> = PouchDB.Core.Changes<Type>;
|
|
20
20
|
export type ChangesStreamOptions = PouchDB.Core.ChangesOptions;
|
|
21
|
-
export type Connection = PouchDB.Database
|
|
21
|
+
export type Connection<Type extends Mapping<unknown> = Mapping<unknown>> = PouchDB.Database<Type>;
|
|
22
22
|
export type Connector = PouchDB.Static;
|
|
23
23
|
export type DatabaseConnectorConfiguration = PouchDB.Configuration.RemoteDatabaseConfiguration;
|
|
24
24
|
export type DatabaseError = PouchDB.Core.Error;
|
|
@@ -218,53 +218,54 @@ export type ConnectorConfiguration = DatabaseConnectorConfiguration & {
|
|
|
218
218
|
timeout: number;
|
|
219
219
|
}) | null;
|
|
220
220
|
};
|
|
221
|
-
export
|
|
222
|
-
|
|
223
|
-
|
|
224
|
-
|
|
225
|
-
|
|
226
|
-
|
|
227
|
-
|
|
228
|
-
|
|
229
|
-
|
|
230
|
-
|
|
231
|
-
|
|
232
|
-
|
|
233
|
-
|
|
234
|
-
|
|
235
|
-
|
|
236
|
-
|
|
237
|
-
|
|
238
|
-
|
|
239
|
-
|
|
240
|
-
|
|
241
|
-
|
|
242
|
-
|
|
243
|
-
|
|
244
|
-
|
|
245
|
-
|
|
246
|
-
|
|
247
|
-
|
|
248
|
-
|
|
249
|
-
|
|
250
|
-
|
|
251
|
-
|
|
252
|
-
password: string;
|
|
253
|
-
};
|
|
221
|
+
export interface CoreConfiguration {
|
|
222
|
+
attachAutoRestarter: boolean;
|
|
223
|
+
backend: {
|
|
224
|
+
configuration: PlainObject;
|
|
225
|
+
prefixes: Array<string>;
|
|
226
|
+
};
|
|
227
|
+
binary: {
|
|
228
|
+
memoryInMegaByte: string;
|
|
229
|
+
nodePath: string;
|
|
230
|
+
runner: Array<Runner>;
|
|
231
|
+
};
|
|
232
|
+
changesStream: ChangesStreamOptions;
|
|
233
|
+
connector: ConnectorConfiguration;
|
|
234
|
+
createGenericFlatIndex: boolean;
|
|
235
|
+
databaseName: string;
|
|
236
|
+
debug: boolean;
|
|
237
|
+
ensureAdminPresence: boolean;
|
|
238
|
+
ensureSecuritySettingsPresence: boolean;
|
|
239
|
+
ensureUserPresence: boolean;
|
|
240
|
+
ignoreNoChangeError: boolean;
|
|
241
|
+
local: boolean;
|
|
242
|
+
maximumRepresentationLength: number;
|
|
243
|
+
maximumRepresentationTryLength: number;
|
|
244
|
+
model: ModelConfiguration;
|
|
245
|
+
path: string;
|
|
246
|
+
security: SecuritySettings;
|
|
247
|
+
skipIDDetermining: boolean;
|
|
248
|
+
url: string;
|
|
249
|
+
user: {
|
|
250
|
+
name: string;
|
|
251
|
+
password: string;
|
|
254
252
|
};
|
|
253
|
+
}
|
|
254
|
+
export type Configuration<ConfigurationType = Mapping<unknown>> = BaseConfiguration<{
|
|
255
|
+
couchdb: CoreConfiguration;
|
|
255
256
|
}> & ConfigurationType;
|
|
256
|
-
export interface CouchDB {
|
|
257
|
+
export interface CouchDB<Type extends Mapping<unknown> = Mapping<unknown>> {
|
|
257
258
|
changesStream: ChangesStream;
|
|
258
|
-
connection: Connection
|
|
259
|
+
connection: Connection<Type>;
|
|
259
260
|
connector: Connector;
|
|
260
261
|
server: {
|
|
261
262
|
process: ChildProcess;
|
|
262
263
|
reject: (value: ProcessCloseReason) => void;
|
|
263
264
|
resolve: (reason: ProcessCloseReason) => void;
|
|
264
265
|
restart: (state: State) => Promise<void>;
|
|
265
|
-
runner: Runner;
|
|
266
266
|
start: (services: Services, configuration: Configuration) => Promise<void>;
|
|
267
267
|
stop: (services: Services, configuration: Configuration) => Promise<void>;
|
|
268
|
+
runner: Runner;
|
|
268
269
|
};
|
|
269
270
|
}
|
|
270
271
|
export type ServicePromises<Type = Mapping<unknown>> = BaseServicePromises<{
|