Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@sqb/connect

Package Overview
Dependencies
Maintainers
1
Versions
137
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@sqb/connect - npm Package Compare versions

Comparing version 4.9.1 to 4.10.0

7

cjs/client/cursor-stream.js

@@ -10,9 +10,6 @@ "use strict";

class CursorStream extends stream_1.Readable {
_cursor;
_objectMode;
_limit;
_rowNum = -1;
_eof = false;
constructor(cursor, options) {
super(options);
this._rowNum = -1;
this._eof = false;
this._cursor = cursor;

@@ -19,0 +16,0 @@ this._objectMode = options?.objectMode;

@@ -14,16 +14,9 @@ "use strict";

class Cursor extends (0, strict_typed_events_1.TypedEventEmitterClass)(strict_typed_events_1.AsyncEventEmitter) {
_connection;
_fields;
_prefetchRows;
_request;
_intlcur;
_taskQueue = new power_tasks_1.TaskQueue();
_fetchCache = new doublylinked_1.default();
_rowNum = 0;
_fetchedAll = false;
_fetchedRows = 0;
_row;
_cache;
constructor(connection, fields, adapterCursor, request) {
super();
this._taskQueue = new power_tasks_1.TaskQueue();
this._fetchCache = new doublylinked_1.default();
this._rowNum = 0;
this._fetchedAll = false;
this._fetchedRows = 0;
this._connection = connection;

@@ -30,0 +23,0 @@ this._intlcur = adapterCursor;

@@ -5,4 +5,2 @@ "use strict";

class FieldInfoMap {
_obj;
_arr;
constructor() {

@@ -9,0 +7,0 @@ Object.defineProperty(this, '_obj', {

@@ -16,8 +16,5 @@ "use strict";

class SqbClient extends (0, strict_typed_events_1.TypedEventEmitterClass)(strict_typed_events_1.AsyncEventEmitter) {
_adapter;
_pool;
_defaults;
_entities = {};
constructor(config) {
super();
this._entities = {};
if (!(config && typeof config === 'object'))

@@ -24,0 +21,0 @@ throw new TypeError('Configuration object required');

@@ -17,11 +17,8 @@ "use strict";

class SqbConnection extends (0, strict_typed_events_1.TypedEventEmitterClass)(strict_typed_events_1.AsyncEventEmitter) {
client;
_intlcon;
_tasks = new power_tasks_1.TaskQueue();
_options;
_inTransaction = false;
_refCount = 1;
constructor(client, adapterConnection, options) {
super();
this.client = client;
this._tasks = new power_tasks_1.TaskQueue();
this._inTransaction = false;
this._refCount = 1;
this._intlcon = adapterConnection;

@@ -28,0 +25,0 @@ this._options = options || {};

@@ -7,3 +7,2 @@ "use strict";

class BaseEntity {
[orm_const_js_1.REPOSITORY_KEY];
constructor(partial) {

@@ -10,0 +9,0 @@ const fields = entity_decorator_js_1.Entity.getColumnFieldNames(Object.getPrototypeOf(this).constructor);

@@ -14,14 +14,10 @@ "use strict";

class FindCommand {
maxEagerFetch = 100000;
maxSubQueries = 5;
mainEntity;
resultEntity;
converter;
mainAlias = 'T';
resultAlias = 'T';
_joins = [];
_selectColumns = {};
_filter = (0, builder_1.And)();
_sort;
constructor(selectEntity, outputEntity) {
this.maxEagerFetch = 100000;
this.maxSubQueries = 5;
this.mainAlias = 'T';
this.resultAlias = 'T';
this._joins = [];
this._selectColumns = {};
this._filter = (0, builder_1.And)();
this.mainEntity = selectEntity;

@@ -28,0 +24,0 @@ this.resultEntity = outputEntity;

@@ -15,9 +15,6 @@ "use strict";

class RowConverter {
resultType;
parent;
_properties = {};
_propertyKeys;
constructor(resultType, parent) {
this.resultType = resultType;
this.parent = parent;
this._properties = {};
}

@@ -24,0 +21,0 @@ addValueProperty(args) {

@@ -6,5 +6,2 @@ "use strict";

class AssociationNode extends association_js_1.Association {
prior;
next;
conditions;
getFirst() {

@@ -11,0 +8,0 @@ let l = this;

@@ -8,15 +8,2 @@ "use strict";

class Association {
_resolved;
_source; // cached value
_target; // cached value
_sourceKey; // cached value
_targetKey; // cached value
_sourceProperty;
_targetProperty;
name;
source;
target;
sourceKey;
targetKey;
many;
constructor(name, args) {

@@ -23,0 +10,0 @@ this.name = name;

@@ -6,5 +6,2 @@ "use strict";

class LinkChain {
target;
first;
current;
constructor(target, targetKey, sourceKey, many) {

@@ -11,0 +8,0 @@ this.target = target;

@@ -13,5 +13,2 @@ "use strict";

class Repository extends (0, strict_typed_events_1.TypedEventEmitterClass)(strict_typed_events_1.AsyncEventEmitter) {
_executor;
_entity;
_schema;
constructor(entityDef, executor, schema) {

@@ -18,0 +15,0 @@ super();

@@ -6,9 +6,6 @@ import _debug from 'debug';

export class CursorStream extends Readable {
_cursor;
_objectMode;
_limit;
_rowNum = -1;
_eof = false;
constructor(cursor, options) {
super(options);
this._rowNum = -1;
this._eof = false;
this._cursor = cursor;

@@ -15,0 +12,0 @@ this._objectMode = options?.objectMode;

@@ -10,16 +10,9 @@ import _debug from 'debug';

export class Cursor extends TypedEventEmitterClass(AsyncEventEmitter) {
_connection;
_fields;
_prefetchRows;
_request;
_intlcur;
_taskQueue = new TaskQueue();
_fetchCache = new DoublyLinked();
_rowNum = 0;
_fetchedAll = false;
_fetchedRows = 0;
_row;
_cache;
constructor(connection, fields, adapterCursor, request) {
super();
this._taskQueue = new TaskQueue();
this._fetchCache = new DoublyLinked();
this._rowNum = 0;
this._fetchedAll = false;
this._fetchedRows = 0;
this._connection = connection;

@@ -26,0 +19,0 @@ this._intlcur = adapterCursor;

export class FieldInfoMap {
_obj;
_arr;
constructor() {

@@ -5,0 +3,0 @@ Object.defineProperty(this, '_obj', {

@@ -12,8 +12,5 @@ import _debug from 'debug';

export class SqbClient extends TypedEventEmitterClass(AsyncEventEmitter) {
_adapter;
_pool;
_defaults;
_entities = {};
constructor(config) {
super();
this._entities = {};
if (!(config && typeof config === 'object'))

@@ -20,0 +17,0 @@ throw new TypeError('Configuration object required');

@@ -13,11 +13,8 @@ import assert from 'assert';

export class SqbConnection extends TypedEventEmitterClass(AsyncEventEmitter) {
client;
_intlcon;
_tasks = new TaskQueue();
_options;
_inTransaction = false;
_refCount = 1;
constructor(client, adapterConnection, options) {
super();
this.client = client;
this._tasks = new TaskQueue();
this._inTransaction = false;
this._refCount = 1;
this._intlcon = adapterConnection;

@@ -24,0 +21,0 @@ this._options = options || {};

import { Entity } from './decorators/entity.decorator.js';
import { REPOSITORY_KEY } from './orm.const.js';
export class BaseEntity {
[REPOSITORY_KEY];
constructor(partial) {

@@ -6,0 +5,0 @@ const fields = Entity.getColumnFieldNames(Object.getPrototypeOf(this).constructor);

@@ -11,14 +11,10 @@ import { And, In, Param, Select } from '@sqb/builder';

export class FindCommand {
maxEagerFetch = 100000;
maxSubQueries = 5;
mainEntity;
resultEntity;
converter;
mainAlias = 'T';
resultAlias = 'T';
_joins = [];
_selectColumns = {};
_filter = And();
_sort;
constructor(selectEntity, outputEntity) {
this.maxEagerFetch = 100000;
this.maxSubQueries = 5;
this.mainAlias = 'T';
this.resultAlias = 'T';
this._joins = [];
this._selectColumns = {};
this._filter = And();
this.mainEntity = selectEntity;

@@ -25,0 +21,0 @@ this.resultEntity = outputEntity;

@@ -12,9 +12,6 @@ import { DataType } from '@sqb/builder';

export class RowConverter {
resultType;
parent;
_properties = {};
_propertyKeys;
constructor(resultType, parent) {
this.resultType = resultType;
this.parent = parent;
this._properties = {};
}

@@ -21,0 +18,0 @@ addValueProperty(args) {

import { Association } from './association.js';
export class AssociationNode extends Association {
prior;
next;
conditions;
getFirst() {

@@ -7,0 +4,0 @@ let l = this;

@@ -5,15 +5,2 @@ import { camelCase } from 'putil-varhelpers';

export class Association {
_resolved;
_source; // cached value
_target; // cached value
_sourceKey; // cached value
_targetKey; // cached value
_sourceProperty;
_targetProperty;
name;
source;
target;
sourceKey;
targetKey;
many;
constructor(name, args) {

@@ -20,0 +7,0 @@ this.name = name;

import { AssociationNode } from './association-node.js';
export class LinkChain {
target;
first;
current;
constructor(target, targetKey, sourceKey, many) {

@@ -7,0 +4,0 @@ this.target = target;

@@ -10,5 +10,2 @@ import { AsyncEventEmitter, TypedEventEmitterClass } from 'strict-typed-events';

export class Repository extends TypedEventEmitterClass(AsyncEventEmitter) {
_executor;
_entity;
_schema;
constructor(entityDef, executor, schema) {

@@ -15,0 +12,0 @@ super();

{
"name": "@sqb/connect",
"description": "Multi-dialect database connection framework written with TypeScript",
"version": "4.9.1",
"version": "4.10.0",
"author": "Panates",

@@ -16,2 +16,6 @@ "contributors": [

},
"type": "module",
"module": "./esm/index.js",
"main": "./cjs/index.js",
"types": "./types/index.d.ts",
"scripts": {

@@ -34,30 +38,20 @@ "compile": "tsc",

"debug": "^4.3.4",
"lightning-pool": "^4.2.1",
"lightning-pool": "^4.2.2",
"lodash": "^4.17.21",
"power-tasks": "^1.7.0",
"power-tasks": "^1.7.2",
"putil-isplainobject": "^1.1.5",
"putil-merge": "^3.10.3",
"putil-promisify": "^1.10.0",
"putil-merge": "^3.12.1",
"putil-promisify": "^1.10.1",
"putil-varhelpers": "^1.6.5",
"reflect-metadata": "^0.1.13",
"strict-typed-events": "^2.3.1",
"ts-gems": "^2.4.0"
"strict-typed-events": "^2.3.2",
"ts-gems": "^2.5.0"
},
"devDependencies": {
"@types/debug": "^4.1.8",
"@types/lodash": "^4.14.195"
"@types/debug": "^4.1.12",
"@types/lodash": "^4.14.201"
},
"peerDependencies": {
"@sqb/builder": "^4.9.1"
"@sqb/builder": "^4.10.0"
},
"type": "module",
"types": "esm/index.d.ts",
"exports": {
".": {
"require": "./cjs/index.js",
"default": "./esm/index.js"
},
"./cjs": "./cjs/index.js",
"./esm": "./esm/index.js"
},
"engines": {

@@ -64,0 +58,0 @@ "node": ">=16.0",

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