postgresql-client
Advanced tools
Comparing version 2.8.0 to 2.8.1
@@ -0,1 +1,11 @@ | ||
# v2.8.1 | ||
[2023-10-03] | ||
### Changes | ||
* Updated dependencies ([`51998d4`](https://github.com/panates/postgresql-client/commit/51998d496cc84d721bf267ba29e8dda3c520fea7)) | ||
* Updated dependencies ([`7faed1a`](https://github.com/panates/postgresql-client/commit/7faed1a68149b82399d951df6f0e0f1c54cd1798)) | ||
* Add ability to configure buffer size ([`30d18c6`](https://github.com/panates/postgresql-client/commit/30d18c6afeb3b973eaa640f772ed791ec0707bb0)) | ||
* Minor fix for logging ([`1af9e94`](https://github.com/panates/postgresql-client/commit/1af9e946018e9605882c13a85120793a65c1fada)) | ||
# v2.8.0 | ||
@@ -2,0 +12,0 @@ [2023-09-24] |
@@ -113,26 +113,44 @@ "use strict"; | ||
sendParseMessage(args, cb) { | ||
if (this.listenerCount('debug')) | ||
this.emit('debug', { location: 'PgSocket.sendParseMessage', args }); | ||
this._send(this._frontend.getParseMessage(args), cb); | ||
} | ||
sendBindMessage(args, cb) { | ||
if (this.listenerCount('debug')) | ||
this.emit('debug', { location: 'PgSocket.sendBindMessage', args }); | ||
this._send(this._frontend.getBindMessage(args), cb); | ||
} | ||
sendDescribeMessage(args, cb) { | ||
if (this.listenerCount('debug')) | ||
this.emit('debug', { location: 'PgSocket.sendDescribeMessage', args }); | ||
this._send(this._frontend.getDescribeMessage(args), cb); | ||
} | ||
sendExecuteMessage(args, cb) { | ||
if (this.listenerCount('debug')) | ||
this.emit('debug', { location: 'PgSocket.sendDescribeMessage', args }); | ||
this._send(this._frontend.getExecuteMessage(args), cb); | ||
} | ||
sendCloseMessage(args, cb) { | ||
if (this.listenerCount('debug')) | ||
this.emit('debug', { location: 'PgSocket.sendCloseMessage', args }); | ||
this._send(this._frontend.getCloseMessage(args), cb); | ||
} | ||
sendQueryMessage(sql, cb) { | ||
if (this.listenerCount('debug')) | ||
this.emit('debug', { location: 'PgSocket.sendQueryMessage', sql }); | ||
this._send(this._frontend.getQueryMessage(sql), cb); | ||
} | ||
sendFlushMessage(cb) { | ||
if (this.listenerCount('debug')) | ||
this.emit('debug', { location: 'PgSocket.sendFlushMessage' }); | ||
this._send(this._frontend.getFlushMessage(), cb); | ||
} | ||
sendTerminateMessage(cb) { | ||
if (this.listenerCount('debug')) | ||
this.emit('debug', { location: 'PgSocket.sendTerminateMessage' }); | ||
this._send(this._frontend.getTerminateMessage(), cb); | ||
} | ||
sendSyncMessage() { | ||
if (this.listenerCount('debug')) | ||
this.emit('debug', { location: 'PgSocket.sendSyncMessage' }); | ||
this._send(this._frontend.getSyncMessage()); | ||
@@ -324,3 +342,2 @@ } | ||
if (this._socket && this._socket.writable) { | ||
// console.log('>', JSON.stringify(data)); | ||
this._socket.write(data, cb); | ||
@@ -327,0 +344,0 @@ } |
@@ -107,26 +107,44 @@ import crypto from 'crypto'; | ||
sendParseMessage(args, cb) { | ||
if (this.listenerCount('debug')) | ||
this.emit('debug', { location: 'PgSocket.sendParseMessage', args }); | ||
this._send(this._frontend.getParseMessage(args), cb); | ||
} | ||
sendBindMessage(args, cb) { | ||
if (this.listenerCount('debug')) | ||
this.emit('debug', { location: 'PgSocket.sendBindMessage', args }); | ||
this._send(this._frontend.getBindMessage(args), cb); | ||
} | ||
sendDescribeMessage(args, cb) { | ||
if (this.listenerCount('debug')) | ||
this.emit('debug', { location: 'PgSocket.sendDescribeMessage', args }); | ||
this._send(this._frontend.getDescribeMessage(args), cb); | ||
} | ||
sendExecuteMessage(args, cb) { | ||
if (this.listenerCount('debug')) | ||
this.emit('debug', { location: 'PgSocket.sendDescribeMessage', args }); | ||
this._send(this._frontend.getExecuteMessage(args), cb); | ||
} | ||
sendCloseMessage(args, cb) { | ||
if (this.listenerCount('debug')) | ||
this.emit('debug', { location: 'PgSocket.sendCloseMessage', args }); | ||
this._send(this._frontend.getCloseMessage(args), cb); | ||
} | ||
sendQueryMessage(sql, cb) { | ||
if (this.listenerCount('debug')) | ||
this.emit('debug', { location: 'PgSocket.sendQueryMessage', sql }); | ||
this._send(this._frontend.getQueryMessage(sql), cb); | ||
} | ||
sendFlushMessage(cb) { | ||
if (this.listenerCount('debug')) | ||
this.emit('debug', { location: 'PgSocket.sendFlushMessage' }); | ||
this._send(this._frontend.getFlushMessage(), cb); | ||
} | ||
sendTerminateMessage(cb) { | ||
if (this.listenerCount('debug')) | ||
this.emit('debug', { location: 'PgSocket.sendTerminateMessage' }); | ||
this._send(this._frontend.getTerminateMessage(), cb); | ||
} | ||
sendSyncMessage() { | ||
if (this.listenerCount('debug')) | ||
this.emit('debug', { location: 'PgSocket.sendSyncMessage' }); | ||
this._send(this._frontend.getSyncMessage()); | ||
@@ -318,3 +336,2 @@ } | ||
if (this._socket && this._socket.writable) { | ||
// console.log('>', JSON.stringify(data)); | ||
this._socket.write(data, cb); | ||
@@ -321,0 +338,0 @@ } |
{ | ||
"name": "postgresql-client", | ||
"description": "Enterprise level PostgreSQL client for JavaScript", | ||
"version": "2.8.0", | ||
"version": "2.8.1", | ||
"author": "Panates", | ||
@@ -6,0 +6,0 @@ "contributors": [ |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
407239
9956