Steven Fackler
a442b2ed4c
Unmangle ConnectTarget and MaybeSslStream
2014-11-03 21:41:35 -08:00
Steven Fackler
ad82d28d18
Demangle PostgresType
2014-11-03 21:31:08 -08:00
Steven Fackler
167b9d0209
Misc cleanup
2014-11-02 16:48:38 -08:00
Steven Fackler
761007487a
Grab RingBuf from std
2014-11-02 10:40:03 -08:00
Steven Fackler
bd9b77a4cf
Fix compilation errors
2014-11-02 10:38:45 -08:00
Steven Fackler
4fbd92e6de
A bit of formating cleanup
2014-11-01 16:38:52 -07:00
Steven Fackler
f8339a6e18
PostgresLazyRows -> LazyRows
2014-11-01 16:28:38 -07:00
Steven Fackler
34aaeaab71
PostgresRow -> Row
2014-11-01 16:27:30 -07:00
Steven Fackler
4eda9cec95
PostgresCopyInStatement -> CopyInStatement
2014-11-01 16:26:03 -07:00
Steven Fackler
7248912cf9
PostgresTransaction -> Transaction
2014-11-01 16:25:11 -07:00
Steven Fackler
4b66c4ab68
PostgresStatement -> Statement
2014-11-01 16:24:24 -07:00
Steven Fackler
2da41be987
Remove the old connection pool
...
It's been deprecated for a long time
2014-11-01 16:22:41 -07:00
Steven Fackler
c11cbd6b7d
PostgresConnection -> Connection
2014-11-01 16:21:47 -07:00
Steven Fackler
d88666586a
PostgresCancelData -> CancelData
2014-11-01 16:19:02 -07:00
Steven Fackler
570512725f
PostgresNotification -> Notification
2014-11-01 16:18:09 -07:00
Steven Fackler
c6c7d8f574
PostgresNoticeHandler -> NoticeHandler
2014-11-01 16:16:50 -07:00
Steven Fackler
975b6dc350
PostgresConnectParams -> ConnectParams
2014-11-01 16:15:30 -07:00
Steven Fackler
09cb2fd4fe
PostgresUserInfo -> UserInfo
2014-11-01 16:14:08 -07:00
Steven Fackler
873a006508
PostgresConnectTarget -> ConnectTarget
2014-11-01 16:13:01 -07:00
Steven Fackler
cea15783a5
PostgresResult -> Result
2014-11-01 16:12:05 -07:00
Steven Fackler
b939526d7b
static -> const
2014-11-01 16:02:50 -07:00
Steven Fackler
22efd1da4b
Update for removal of collections traits
2014-11-01 15:50:25 -07:00
Steven Fackler
a151a5ba02
Update for rust changes
2014-10-31 08:51:27 -07:00
Steve Klabnik
675534c26f
fail -> panic
2014-10-30 00:26:03 -04:00
Steven Fackler
4a9ca42b20
Reuse the same vec during copies
2014-10-28 09:16:11 -07:00
Steven Fackler
5dd09ce9c4
Update docs location
2014-10-26 13:11:14 -07:00
Steven Fackler
886f24ea9d
Get rid of literal type specifiers
...
Yay trait reform!
2014-10-25 23:43:59 -07:00
Steven Fackler
7929d07f74
Fix a desynchronization issue
2014-10-25 20:26:45 -07:00
Steven Fackler
a480ec1cfb
Some more if let conversion
2014-10-25 17:58:46 -07:00
Steven Fackler
00164fad31
Fix read_message name
...
The issue that forced the rename has been resolved
2014-10-23 23:31:26 -07:00
Steven Fackler
86bf3b719b
Switch some .to_string to .into_string
2014-10-18 11:17:12 -07:00
Steven Fackler
e73557cce0
Pull liburl in-crate
...
Cargo apparently can't deal with liburl and rust-url at the same time
and rust-url has some bugs that prevent using it for now.
2014-10-15 08:37:43 -07:00
Steven Fackler
774fd93d80
Start using if let
2014-10-13 21:12:25 -07:00
Steven Fackler
f62aa26917
Fix for upstream changes
2014-10-09 20:43:14 -07:00
Steven Fackler
557a159a8a
Add a trait abstracting over transactions and connections
...
This is implemented *in addition* to the intrinsic methods because
having to import a trait to call `prepare` sucks.
Closes #63
2014-10-08 20:29:26 -07:00
Steven Fackler
b581e3a0af
Doc rephrase
2014-10-05 20:49:09 -07:00
Steven Fackler
749dc34529
Clean up example a bit
2014-10-05 20:47:48 -07:00
Steven Fackler
b69ae99a51
Handle COPY IN in batch_execute
2014-10-05 17:31:25 -07:00
Steven Fackler
58dd5fe12b
Remove weird continue
2014-10-05 14:47:57 -07:00
Steven Fackler
e5ed2ba96e
Use new slice syntax
2014-10-04 20:08:44 -07:00
Steven Fackler
dd4052210f
Improve error handling in COPY
2014-10-01 14:40:43 -07:00
Steven Fackler
51ace9081a
Don't fuse row iterator
2014-09-30 23:54:11 -07:00
Steven Fackler
a64ca5f955
Remove failure from PostgresDbError::new
...
Closes #43
2014-09-30 22:52:27 -07:00
Steven Fackler
5561e7baca
Add column_types to copy in statement
2014-09-30 00:15:17 -07:00
Steven Fackler
0c3f3b1e83
More docs + return copy count from execute
2014-09-30 00:11:23 -07:00
Steven Fackler
91a90f0d1c
Remove some unused methods
2014-09-30 00:02:54 -07:00
Steven Fackler
a85d50805d
Add some prepare_copy_in docs
2014-09-30 00:01:15 -07:00
Steven Fackler
4863433ca7
Add prepare_copy_in to transaction
2014-09-29 23:49:58 -07:00
Steven Fackler
011d531b1d
Remove Binary/Text choice from ToSql
...
Text format doesn't work with our COPY implementation, and FromSql is
already binary only.
2014-09-29 23:41:13 -07:00
Steven Fackler
249db6b55a
Correctly handle bad column counts in copy
2014-09-29 23:32:57 -07:00
Steven Fackler
f88f908498
Don't flush more than needed when copying
2014-09-29 23:09:39 -07:00
Steven Fackler
2e61f1316f
Initial COPY FROM support!
...
cc #51
2014-09-29 22:56:43 -07:00
Steven Fackler
a4a625a30c
Detect direct queries to COPY FROM
2014-09-29 21:05:42 -07:00
Mike "Wizard" Dilger
ed3bcda729
Fix double borrow of conn RefCell<T>
2014-09-30 13:46:21 +13:00
Steven Fackler
18e1240601
Work around rust-lang/rust#17594
2014-09-27 13:55:47 -07:00
Steven Fackler
5410363f49
Fix deprecations
2014-09-24 00:18:27 -07:00
Steven Fackler
c8cc3799be
Fix deprecation warnings
2014-09-17 22:57:23 -07:00
Steven Fackler
0c1dccfd52
Remove unneeded crate_name attribute
2014-09-14 19:27:15 -07:00
Steven Fackler
d9b7d3c4d2
Remove some failure
...
Avoid reborrowing a RefCell over and over since it'll bloat at least the
IR and maybe the resulting binary with failure cruft.
2014-09-12 22:07:10 -07:00
Steven Fackler
e362feb85b
Suppress warnings
2014-09-11 21:35:10 -07:00
Steven Fackler
9a7e5b7c7d
Misc cleanup
2014-09-06 16:33:43 -07:00
Steven Fackler
fa34efba8f
Change docs to work around coercion issue
2014-08-30 10:57:46 +01:00
Steven Fackler
364c213383
Add back crate_name for rustdoc
2014-08-23 09:17:58 -07:00
Steven Fackler
9d44bb8c7e
Fix doc typo
2014-08-20 22:40:11 -07:00
Steven Fackler
b8539003c3
Improve examples a bit
2014-08-19 21:49:27 -07:00
Steven Fackler
30a3210be0
Revert "Strip prefixes from types"
...
This reverts commit ccdb02f661
.
I'm not sure this is the right way to go just yet
2014-08-18 22:02:16 -07:00
Steven Fackler
ccdb02f661
Strip prefixes from types
...
They can be prefixed with the crate name
2014-08-18 21:52:56 -07:00
Steven Fackler
44da9d9e1e
Start using where clauses
2014-08-17 13:57:58 -07:00
Steven Fackler
d9e4625f01
Switch stuff to unsigned types
2014-08-15 20:14:46 -07:00
Steven Fackler
f7c0038fa3
Formatting cleanup
2014-08-15 19:50:11 -07:00
Steven Fackler
dec56db1d6
Remove old crate attributes
2014-08-15 19:25:12 -07:00
Steven Fackler
455dea3bd0
Force all result formats to binary
2014-08-14 20:22:12 -07:00
Steven Fackler
d374641ecb
Remove some indirection from files
2014-08-02 19:10:45 -07:00
Steven Fackler
42123f7765
Extract tests to a separate crate
...
This ensures that we're only testing public API and speeds up the
development process.
2014-06-30 21:30:39 -07:00
Steven Fackler
092453b3b2
Fix docs for indexing
2014-06-29 23:05:26 -07:00
Steven Fackler
8b74cb0ab4
Zero-index ResultRow
...
It seems like this is the decision made by every DB interface *except*
JDBC, and is more consistent with the rest of the language anyway.
Closes #42 .
2014-06-29 22:53:03 -07:00
Steven Fackler
a54fdaf834
Switch docs back to rust-ci (again)
2014-06-29 14:11:38 -07:00
Steven Fackler
a9ec2a21e6
Update for * -> *const changes
2014-06-29 13:42:43 -07:00
Steven Fackler
a2fdd9b6e6
Fix stuff for int fallback removal
2014-06-27 19:36:23 -07:00
Steven Fackler
f35ca8a23e
Fix for unsafe_destructor feature gate
2014-06-21 15:55:12 -07:00
Steven Fackler
d1c477b97e
Stop destructuring a trait object reference
...
This broke upstream but we don't even need to do it.
2014-06-18 23:56:57 -07:00
Steven Fackler
dc603600d1
Makefile + syntax fixes
2014-06-16 09:20:50 -07:00
Steven Fackler
8e34fe3586
Update for upstream changes
2014-06-12 19:35:59 -07:00
Steven Fackler
ed81ceadf2
Update for unused field lint
2014-06-11 21:05:24 -07:00
Steven Fackler
2db1d477d2
Update for plugin changes
2014-06-10 23:27:07 -07:00
Steven Fackler
6537d160f6
Update for collections changes
2014-06-09 20:17:42 -07:00
Steven Fackler
32e6a70e8d
Clean up batch_execute example a bit
2014-06-08 16:12:27 -07:00
Steven Fackler
60e16d3806
Add a batch_execute method
2014-06-08 16:07:15 -07:00
Steven Fackler
5e363204e1
Fix some types to match the postgres implementation
2014-06-07 16:01:50 -07:00
Steven Fackler
cb052398d6
Make lazy_query take a u32
...
That's what the backend accepts so larger values would just overflow.
2014-06-07 00:14:08 -07:00
Steven Fackler
aa457cb5be
to_string -> to_str
2014-06-05 23:32:49 -07:00
Steven Fackler
216f15d33d
Update for collections changes
2014-06-05 20:50:23 -07:00
Steven Fackler
01d8352773
De-Total
2014-06-01 19:57:27 -07:00
Steven Fackler
2a0f92a411
Update for cmp changes
2014-05-31 10:11:18 -07:00
Steven Fackler
e6b45ed291
Update for upstream changes
2014-05-28 21:54:02 -07:00
Steven Fackler
adc81a9809
Some random cleanup
2014-05-27 21:07:58 -07:00
Steven Fackler
b926745f50
More StrBuf cleanup
2014-05-26 15:21:15 -07:00
Steven Fackler
fec7286284
use vec![] intead of Vec::new()
2014-05-26 11:41:18 -07:00
Steven Fackler
d2cd820f71
StrBuf -> String
2014-05-25 20:38:40 -07:00
Steven Fackler
584226bd23
Stop using to_strbuf
2014-05-24 20:42:07 -07:00
Steven Fackler
835da92987
Update for string changes
2014-05-23 20:08:14 -07:00
Steven Fackler
06db735101
Add tests for transaction checks
2014-05-18 19:46:21 -07:00
Steven Fackler
ec7dd96a30
Disallow use of wrong transactions
...
We don't want to allow statements to outlive the active transaction in
which they were prepared.
2014-05-18 19:34:01 -07:00
Steven Fackler
04ba539ca6
Some cleanup
2014-05-18 11:37:52 -07:00
Steven Fackler
7cbbccf79a
Update for upstream changes
2014-05-17 16:40:08 -07:00
Steven Fackler
0aac8225be
Impl IntoConnectParams for Url
2014-05-16 20:47:03 -07:00
Steven Fackler
b9efef80fd
Swap to better format macro
...
This'll make it easier to not forget to switch back to format! when it
gets updated.
2014-05-16 19:18:42 -07:00
Steven Fackler
7849a5843d
Death to ~str!
2014-05-15 19:59:01 -07:00
Steven Fackler
dcd47041d0
More ~str -> StrBuf
2014-05-15 19:27:19 -07:00
Steven Fackler
1909bd46b4
Update for upstream StrBuf changes
2014-05-15 19:11:23 -07:00
Steven Fackler
d1c412b393
More ~str -> StrBuf
2014-05-12 22:05:37 -07:00
Steven Fackler
dc6bb579c2
Little cleanup
2014-05-11 23:28:54 -07:00
Steven Fackler
a00ad0d54e
Start to move to StrBuf
2014-05-11 21:52:59 -07:00
Steven Fackler
6e0a860b9d
Pull IO stuff out to a separate module.
2014-05-04 12:21:52 -07:00
Steven Fackler
ff587b3334
Use Box instead of ~
2014-05-03 22:38:50 -07:00
Steven Fackler
c61c0c23cc
Change doc root URL
2014-04-27 23:16:59 -07:00
Steven Fackler
180c13dee6
Clean up string creation
2014-04-26 14:46:38 -07:00
Steven Fackler
ecea5672a7
Minor cleanup
2014-04-25 23:14:55 -07:00
Steven Fackler
ec43eb86a6
Allocate with box instead of ~
2014-04-25 21:59:44 -07:00
Steven Fackler
e1ebf3a953
Clarify SSL limitations
...
cc #36
2014-04-23 22:54:34 -07:00
Steven Fackler
9eb69c7149
Bump rust-phf version
2014-04-23 20:33:13 -07:00
Steven Fackler
8eca3aecb6
Remove frumious pool hack
2014-04-22 22:14:12 -07:00
Steven Fackler
47cb9b1c3e
Eliminate a few more sources of failure + refactor
2014-04-21 22:53:14 -07:00
Steven Fackler
aca87688fe
Don't decode a non-path host
...
We should let the DNS resolution system handle that part.
2014-04-21 21:43:00 -07:00
Steven Fackler
59e548623c
De ~""
2014-04-21 21:01:44 -07:00
Steven Fackler
ed1b75147e
Minor docs cleanup
2014-04-20 22:53:54 -07:00
Steven Fackler
5c866ba20b
Unify Unix and TCP connection creation
...
Not all Unix socket setups can be configured via a URL connection string
since paths need not be UTF8, so it's possible to directly pass a
`PostgresConnectParams` type into `connect`.
In addition, an SSL encrypted connection can be used via Unix sockets.
2014-04-20 22:27:55 -07:00
Steven Fackler
11193628e9
Re-pub ResultDescription fields
2014-04-20 14:38:11 -07:00
Steven Fackler
2085d01c01
Enable the connect_unix doc test
2014-04-19 11:10:27 -07:00
Steven Fackler
cc3db19974
Merge pull request #35 from zr40/add-unix-domain-socket
...
Add support for connecting through Unix sockets
2014-04-19 12:45:48 -04:00
Matthijs van der Vleuten
5e85d6b9bd
test_unix_connection now detects the socket directory.
...
Change pg_hba.conf to allow connections through the socket.
Ignore connect_unix doc test. It requires `extern crate url;` which is not allowed with rustdoc.
Also, per comments on PR #35 :
- Inline open_unix
- Centralize common code from connect and connect_unix in connect_finish.
2014-04-19 11:42:17 +02:00
Steven Fackler
3c2394fbeb
Update for ~[T] changes
2014-04-19 00:01:20 -07:00
Matthijs van der Vleuten
707e7ccfa4
Add support for connecting through Unix sockets
...
Includes connection test (assumes socket is in /tmp, the default location).
2014-04-18 23:41:39 +02:00
Steven Fackler
e8f183d589
Workaround rustc bug
...
There's an assert getting tripped in the metadata encoder
2014-04-15 23:49:41 -07:00
Steven Fackler
650a03003d
Less sketchy shift
2014-04-11 19:57:09 -07:00
Steven Fackler
8516d841f1
Tweak connection pool API
2014-04-11 19:45:06 -07:00
Steven Fackler
a1acc98f5b
More cleanup
2014-04-09 21:28:50 -07:00
Steven Fackler
3c4dcf8768
Add a canary to PostgresConnection
...
This is a workaround for mozilla/rust#13246 to prevent total badness
until it gets fixed.
cc #34 , #31
2014-04-07 20:52:41 -07:00
Steven Fackler
0d70c17151
Update for IO Vec changes
2014-04-07 20:02:05 -07:00
Steven Fackler
48501cfb73
Stop failing in destructors
...
I'm not sure what the right thing to do is here, but ignoring errors is
what the standard library does.
2014-04-06 23:37:17 -07:00
Steven Fackler
40d5125f2c
Re-pub some fields
2014-04-02 22:56:16 -07:00
Steven Fackler
15f79973a4
Make a PostgresResult typedef
2014-04-02 21:26:41 -07:00
Steven Fackler
ec6fd52301
Fix error message
2014-04-02 09:19:38 -07:00
Steven Fackler
3181d39be8
Use more idiomatic names for row iterators
2014-04-02 00:16:21 -07:00
Steven Fackler
3e5a48dfb6
Update for privacy overhaul
...
The ToSql impl for Timespec is broken as some fields became accidentally
private
2014-04-01 00:32:10 -07:00
Jim Radford
28fd9e8bdb
Better errors when a column has the wrong type
2014-03-31 21:35:09 -07:00
Steven Fackler
a9ec7256a7
More cleanup
2014-03-30 19:21:51 -07:00
Steven Fackler
5157a00587
Miscellaneous cleanup
2014-03-30 16:19:04 -07:00
Steven Fackler
9ff7b3d00a
Remove mandatory failure from row lookup
2014-03-29 17:01:41 -07:00
Steven Fackler
4adf743aeb
Update for upstream changes
2014-03-29 14:33:11 -07:00
Steven Fackler
61f9f43cf3
Stop failing on wrong types
2014-03-27 22:43:10 -07:00
Steven Fackler
76ff679f9a
Don't fail on wrong param count
2014-03-27 21:39:03 -07:00
Steven Fackler
0916a53df3
Make lazy_query result return a Result
2014-03-27 21:20:04 -07:00
Steven Fackler
78c96f23a4
Remove failing wrappers
...
Embrace the error propogation!
2014-03-27 21:08:22 -07:00
Steven Fackler
2d59e5911a
Fix PostgresLazyResult docs
2014-03-25 21:50:59 -07:00
Steven Fackler
587cbff836
Restructure lazy query API
...
It doesn't make any sense to limit lazy queries to statments *prepared*
inside a transaction. We really only care that we're in a transaction
when the statement is executed. This does introduce a new runtime error
if a statement prepared on connection A is executed on a transaction
prepared on connection B, but I don't think anyone will *ever* run into
that.
2014-03-25 21:07:42 -07:00
Steven Fackler
a773f19c20
Some cleanup
2014-03-23 17:34:50 -07:00
Steven Fackler
613ceec630
Updates for upstream changes
2014-03-22 21:20:22 -07:00
Steven Fackler
ec82c45cc9
Updates for API changes
2014-03-20 19:14:20 -07:00
Steven Fackler
2a822eb8c0
Use autoderef stuff for RefCell
2014-03-18 21:00:06 -07:00
Steven Fackler
01e77a06f2
Link in logging crate
2014-03-17 21:05:04 -07:00
Steven Fackler
15eb3891c5
Down with libextra!
2014-03-15 21:35:44 -07:00
Steven Fackler
5b646c0ca1
Some ~[] -> Vec work
2014-03-14 22:33:24 -07:00
Steven Fackler
3cf70fa533
Use no_run for doc tests
2014-03-10 10:06:40 -07:00
Steven Fackler
8034413247
De-globbing
2014-03-09 22:01:51 -07:00
Steven Fackler
58571cab26
Add examples!
2014-03-09 15:22:20 -07:00
Steven Fackler
3760a98528
Check doc code blocks
2014-03-08 22:01:24 -08:00
Steven Fackler
42c6255412
Updates for upstream changes
2014-02-26 00:40:57 -08:00
Steven Fackler
9b81b556a1
Update for hashmap move
2014-02-23 22:32:14 -08:00
Steven Fackler
75de360e9f
Update for API changes
2014-02-21 23:18:39 -08:00
Steven Fackler
c78266b06d
Lower visibility on thing
2014-02-15 19:16:12 -08:00
Steven Fackler
8831466caa
Split statement and result logic out of lib.rs
2014-02-15 18:59:16 -08:00
Steven Fackler
e22a310aad
Switch to extern crate syntax
2014-02-15 15:03:35 -08:00
Steven Fackler
7c9f552eb4
Update for hex move
2014-02-13 19:26:52 -08:00
Steven Fackler
0f4e4e9c08
Sort use statements
2014-02-11 23:44:07 -08:00
Steven Fackler
d72c607b6d
Don't desync the stream on error in quick_query
2014-02-11 23:09:27 -08:00
Steven Fackler
8ae9636422
Forward errors from statement and portal cleanup
2014-02-11 23:07:34 -08:00
Steven Fackler
835f745be2
Updates for library changes
2014-02-10 19:20:53 -08:00
Steven Fackler
dfb61df672
Don't fail on drop with a desynched stream
2014-02-10 00:20:39 -08:00
Steven Fackler
6e37db330b
Properly handle object cleanup errors
...
Destructors now fail and there's a finish method returning an error.
2014-02-09 23:55:16 -08:00
Steven Fackler
dec566e683
Track stream desynchronization
...
If we hit an IO error talking to the server, message framing has
probably been lost and we shouldn't try to keep talking.
2014-02-09 22:45:26 -08:00
Steven Fackler
d84acfda52
Rename tests module to test
2014-02-09 16:01:09 -08:00
Steven Fackler
0ea80b4c99
Build dynamic and static libs
2014-02-09 15:55:31 -08:00
Steven Fackler
e0ec05c9de
Update for collections split
2014-02-08 10:24:21 -08:00
Steven Fackler
26a0cdaae7
Use a Cell for next_portal_id
2014-02-07 18:17:40 -08:00
Steven Fackler
774533e1df
Add a size_hint to result iterator
2014-02-07 18:07:25 -08:00
Steven Fackler
c413633fa9
More error checking
2014-02-06 22:59:43 -08:00
Steven Fackler
e7a2ee8bd8
More updates for upstream changes
2014-02-06 21:37:05 -08:00
Steven Fackler
fdd1f4f88d
Beginnings of fixes for IO API changes
...
It is still very much incorrect in the face of errors, but it's better
2014-02-06 20:58:47 -08:00
Steven Fackler
dbb698b9f3
Rename notification iterator
2014-02-03 00:09:48 -05:00
Steven Fackler
d6aa529474
Move source files to src directory
...
The root was getting too crowded.
2014-02-02 23:28:59 -05:00
Steven Fackler
88bb03119a
Restructure to support rustpkg
2013-09-28 20:30:35 -07:00
Steven Fackler
81af9e9e98
Import Port
2013-09-28 11:14:06 -07:00
Steven Fackler
ce0031c5d0
Restructure Cell wrapping for PostgresConnection
...
It's silly to wrap each individual field in Cell when we can just wrap
everything together.
2013-09-19 21:06:45 -07:00
Steven Fackler
bad3a5e36c
Stop storing query string in statement
...
The query string isn't as useful here since any error at this stage
won't be a syntax issue.
2013-09-18 20:54:47 -07:00
Steven Fackler
fa472cf312
Restructure conn pool to RAII style
2013-09-17 22:06:47 -07:00
Steven Fackler
65aabf5147
Sketches of a connection pool
2013-09-16 23:03:13 -07:00
Steven Fackler
2f282affe6
Move transaction cleanup to descructor
...
Support for connection pooling, since we'll recover the conn after a
task failure.
2013-09-15 22:35:30 -07:00
Steven Fackler
3a7f9ac50c
Updated README with error code stuff
2013-09-15 19:26:56 -07:00
Steven Fackler
1858ed41dc
Better error output
2013-09-14 22:56:52 -07:00
Steven Fackler
a00843751e
Parse Notice/Error SQLSTATE codes
...
The enum is stuck inside of an extra module due to mozilla/rust#4375 .
2013-09-14 21:37:20 -07:00
Steven Fackler
f392d6caf1
Use buffered IO
...
Closes #17
2013-09-14 13:08:09 -07:00
Steven Fackler
5654fa5f2a
Fail on incorrect parameter count
2013-09-11 22:33:19 -07:00
Steven Fackler
4ec8130860
Don't fail on unsupported auth methods
2013-09-11 22:02:32 -07:00
Steven Fackler
970b5f657a
Allow custom notice handling
...
It was a tossup between a ~fn and a ~Trait *shrug*
2013-09-11 19:57:26 -07:00
Steven Fackler
db634b5a3c
Get rid of use *
2013-09-08 22:40:08 -07:00
Steven Fackler
9562711af3
TIMESTAMP WITH TIMEZONE support
2013-09-08 21:33:41 -07:00
Steven Fackler
5bb1ec2db7
Remove read_message macros
...
Workaround for mozilla/rust#9049 but probably the right thing to do in
any case.
2013-09-08 20:35:24 -07:00
Steven Fackler
7971e8678d
DNS lookup
2013-09-08 14:26:34 -07:00
Steven Fackler
20b7b5426d
Timestamp support
...
cc #6
2013-09-08 13:27:43 -07:00
Steven Fackler
1b00801938
Handle asynchronous ParameterStatus
...
Closes #16
2013-09-06 21:56:31 -07:00
Steven Fackler
4eb99e096e
Explicitly set client encoding
...
Postgres will translate data from non-utf8 databases for us
2013-09-05 20:49:19 -07:00
Steven Fackler
a17fe648de
Rename PostgresResult methods to be more clear
2013-09-05 20:31:23 -07:00
Steven Fackler
0a361967ce
Avoid infinite loop
2013-09-04 23:48:02 -07:00
Steven Fackler
8422072d37
Remove savepoint IDs entirely
...
Turns out that Postgres allows nested savepoints with the same name
2013-09-04 23:40:22 -07:00
Steven Fackler
6a696461b9
Simplify savepoint ID logic
...
A savepoint ID is now the "depth" of the savepoint.
2013-09-04 23:32:33 -07:00
Steven Fackler
cf5bd66218
Add nested transaction support
2013-09-04 23:28:44 -07:00
Steven Fackler
c81c207c90
Add methods to look at params and results
2013-09-04 21:51:48 -07:00
Steven Fackler
749aa735f6
Make nice types for parameter and result descs
2013-09-04 21:26:43 -07:00
Steven Fackler
c0d70e90dc
Implement transactional lazy queries
...
Closes #13
2013-09-03 22:42:24 -07:00
Steven Fackler
47d1458eb7
More infrastructure for lazy queries
...
cc #13
2013-09-03 22:20:21 -07:00
Steven Fackler
c2b3768a29
Infrastructure for lazy queries in transactions
...
cc #13
2013-09-03 22:05:28 -07:00
Steven Fackler
9891f597bc
Switch over to new format + clean up matches
2013-09-03 20:07:10 -07:00
Steven Fackler
a677f62fe2
Remove lazy query support
...
It turns out this only works inside a transaction, so the API will need
to be rethought. Probably PostgresTransaction.prepare will return a
special TransactionalPreparedStatement that has support for it or
something.
2013-09-02 23:09:30 -07:00
Steven Fackler
03e0ab29e2
Add link attribute
2013-09-02 19:08:56 -07:00
Steven Fackler
3d8d35d840
Overload Index for PostgresRow
...
RowIndex has to be implemented for int unfortunately since that's what a
literal ends up resolving to.
2013-09-02 18:53:03 -07:00
Steven Fackler
8ab3c1d04b
Add column name to index lookup
2013-09-02 20:07:08 -04:00
Steven Fackler
46b4228415
Binary return value support
...
The set of types the driver asks for in binary format is currently hard
coded.
cc #7 , #14
2013-09-02 15:43:48 -04:00
Steven Fackler
1a6d681cbd
Strict type checking in ToSql
...
cc #14
2013-09-02 13:27:25 -04:00
Steven Fackler
043d231476
Remove redundant format specifiers
2013-09-02 01:29:13 -04:00
Steven Fackler
e9245294f0
Store row description in statement
...
Will be useful for FromSql binary formats. CC #7
2013-09-01 14:09:08 -07:00
Steven Fackler
8b787cf8af
Convenience update methods
...
cc #11
2013-09-01 11:06:33 -07:00
Steven Fackler
e93df44149
Switch PostgresResult storage to Deque
2013-09-01 00:18:09 -07:00
Steven Fackler
fa818566f3
Support for lazy query results
...
Closes #13 .
2013-08-31 23:19:44 -07:00
Steven Fackler
6071706e7e
More work towards row limits
...
cc #13
2013-08-31 22:48:49 -07:00
Steven Fackler
e82c887949
Restructure result API for row limits
...
Work towards #13 .
2013-08-31 21:55:44 -07:00
Steven Fackler
0f1d31c4ab
Batch command sequence writes
...
This allows command sequences like Prepare/Describe/Sync to be sent in
fewer TCP packets.
2013-08-31 17:17:15 -07:00
Steven Fackler
ace9ffcec4
Infrastructure for binary parameter formats
...
Work towards #7 .
2013-08-31 17:16:49 -07:00
Steven Fackler
543af184ab
Moving blocks around for consistency
2013-08-29 02:19:53 -04:00
Steven Fackler
440421e81a
Minor cleanup
2013-08-29 01:44:34 -04:00
Steven Fackler
be080e783f
Stop storing num_params in statement
...
Postgres will check the count for us.
2013-08-29 01:33:27 -04:00
Steven Fackler
30d1a43f4b
Parsing of ErrorResponse and NoticeResponse
...
PostgresDbError::new plays a little fast and loose with the expected
format. Hopefully that's okay.
Closes #4
2013-08-29 00:24:43 -04:00
Steven Fackler
b93bbd7eed
Switched Message enums to struct-like
...
They're now a lot more clear, especially ones like Bind that have tons
of fields.
2013-08-28 23:25:15 -04:00
Steven Fackler
0204d950c4
Log NoticeResponses
...
Progress towards #3 . I think we probably want to have a user
configurable notice handler.
2013-08-28 02:23:36 -04:00
Steven Fackler
27bbf6f7fd
Pull ToSql and FromSql out into their own module
...
Their implementations will become significantly more complicated once we
start handling binary data.
2013-08-28 00:37:06 -04:00
Steven Fackler
604b1ddb4d
Fix for generic type syntax changes
2013-08-28 00:09:50 -04:00
Steven Fackler
afd7d8800d
Better transaction syntax
...
Closes #9
2013-08-27 01:40:23 -04:00
Steven Fackler
6afc2cac3f
Fix error handling for prepare, result and query
...
Closes #2
2013-08-27 01:06:53 -04:00
Steven Fackler
594830b296
Closer-to-proper error handling for connect
2013-08-27 00:19:24 -04:00
Steven Fackler
c73e1e93f4
ifmt! -> format!
2013-08-26 22:38:02 -04:00
Steven Fackler
f60d3993b3
Handle conditions in Drop impls
...
Aborting the process is sadface
2013-08-26 03:36:09 -04:00
Steven Fackler
47ef8ea6b1
Add plaintext and MD5 password authentication
2013-08-26 01:08:37 -04:00
Steven Fackler
ceaac705d6
Parameter binding support!
2013-08-24 23:47:36 -04:00
Steven Fackler
9ff747724a
Query support!
2013-08-23 03:13:42 -04:00
Steven Fackler
dd64882d32
Updates and transactions
2013-08-23 01:24:14 -04:00
Steven Fackler
e5c5b783f3
Clean up for extra::url fixes
2013-08-22 22:47:06 -04:00
Steven Fackler
2b617e61b1
Beginnings of Bind support
2013-08-22 03:12:35 -04:00
Steven Fackler
1f127289bb
Fully construct prepared statements
2013-08-22 02:41:26 -04:00
Steven Fackler
11098f4d47
Beginnigs of native Postgres frontend
2013-08-22 01:58:37 -04:00
Steven Fackler
067f2c9f91
Removed sql and sqlite3
...
I'm going to focus on a postgres driver for now
2013-08-18 17:14:22 -04:00