From 7db650f985245c3469963b616986848e2e1242e2 Mon Sep 17 00:00:00 2001 From: ExWeiv GitHub BOT Date: Wed, 22 May 2024 23:18:11 +0000 Subject: [PATCH] Build and Generate Docs - BOT --- .../automatic_connection_provider.js | 22 ++++---- app/package-lock.json | 4 +- docs/functions/Hooks.afterCount.html | 4 +- docs/functions/Hooks.afterFindOne.html | 4 +- docs/functions/Hooks.afterGet.html | 4 +- docs/functions/Hooks.afterGetAndRemove.html | 4 +- docs/functions/Hooks.afterGetAndReplace.html | 4 +- docs/functions/Hooks.afterGetAndUpdate.html | 4 +- docs/functions/Hooks.afterIncrement.html | 4 +- docs/functions/Hooks.afterInsert.html | 4 +- docs/functions/Hooks.afterMultiply.html | 4 +- docs/functions/Hooks.afterPull.html | 4 +- docs/functions/Hooks.afterPush.html | 4 +- docs/functions/Hooks.afterQuery.html | 4 +- docs/functions/Hooks.afterRemove.html | 4 +- docs/functions/Hooks.afterReplace.html | 4 +- docs/functions/Hooks.afterUpdate.html | 4 +- docs/functions/Hooks.beforeCount.html | 4 +- docs/functions/Hooks.beforeFindOne.html | 4 +- docs/functions/Hooks.beforeGet.html | 4 +- docs/functions/Hooks.beforeGetAndRemove.html | 4 +- docs/functions/Hooks.beforeGetAndReplace.html | 4 +- docs/functions/Hooks.beforeGetAndUpdate.html | 4 +- docs/functions/Hooks.beforeIncrement.html | 4 +- docs/functions/Hooks.beforeInsert.html | 4 +- docs/functions/Hooks.beforeMultiply.html | 4 +- docs/functions/Hooks.beforePull.html | 4 +- docs/functions/Hooks.beforePush.html | 4 +- docs/functions/Hooks.beforeQuery.html | 4 +- docs/functions/Hooks.beforeRemove.html | 4 +- docs/functions/Hooks.beforeReplace.html | 4 +- docs/functions/Hooks.beforeUpdate.html | 4 +- docs/functions/Hooks.onFailure.html | 4 +- docs/functions/_version.html | 4 +- docs/functions/aggregate.html | 4 +- docs/functions/bulkInsert.html | 4 +- docs/functions/bulkRemove.html | 4 +- docs/functions/bulkSave.html | 4 +- docs/functions/bulkUpdate.html | 4 +- docs/functions/convertId.html | 4 +- docs/functions/createCollection.html | 4 +- docs/functions/deleteCollection.html | 4 +- docs/functions/filter.html | 4 +- docs/functions/findOne.html | 4 +- docs/functions/flushCache.html | 4 +- docs/functions/get.html | 4 +- docs/functions/getAndRemove.html | 4 +- docs/functions/getAndReplace.html | 4 +- docs/functions/getAndUpdate.html | 4 +- docs/functions/increment.html | 4 +- docs/functions/insert.html | 4 +- docs/functions/insertReference.html | 4 +- docs/functions/isReferenced.html | 4 +- docs/functions/listCollections.html | 4 +- docs/functions/multiply.html | 4 +- docs/functions/native.html | 4 +- docs/functions/pull.html | 4 +- docs/functions/push.html | 4 +- docs/functions/query.html | 4 +- docs/functions/queryReferenced.html | 4 +- docs/functions/remove.html | 4 +- docs/functions/removeReference.html | 4 +- docs/functions/renameCollection.html | 4 +- docs/functions/replace.html | 4 +- docs/functions/replaceReferences.html | 4 +- docs/functions/save.html | 4 +- docs/functions/truncate.html | 4 +- docs/functions/update.html | 4 +- docs/index.html | 2 +- .../ConnectionOptionsJS.Options.html | 12 ++-- docs/interfaces/WeivDataAggregate.html | 30 +++++----- docs/interfaces/WeivDataAggregateResult.html | 14 ++--- docs/interfaces/WeivDataFilter.html | 38 ++++++------- docs/interfaces/WeivDataQuery.html | 56 +++++++++---------- .../WeivDataQueryReferencedResult.html | 16 +++--- docs/interfaces/WeivDataQueryResult.html | 28 +++++----- docs/modules.html | 2 +- docs/modules/ConnectionOptionsJS.html | 4 +- docs/modules/Hooks.html | 4 +- docs/types/BulkInsertResult.html | 4 +- docs/types/BulkRemoveResult.html | 4 +- docs/types/BulkSaveResult.html | 4 +- docs/types/BulkUpdateResult.html | 4 +- docs/types/CacheSelections.html | 4 +- docs/types/CollectionID.html | 4 +- docs/types/Hooks.HookContext.html | 4 +- docs/types/Hooks.HookName.html | 4 +- docs/types/IncludeObject.html | 4 +- docs/types/Item.html | 4 +- docs/types/ItemID.html | 4 +- docs/types/PipelineStage.html | 4 +- docs/types/PipelineStageKey.html | 4 +- docs/types/ReadConcern.html | 4 +- docs/types/ReferencedItem.html | 4 +- docs/types/ReferringItem.html | 4 +- docs/types/SaveResult.html | 4 +- docs/types/WeivDataAggregateRunOptions.html | 4 +- docs/types/WeivDataOptions.html | 4 +- docs/types/WeivDataOptionsCache.html | 4 +- docs/types/WeivDataOptionsOwner.html | 4 +- docs/types/WeivDataOptionsQuery.html | 4 +- docs/types/WeivDataOptionsWrite.html | 4 +- docs/types/WeivDataOptionsWriteOwner.html | 4 +- .../types/WeivDataQueryReferencedOptions.html | 4 +- 104 files changed, 298 insertions(+), 298 deletions(-) diff --git a/app/lib/Connection/automatic_connection_provider.js b/app/lib/Connection/automatic_connection_provider.js index 856b67e9..5d8689fc 100644 --- a/app/lib/Connection/automatic_connection_provider.js +++ b/app/lib/Connection/automatic_connection_provider.js @@ -42,7 +42,7 @@ const createNewClient = async (uri, role) => { manual = true; } const newMongoClient = new mongodb_1.MongoClient(uri, options); - clientCache.set(uri.slice(0, 20), newMongoClient); + clientCache.set(uri.slice(14, 40), newMongoClient); let connection = newMongoClient; if (manual) { connection = await connectClient(newMongoClient, uri); @@ -74,31 +74,31 @@ const createNewClient = async (uri, role) => { const listenersMap = new Map(); const connectClient = async (client, uri) => { try { - const status = statusCache.get(uri.slice(0, 20)); - const cachedClient = clientCache.get(uri.slice(0, 20)); + const status = statusCache.get(uri.slice(14, 40)); + const cachedClient = clientCache.get(uri.slice(14, 40)); if (status === true) { if (cachedClient) { return cachedClient; } } let connectedClient; - if (!listenersMap.has(uri.slice(0, 20))) { + if (!listenersMap.has(uri.slice(14, 40))) { const handleClose = async () => { - clientCache.del(uri.slice(0, 20)); - statusCache.set(uri.slice(0, 20), false); + clientCache.del(uri.slice(14, 40)); + statusCache.set(uri.slice(14, 40), false); }; const handleError = async () => { - clientCache.del(uri.slice(0, 20)); - statusCache.set(uri.slice(0, 20), false); + clientCache.del(uri.slice(14, 40)); + statusCache.set(uri.slice(14, 40), false); throw new Error(`when trying to connect client (connection error): ${uri}`); }; client.on('close', handleClose); client.on('error', handleError); - listenersMap.set(uri.slice(0, 20), true); + listenersMap.set(uri.slice(14, 40), true); } connectedClient = await client.connect(); - clientCache.set(uri.slice(0, 20), connectedClient); - statusCache.set(uri.slice(0, 20), true); + clientCache.set(uri.slice(14, 40), connectedClient); + statusCache.set(uri.slice(14, 40), true); return connectedClient; } catch (err) { diff --git a/app/package-lock.json b/app/package-lock.json index 37a55a87..ac45594d 100644 --- a/app/package-lock.json +++ b/app/package-lock.json @@ -1,12 +1,12 @@ { "name": "@exweiv/weiv-data", - "version": "4.1.3", + "version": "4.1.4", "lockfileVersion": 3, "requires": true, "packages": { "": { "name": "@exweiv/weiv-data", - "version": "4.1.3", + "version": "4.1.4", "license": "Apache-2.0", "dependencies": { "crypto-js": "^4.2.0", diff --git a/docs/functions/Hooks.afterCount.html b/docs/functions/Hooks.afterCount.html index 7b9024e8..2f90dc96 100644 --- a/docs/functions/Hooks.afterCount.html +++ b/docs/functions/Hooks.afterCount.html @@ -3,10 +3,10 @@
  • context: HookContext

    Contextual information about the hook.

  • Returns Promise<number> | number

    The count to return to count() instead of the original count. Returning a rejected promise will not block the operation, but will return a rejected promise to the caller as well as trigger the onFailure() hook.

    Description

    A hook that is triggered after a count() operation.

    -