Socket
Socket
Sign inDemoInstall

iridium

Package Overview
Dependencies
Maintainers
1
Versions
157
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

iridium - npm Package Compare versions

Comparing version 6.0.0 to 6.1.0

0

dist/index.js

@@ -0,0 +0,0 @@ function __export(m) {

//# sourceMappingURL=Aggregate.js.map
//# sourceMappingURL=Cache.js.map

@@ -0,0 +0,0 @@ var MongoDB = require('mongodb');

//# sourceMappingURL=CacheDirector.js.map

@@ -0,0 +0,0 @@ var Bluebird = require('bluebird');

@@ -0,0 +0,0 @@ var Bluebird = require('bluebird');

//# sourceMappingURL=Configuration.js.map

@@ -0,0 +0,0 @@ var Bluebird = require('bluebird');

@@ -0,0 +0,0 @@ var Bluebird = require('bluebird');

@@ -0,0 +0,0 @@ var MongoDB = require('mongodb');

//# sourceMappingURL=General.js.map
//# sourceMappingURL=Hooks.js.map
//# sourceMappingURL=Index.js.map

@@ -0,0 +0,0 @@ var _ = require('lodash');

//# sourceMappingURL=InstanceInterface.js.map
//# sourceMappingURL=Middleware.js.map

@@ -0,0 +0,0 @@ /**

@@ -0,0 +0,0 @@ var MongoDB = require('mongodb');

@@ -0,0 +0,0 @@ var Bluebird = require('bluebird');

@@ -0,0 +0,0 @@ var _ = require('lodash');

@@ -0,0 +0,0 @@ var Skmatc = require('skmatc');

//# sourceMappingURL=ModelInterfaces.js.map
//# sourceMappingURL=ModelOptions.js.map

@@ -0,0 +0,0 @@ var util = require('util');

//# sourceMappingURL=Plugins.js.map
//# sourceMappingURL=Schema.js.map
//# sourceMappingURL=Transforms.js.map

@@ -0,0 +0,0 @@ var MongoDB = require('mongodb');

@@ -0,0 +0,0 @@ var _ = require('lodash');

116

lib/Configuration.ts

@@ -0,1 +1,3 @@

import MongoDB = require('mongodb');
export interface Configuration {

@@ -8,3 +10,117 @@ host?: string;

password?: string;
options?: ConnectionOptions;
[key:string]: any;
}
interface ConnectionOptions {
db?: DatabaseLevelConnectionOptions;
server?: ServerLevelConnectionOptions;
replset?: ReplicasetLevelConnectionOptions;
mongos?: MongosLevelConnectionOptions;
}
interface DatabaseLevelConnectionOptions {
/**
* The write concern for the operation where < 1 is no acknowledgment of write and w >= 1 or w = ‘majority’ acknowledges the write
*/
w?: string | number;
/**
* Set the timeout for waiting for write concern to finish (combines with w option)
*/
wtimeout?: number;
/**
* Write waits for fsync before returning
*/
fsync?: boolean;
/**
* Write waits for journal sync before returning
*/
j?: boolean;
/**
* The preferred read preference (ReadPreference.PRIMARY, ReadPreference.PRIMARY_PREFERRED, ReadPreference.SECONDARY, ReadPreference.SECONDARY_PREFERRED, ReadPreference.NEAREST).
*/
readPreference?: string;
/**
* The tags object {‘loc’:‘ny’} used with the readPreference.
*/
readPreferenceTags?: any;
/**
* Use c++ bson parser.
*/
native_parser?: boolean;
/**
* Force server to create _id fields instead of client.
*/
forceServerObjectId?: boolean;
/**
* Object overriding the basic ObjectID primary key generation.
*/
pkFactory?: any;
/**
* Serialize functions.
*/
serializeFunctions?: boolean;
/**
* Perform operations using raw bson buffers.
*/
raw?: boolean;
/**
* Number of milliseconds between retries.
*/
retryMiliseconds?: number;
/**
* Number of retries off connection.
*/
numberOfRetries?: number;
/**
* Sets a cap on how many operations the driver will buffer up before giving up on getting a working connection, default is -1 which is unlimited.
*/
bufferMaxEntries?: number;
}
interface ServerLevelConnectionOptions extends BasicConnectionOptions {
autoReconnect?: boolean;
}
interface ReplicasetLevelConnectionOptions extends MongosLevelConnectionOptions {
replicaSet?: string;
connectWithNoPrimary?: boolean;
}
interface MongosLevelConnectionOptions extends BasicConnectionOptions {
ha?: boolean;
haInterval?: number;
secondaryAcceptableLatencyMS?: number;
}
interface BasicConnectionOptions {
poolSize?: number;
ssl?: boolean;
sslValidate?: boolean;
sslCA?: Buffer[] | string[];
sslCert?: Buffer | string;
sslKey?: Buffer | string;
sslPass?: Buffer | string;
socketOptions?: {
noDelay?: boolean;
keepAlive?: number;
connectTimeoutMS?: number;
socketTimeoutMS?: number;
}
}

4

lib/Core.ts

@@ -58,3 +58,3 @@ import Bluebird = require('bluebird');

private mongoConnectAsyc = Bluebird.promisify(MongoDB.MongoClient.connect);
private mongoConnectAsyc = Bluebird.promisify<MongoDB.Db, string, any>(MongoDB.MongoClient.connect);

@@ -171,3 +171,3 @@ private _plugins: Plugin[] = [];

if (this._connectPromise) return this._connectPromise;
return this._connectPromise = this.mongoConnectAsyc(this.url);
return this._connectPromise = this.mongoConnectAsyc(this.url, this._config.options);
}).then((db: MongoDB.Db) => {

@@ -174,0 +174,0 @@ return this.onConnecting(db);

{
"name": "iridium",
"version": "6.0.0",
"version": "6.1.0",
"author": "Benjamin Pannell <admin@sierrasoftworks.com>",

@@ -5,0 +5,0 @@ "description": "A custom lightweight ORM for MongoDB designed for power-users",

Sorry, the diff of this file is too big to display

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc