Brian M. Carlson
bd74d48791
Fix query error emit on native bindings
2014-04-06 12:55:26 -05:00
Brian M. Carlson
876abe8730
Break type parsing into separate module
2014-03-15 15:36:27 -05:00
rpedela
cd4565ba1f
#181 #366 Add support for single row mode in Postgres 9.2+. This will enable single row mode only when the user wants to stream rows.
2013-09-04 11:46:07 -06:00
rpedela
cf07a4f2b4
#403 Only use native escape functions if PG version >= 9.0.0. Otherwise use the JS functions.
2013-07-29 15:45:36 -06:00
Brian Carlson
145666c1b3
Support result rows as arrays
2013-07-08 17:45:06 -05:00
Brian Carlson
413eff72e5
Move row parsing into result object
2013-07-08 09:30:10 -05:00
Brian Carlson
3f96bbbc5c
Add field metadata to query result object
...
Refactored the way rows are built in the native bindings which should
result in a small performance improvement
2013-07-08 09:19:30 -05:00
Brian Carlson
05e9026aea
Remove tab character
2013-07-08 08:16:10 -05:00
Andrey Popp
4458e69285
call EventEmmiter constructor on native Connection
...
this allows to preserve an active domain on switches in libpq
2013-05-20 18:31:55 +04:00
bmc
56a5903a02
Make throws in query error callback not break client
...
If you receive an error while running a query and in user's callback
they throw an exception it can disrupt the internal query queue
and prevent a client from ever cleaning up properly
2013-04-19 09:25:53 -05:00
bmc
9b1c4facc2
Make query callback exceptions not break client
...
If you throw an exception in a query callback the client will not pulse
its internal query queue and therefor will never process any
more queries or emit its own 'drain' event.
I don't find this to be an issue in production code since I restart
the process on exceptions, but it can break tests and cause things
to 'hang'. My crude benchmarks show no noticable impact in perf
from the try/catch/rethrow.
:q
2013-04-19 09:09:28 -05:00
brianc
683d636501
better handling of client stream termination
...
1. Pass an error to an active query if the client is ended while a query is in progress.
2. actually emit 'end' event on the client when the stream ends
3. do not emit an error from native bindings if lasterror is null
2013-03-28 13:24:33 -05:00
brianc
c57eee8661
normalize whitespace, add comments, and do a little house cleaning
2013-03-06 10:26:40 -06:00
brianc
37bb13fc0c
move type conversion related code under sub-folder
2013-03-06 08:57:38 -06:00
brianc
b58ae9e7f7
clean up prototype shorthand
...
For some reason a few years ago I thought it would be neat to use a shorthand version of prototype to save myself some keystrokes. That was a cosmetic mistake. It also breaks ctags.
Also, normalized some whitespace.
2013-03-06 08:48:52 -06:00
Philipp Borgers
bed3de9490
fix jshint erros
2013-01-24 22:03:03 +01:00
Philipp Borgers
0c3e1cba83
fix jshint errors in lib/native/query.js
2013-01-24 22:03:03 +01:00
Philipp Borgers
60a022b0b0
fix jshint errors for lib/native/index.js
2013-01-24 21:59:28 +01:00
Philipp Borgers
2cc91225e3
fix jshint errors for lib/native/query.js
2013-01-24 21:59:28 +01:00
bmc
113b6298e2
use ConnectionParameters with native bindings and remove unused util functions
2013-01-22 23:23:47 -06:00
anton
88d684f925
bugfix. sometimes native copy to loose rows
2013-01-20 19:45:41 -06:00
anton
7ca21acb25
handle situation, when broken copy to query, ends before it is canceled
2013-01-20 19:45:41 -06:00
anton
8ea2f259ed
bugfix: correctly create new connection for canceling copy to query
2013-01-20 19:45:41 -06:00
anton
c5c31143c1
1. behave correctly if copy to/from is send to db by query method (report error in standart way); 2. bugfix and code review in native copy to implementation
2013-01-20 19:45:40 -06:00
anton
8bcd40595d
make copy related events to have same names in native and libpq clients
2013-01-06 12:06:26 -06:00
anton
d2b21aa95e
just comments
2013-01-06 12:06:26 -06:00
anton
c014096e0e
COPY TO/FROM native/libpq done. Looks like it works, but need to test
2013-01-06 12:06:26 -06:00
Stephen Sugden
903e9b25ea
Attach Query constructors to Client constructors
2012-12-16 00:58:30 -06:00
Stephen Sugden
5a91dd0c35
Use normalizeQueryConfig with native driver
2012-12-16 00:58:30 -06:00
brianc
102a069bd2
have native bindings emit proper result object on 'end' event - closes #219
2012-12-10 23:25:26 -06:00
bmc
886926a777
pass result object to native query 'row' event - closes #183
2012-09-09 21:13:36 -05:00
brianc
fa80b4e3fa
make data conversion the same between native & javascript
2012-07-11 22:47:02 -05:00
booo
17e8287bdd
call nativeConnect after defining the error handler/callback
2012-07-06 15:55:10 +02:00
brianc
176e6c7ab2
include command metadata with native query result callback - closes #128
2012-05-30 23:38:03 -05:00
Alexander Sulfrian
070155a577
fix native bindings
...
native bindings need to get the textParsers with the new syntax
2011-11-22 04:53:38 +01:00
Christophe Macabiau
fe6d5aeb68
query cancellation (libpq native binding)
2011-11-02 19:30:44 +01:00
brianc
b59e0041b3
native bindings compatible with v0.5.x
2011-10-10 22:03:27 -05:00
brianc
06585d6e2c
require 'util' instead of 'sys'
2011-10-10 19:40:52 -05:00
brianc
c7774ca0a8
native bindings emit Error objects on all 'error' events
2011-10-03 23:43:28 -05:00
brianc
2835f25e3f
make booo's tests pass for the native client
2011-10-03 03:26:50 -05:00
brianc
ec1c70c4b5
ability to pause/resume drain event for long-running async transactions
2011-08-29 23:43:36 -05:00
brianc
4f1fef5933
start native code cleanup
2011-08-29 23:06:07 -05:00