-
Notifications
You must be signed in to change notification settings - Fork 27
/
CHANGES
407 lines (364 loc) · 15.9 KB
/
CHANGES
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
CHANGES version 3.2.2
This file summarizes changes made since 1.0
Version 3.2.2
-------------
* Fix: Removed Thread.h from the API. This is an internal interface
and should not have been exposed in the first place.
Version 3.2.1
-------------
* New: Include Library version number in zdb.h
* Fix: Simplified test/zdbpp.cpp and added missing header
* Fix: Improved support for MySQL 8 and MariaDB
Version 3.2
-----------
* New: C++17 support via zdbpp.h which is distributed with libzdb
for more idiomatic use of libzdb from C++.
* New: Support prefetch rows for MySQL and Oracle. Either
programatically via Connection_setFetchSize() or via ResultSet_setFetchSize()
or via a new global 'fetch-size' URL option. Thanks to dragon
jiang (jianlinlong)
* New: MySQL 5.7 and later. Added session query timeout accessible via
Connection_setQueryTimeout()
* New: MySQL 8. Added a new URL option 'auth-plugin' which specify
the authentication plugin to use when connecting to a MySQL server.
* New: Oracle: Added a new URL option 'sysdba' for connecting with
sysdba privileges.
* Fixed: Revert previous fix and remove last SQL terminator character ';' in
statements, except if preceded with END; to allow for ending a pl/sql block.
* Fixed: Oracle: Set SQL null value in prepared statement
* Fixed: Oracle: Handle date/time literal values
Version 3.1
-----------
* New: Support Literal IPv6 Addresses in URL, RFC2732. You can now
use an IPv6 address as host in URL as long as it is enclosed in
brackets, e.g. mysql://[2001:db8:85a3::8a2e:370:7334]:3306/test
Requires that linked database libs supports IPv6. MySQL 5.x,
Postgres 9.x and Oracle 11.x or later versions should be fine.
* New: Honour timezone information if provided with date-time column
values. Previous version assumed date-time information to be in UTC
(which is the usual case).
* Fixed: #7 Removed onstop handler which called third-party database
libraries shutdown method. This could cause a problem for MySQL and
SQLite if more than one Connection Pool was used as the onstop handler
was called in ConnectionPool_stop() and thereby would render other
live Connection Pools invalid as the underlying library was shutdown.
* Fixed: #8 Do not remove a trailing SQL termination charachter ';' from
the SQL statement.
Version 3.0
-----------
* New: Methods for retrieving Date, Time, DateTime and TimeStamp column
values from a ResultSet. PreparedStatement_setTimestamp for setting
Unix timestamp.
* New: ResultSet_isnull, can be used to explicit test if a column
value in a Result Set is SQL null. A Result Set already returns
the NULL pointer for string and blob types and 0 for primitive data
types if column value is SQL null, but to differ between SQL null and
the value NULL or 0, this method can be used.
* New: PreparedStatement_getParameterCount, Returns the number of
parameters in a prepared statement
* New: It is now a checked runtime error for the url parameter given
in ConnectionPool_new() to be NULL.
* New: No longer require flex installed as the generated file is
part of the distribution.
* Fixed: Oracle: memory corruption in OracleResultSet when a Blob
value is retrieved as a String
Version 2.12
--------------
* New: PreparedStatement_rowsChanged added to PreparedStatement.h
* Fixed: Oracle: OCIPing is used to check oracle connection and
ensure that the Pool returns connected connections. Thanks to
Pavlo Lavrenenko.
Version 2.11.3
--------------
* New: License exception added to allow for linking and
distributing this Software together with OpenSSL.
Version 2.11.2
--------------
* New: Throw SQLException if a database access error occurs
when ResultSet_next() is called. Previously, access errors
could be masked as end of result set. Thanks to JiaQiang Xu.
* Fixed: Possible mem leak in Oracle's blob operation fixed
(Volodymyr Tarasenko)
Version 2.11.1
--------------
* Fixed: MySQL: Fixed a ResultSet bind memory error which could occur
if string or blob columns of different size caused successive buffer
reallocation. Thanks to Ryan Addams for discovering the problem.
Version 2.11
------------
* New: Added support for the new bytea hex encoding format
introduced in PostgreSQL 9.0.
* Fixed: MySQL: A table with two or more columns larger than 256
bytes would cause libzdb to truncate the second column to 256
bytes in the first row. Thanks to Me from China for bug report
and patch.
* Fixed: Using configure flags --with-xxx without arguments
now works as expected. Thanks to Johan Bergström for report
Version 2.10.6
--------------
* New: ConnectionPool_start() now throws an SQLException instead
of calling ABORT if starting the pool failed. Thanks to
Christopher O'Hara for suggestion.
* Fixed: MySQL: Using a stored procedure which returned a
result set would freeze the connection until it was reaped.
Thanks to Jesse White for patch.
* Fixed: Ensure that the library can be restarted after it was
stopped without leaking resources. Only applicable for MySQL
which could leak memory on runtime restart. Thanks to Axel
Steiner for initial patch and suggestion.
Version 2.10.5
--------------
* New: Automatically unescape the following URL components:
credentials, path and parameter values.
Version 2.10.4
--------------
* MySQL: Improved error reporting for select and prepared statements
Version 2.10.3
--------------
* Fixed: Oracle: fixed a compile issue for GCC when strict C99 is
used. Thanks to Stas Oginsky.
Version 2.10.2
--------------
* Fixed: Oracle: fixed a parameter sequence bug at connection. Bug
was introduced in 2.9. Thanks to l00106600.
Version 2.10.1
--------------
* A zdb.pc library package config file was added. Thanks to
Matthieu Verbert
* Build, configure and minor code improvements
Version 2.10
-----------
* Libzdb is now compatible with and can be included in C++ or
Objective-C(++) projects.
* Internal optimising changes and improvements
Version 2.9
-----------
* SQLite: Unescape path to allow for (white-)space in database file
path. Thanks to Jonas Schnelli
* SQLite: Use sqlite3_open_v2 instead of sqlite3_enable_shared_cache
which is deprecated in OS X Lion.
* Oracle: Fixed a problem with ResultSet not returning all data
Version 2.8.1
-------------
* Oracle: Fixed a transaction related memory leak
Version 2.8
-----------
* Allow spaces in URL property values
* PostgreSQL: Allow sending application name to the server for
logging. Thanks to Chris Mayo. See the PostgreSQL URL property,
application-name.
Bug fixes:
* ResultSet_getBlob: Ensure that returned blob size is 0 if blob
is SQL null.
* Oracle: Fixed ResultSet memory leak.
Version 2.7
-----------
* Added tentative support for Oracle. Thanks to Volodymyr
Tarasenko, and Sergey Pavlov for implementing this.
This implementation does not support BLOB, though CLOB
is supported. It will also not run all zdb unit tests,
but should be useful for most purposes. It is released
with the hope that others may still find it useful and
help iron out any remaining issues.
* Added new convenience zdb.h meta include file which
can be used to include all required API interfaces
* Internal optimizing changes and improvements
* SQLite: Clear connection on rollback to prevent SQLite
from issue an SQLITE_BUSY error if there are pending
selects in progress.
* SQLite: added a "heap_limit" URL property. Makes SQLite
auto-release unused memory if memory usage goes above
the specified limit [KB]. Require that SQLite is
compiled with the SQLITE_ENABLE_MEMORY_MANAGEMENT option
to take effect.
Bug fixes:
* SQLite: Ensure that the database file is specified in
connection URL. Thanks to Bogdan Nicula.
* PostgreSQL: Implemented Connection_setQueryTimeout()
Version 2.6
-----------
* Internal optimizing changes and improvements
* Enable shared cache mode for SQLite >= 3.5
* Added new configure option --enable-sqliteunlock which
enables SQLite unlock notification. This feature requires
SQLite >= 3.6.12 compiled with the SQLITE_ENABLE_UNLOCK_NOTIFY
C-preprocessor symbol. This option greatly improves upon
SQLite concurrency when libzdb and SQLite is used from a
multi-threaded program.
* Removed deprecated ResultSet_readData() from API
Bug fixes:
* PostgreSQL: Unescape values retrieved via ResultSet_getBlob()
and via ResultSet_getBlobByName(). By an incurie, unescape was
left out of libzdb version 2.5.
Version 2.5
-----------
* Removed GPL license exceptions. The library is now licensed under
the GPL version 3 only.
* Deprecated ResultSet_readData(). This function _was_ useful for
MySQL, but not for other drivers where it had some overhead.
* Added GCC __attribute__ printf checks where applicable
* PostgreSQL: Blob retrieval optimized
* PostgreSQL: Added unix-socket parameter to connection URL
* Internal optimizing changes and improvements
Version 2.4
-----------
* The options --with_mysql=<path> and --with_postgresql=<path> to
configure has a new meaning; If <path> is given it is assumed to be
the full path to respectively mysql_config and to pg_config. Example:
./configure --with_mysql=/usr/local/mysql/bin/mysql_config
./configure --with_postgresql=/usr/local/pgsql/bin/pg_config
* From version 2.4, libzdb places its header files into a zdb
sub-directory as in, <prefix>/include/zdb. Clients must now use the
include-dir compiler flag, -I<prefix>/include/zdb.
* Internal optimizing changes and improvements
* Changed two prototypes to 'extern void foo(void)' so the library
compiles without warning if -Wstrict-prototype is used with gcc.
Thanks to Paul Stevens
Bug fixes:
* Fixed off-by-one bug in Vector_remove
* PostgreSQL: Fixed PostgresqlResultSet_getColumnSize to report correct
value.
* PostgreSQL: Improved error reporting and fixed potential allocation
bugs in prepared statements.
* PostgreSQL: Calling PreparedStatement_setString with a NULL value now
works
Version 2.3
-----------
* Cleaned up API and changed function return type to void for
those functions that can throw exception on error.
* Support variable arguments in Connection_prepareStatement()
to make it easy to build prepared statements in-place
Version 2.2.3
-------------
Bug fixes:
* Make sure connection properties, max rows and query timeout are
reset on Connection_close(), if changed.
* Ensure that timeout is set for new Connections.
* SQLite: Fixed a bug so the SQLite driver now will retry executing
on database lock. This should greatly improve concurrent usage of
SQLite and reduce database locks from occurring
Version 2.2.2
-------------
Bug fixes:
* Ensure that reaper progress forward and remove all connections it can
* Fixed a va_copy bug on 64 bits systems
Version 2.2.1
-------------
* SQLite: Improved error reporting by using sqlite3_prepare_v2() when
available. Thanks to Paul Stevens for suggesting this.
Bug fixes:
* MySQL and PostgreSQL: Fixed off-by-one count when verifying validity
of parameter and column index. Thanks to Paul Stevens for bug report.
* MySQL: Workaround mysql column truncation bug. Thanks to Paul Stevens
for bug report.
Version 2.2
-----------
* Detailed error message added to exception. In an exception handler,
the variable Exception_frame.message, now provides an alternative to
Connection_getLastError() for obtaining the latest error message
* From this release, building with exceptions handling is no longer
optional but required
* Internal optimizing changes
Bug fixes:
* Fixed Connection_prepareStatement() error reported on a PostgreSQL
Connection. Thanks to Paul Stevens for bug report.
* MySQL: Fixed error in ResultSet_getBlob() and ResultSet_getString()
which lead to a segfault when trying to obtain "large" strings and
blobs. Again thanks to Paul Stevens.
* PostgreSQL: Fixed the "syntax error at character 12" for prepared
statement deallocation. Thanks to Paul Stevens for bug report.
Version 2.1
-----------
* API: Connection_ping is promoted to a public method. Clients can use
this method to test if a Connection is alive.
* API: Connection_clear() is exposed as a public method. Normally it
is not necessary to call this method, but in some situations, if you
use PreparedStatement_executeQuery it is necessary to call this
function to close a prepared statement explicit. Basically, if you
see this SQLite error, "SQL statements in progress", call this
function to close any previous opened statements before proceeding.
* Upon returning a Connection, the Connection Pool previously tried to
commit a Connection if it was in a non-committed state, while now it
rollback instead, which is assumed to be more correct.
* Improved retry when SQLite report database lock, which should reduce
the chance to meet the infamous SQLite "database is locked" error
* Removed section 3 from "Tildeslash License Exception" so libzdb is
licensed clear and permissive.
* Internal optimizing changes
Version 2.0.2
-----------
* Don't normalize path during URL parsing. If the path needs to be
normalized it is the responsibility of the caller
* Minor internal changes
* libzdb is now licensed under GNU General Public License version 3
Version 2.0.1
-----------
* ConnectionPool_version() is now a class method
* Minor internal changes
Version 2.0
-----------
* Exceptions handling added to the library. This change how clients
should use the library. Methods in the library that can throw an
SQL Exception should now be called from inside a try-catch block.
Bug fixes:
* Fixed a PostgreSQL prepared statement bug. If parts of a statement
was defined after its last parameter, preparation failed.
Version 1.1.3
-------------
Bug fixes:
* This release fixes a MySQL prepared statement bug. If a prepared
statement was used with two or more number parameters, the numbers
were saved with a bogus value in the database. Thanks to José Antonio
Sánchez
Version 1.1.2
-------------
* ResultSet_next() can be given a NULL value, upon which false is returned.
Version 1.1
-------------
* Added PostgreSQL support
* Using 'mysql_config' when available. Thanks to Paul Stevens paul
* Removed the viral clausal from the exceptions license
* Note, the caller is now responsible for freeing the URL_T object used
in ConnectionPool_new(), via the URL_free() method.
Version 1.0.4
-------------
* Use libtool to set release information for the library.
* Simplified and removed section 4 of the license exception.
* Use new version of auto-tools so library extension is set correct
* Include bootstrap script for recreating configure
* Minor internal changes
Version 1.0.3
-------------
* Clear any previous resultset when calling Connection_execute() also. This
allow MySQL implementations to issue a Connection_executeQuery() followed
by Connection_execute() without having to close the Connection first.
Otherwise MySQL may return a 'commands out of sync' error.
Bug fixes:
* Changed declaration of AbortHandler() so clients are not required to
provide this function.
Version 1.0.2
-------------
Bug fixes:
* Refactor and consolidate PreparedStatement clearResultSet
* Do not free prepared statements on Connection_executeQuery(), only the
ResultSet if any.
* MySQL: Avoid unnecessary re-allocation in
MysqlResultSet.ensureCapacity() and set the new buffer length
properly.
* MySQL: Stop MysqlResultSet_next() sooner when maxRows is reached for
versions < 5.0
* MySQL: Do not try to bind params in PreparedStatement unless in-params
are present in the statement
Version 1.0.1
-------------
* API: Connection_beginTransaction(), Connection_commit() and
Connection_rollback() now returns an int (true or false) instead of void.
Bug fixes:
* MySQL: Removed a debug statement in MySQL prepare statement so a
potential error message is not lost - MySQL pops last error messages.
* MySQL: Make room for a terminating NUL byte when fetching large strings.
* configure.ac: Don't link with zlib unless mysql version was confirmed
* configure.ac: Don't print a warning if re2c was not found - Not required
Version 1.0
-----------
* Initial release