forked frompostgres/postgres
- Notifications
You must be signed in to change notification settings - Fork6
Commitfe2dec7

Barry Lind
Enhancements to how queries with bind values are stored internally and sent to
the server. Previously we allocated a new String object for the entire finalquery we were sending to the database. If you had a big query, or especiallyif you had large bind values you ended up with essentially two copies in memory.This change will reuse the existing objects and therefore should take 1/2 thememory it does today for a given query. This restructuring will also allowin the future the ability to stream bytea data to the server instead of the current approach of pulling it all into memory.I also fixed a test that was failing on a 7.2 database.Also renamed some internal variables and some minor cleanup. Modified Files: jdbc/org/postgresql/core/QueryExecutor.java jdbc/org/postgresql/jdbc1/AbstractJdbc1Connection.java jdbc/org/postgresql/jdbc1/AbstractJdbc1Statement.java jdbc/org/postgresql/jdbc2/AbstractJdbc2ResultSet.java jdbc/org/postgresql/jdbc2/AbstractJdbc2Statement.java jdbc/org/postgresql/test/jdbc2/DatabaseMetaDataTest.java1 parenta2a3192 commitfe2dec7
File tree
6 files changed
+162
-147
lines changed- src/interfaces/jdbc/org/postgresql
- core
- jdbc1
- jdbc2
- test/jdbc2
6 files changed
+162
-147
lines changedLines changed: 15 additions & 7 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
13 | 13 |
| |
14 | 14 |
| |
15 | 15 |
| |
16 |
| - | |
| 16 | + | |
17 | 17 |
| |
18 | 18 |
| |
19 | 19 |
| |
20 | 20 |
| |
21 | 21 |
| |
22 |
| - | |
| 22 | + | |
| 23 | + | |
23 | 24 |
| |
24 | 25 |
| |
25 | 26 |
| |
26 | 27 |
| |
27 |
| - | |
| 28 | + | |
28 | 29 |
| |
29 | 30 |
| |
30 | 31 |
| |
31 | 32 |
| |
32 | 33 |
| |
33 |
| - | |
| 34 | + | |
| 35 | + | |
34 | 36 |
| |
35 | 37 |
| |
36 | 38 |
| |
| |||
60 | 62 |
| |
61 | 63 |
| |
62 | 64 |
| |
63 |
| - | |
| 65 | + | |
64 | 66 |
| |
65 | 67 |
| |
66 | 68 |
| |
| |||
129 | 131 |
| |
130 | 132 |
| |
131 | 133 |
| |
132 |
| - | |
| 134 | + | |
133 | 135 |
| |
134 | 136 |
| |
135 | 137 |
| |
136 | 138 |
| |
137 |
| - | |
| 139 | + | |
| 140 | + | |
| 141 | + | |
| 142 | + | |
| 143 | + | |
| 144 | + | |
| 145 | + | |
138 | 146 |
| |
139 | 147 |
| |
140 | 148 |
| |
|
Lines changed: 21 additions & 2 deletions
Original file line number | Diff line number | Diff line change | |
---|---|---|---|
| |||
13 | 13 |
| |
14 | 14 |
| |
15 | 15 |
| |
16 |
| - | |
| 16 | + | |
17 | 17 |
| |
18 | 18 |
| |
19 | 19 |
| |
| |||
426 | 426 |
| |
427 | 427 |
| |
428 | 428 |
| |
429 |
| - | |
| 429 | + | |
| 430 | + | |
| 431 | + | |
| 432 | + | |
| 433 | + | |
| 434 | + | |
| 435 | + | |
| 436 | + | |
| 437 | + | |
| 438 | + | |
| 439 | + | |
| 440 | + | |
| 441 | + | |
| 442 | + | |
| 443 | + | |
| 444 | + | |
| 445 | + | |
| 446 | + | |
| 447 | + | |
| 448 | + | |
430 | 449 |
| |
431 | 450 |
| |
432 | 451 |
| |
|
0 commit comments
Comments
(0)