Enhancements:
Fixing compilation problems with Microsoft Visual Studio 2008. GH #10
Avoid name clash with xcode and jemalloc. PR#22, PR#23
Bugfixes:
Avoid segfault, when quote_ident or TextEncoder::Identifier is called with Array containing non-strings. #226
Enhancements:
Use rake-compiler-dock to build windows gems easily.
Add CI-tests on appveyor and fix test cases accordingly.
Bugfixes:
Fix data type resulting in wrong base64 encoding.
Change instance_of checks to kind_of for subclassing. #220
TextDecoder::Date returns an actual Ruby Date instead of a Time (thanks to Thomas Ramfjord)
Enhancements:
Allow URI connection string (thanks to Chris Bandy)
Allow Array type parameter to conn.quote_ident
Bugfixes:
Speedups and fixes for PG::TextDecoder::Identifier and quoting behavior
Revert addition of PG::Connection#hostaddr [#202].
Fix decoding of fractional timezones and timestamps [#203]
Fixes for non-C99 compilers
Avoid possible symbol name clash when linking againt static libpq.
Correct the minimum compatible Ruby version to 1.9.3. #199
Bugfixes:
Fix OID to Integer mapping (it is unsigned now). #187
Fix possible segfault in conjunction with notice receiver. #185
Enhancements:
Add an extensible type cast system.
A lot of performance improvements.
Return frozen String objects for result field names.
Add PG::Result#stream_each and stream_each_row as fast helpers for the single row mode.
Add Enumerator variant to PG::Result#each and each_row.
Add PG::Connection#conninfo and hostaddr.
Add PG.init_openssl and PG.init_ssl methods.
Force zero termination for all text strings that are given to libpq. It raises an ArgumentError if the string contains a null byte.
Update Windows cross build to PostgreSQL 9.3.
Bugfixes:
Fix compatibility with signal handlers defined in Ruby. This reverts cancelation of queries running on top of the blocking libpq API (like Connection#exec) in case of signals. As an alternative the async_exec can be used, which is reverted to use the non-blocking API, again.
Wrap PQcancel to be called without GVL. It internally waits for the canceling connection.
Documentation fixes:
Fix documentation for PG::Connection.conndefaults.
Bugfixes:
Fix crash by calling PQsend* and PQisBusy without GVL (#171).
Enhancements:
Add method PG::Connection#copy_data.
Add a Gemfile to allow installation of dependencies with bundler.
Add compatibility with rake-compiler-dev-box.
Return self from PG::Result#check instead of nil. This allows to stack method calls.
Bugfixes:
Avoid warnings about uninitialized instance variables.
Use a more standard method of adding library and include directories. This fixes build on AIX (Github #7) and Solaris (#164).
Cancel the running query, if a thread is about to be killed (e.g. by CTRL-C).
Fix GVL issue with wait_for_notify/notifies and notice callbacks.
Set proper encoding on the string returned by quote_ident, escape_literal and escape_identifier (#163).
Use nil as PG::Error#result in case of a NULL-result from libpq (#166).
Recalculate the timeout of conn#wait_for_notify and conn#block in case of socket events that require re-runs of select().
Documentation fixes:
Fix non working example for PG::Result#error_field.
Enhancements:
Add unique exception classes for each PostgreSQL error type (#5).
Return result of the block in conn#transaction instead of nil (#158).
Allow 'rake compile' and 'rake gem' on non mercurial repos.
Add support for PG_DIAG_*_NAME error fields of PostgreSQL-9.3 (#161).
Bugfixes:
Shorten application_name to avoid warnings about truncated identifier.
Bugfixes:
Fix segfault in PG::Result#field_values when called with non String value.
Fix encoding of messages delivered by notice callbacks.
Fix text encoding for Connection#wait_for_notify and Connection#notifies.
Fix 'Bad file descriptor' problems under Windows: wrong behaviour of wait_for_notify() and timeout handling of block on Ruby 1.9.
Documentation fixes:
conn#socket() can not be used with IO.for_fd() on Windows.
Enhancements:
Tested under Ruby 2.0.0p0.
Add single row mode of PostgreSQL 9.2.
Set fallback_application_name to programm name $0. Thanks to Will Leinweber for the patch.
Release Ruby's GVL while calls to blocking libpq functions to allow better concurrency in threaded applications.
Refactor different variants of waiting for the connection socket.
Make use of rb_thread_fd_select() on Ruby 1.9 and avoid deprecated rb_thread_select().
Add an example of how to insert array data using a prepared statement (#145).
Add continous integration tests on travis-ci.org.
Add PG::Result#each_row for iterative over result sets by row. Thanks to Aaron Patterson for the patch.
Add a PG::Connection#socket_io method for fetching a (non-autoclosing) IO object for the connection's socket.
Specs:
Fix various specs to run on older PostgreSQL and Ruby versions.
Avoid fork() in specs to allow usage on Windows and JRuby.
Important bugfix:
Fix stack overflow bug in PG::Result#values and column_values (#135). Thanks to everyone who reported the bug, and Lars Kanis especially for figuring out the problem.
PostgreSQL 9.2 beta fixes:
Recognize PGRES_SINGLE_TUPLE as OK when checking PGresult (Jeremy Evans)
Documentation fixes:
Add note about the usage scope of the result object received by the set_notice_receiver block. (Lars Kanis)
Add PGRES_COPY_BOTH to documentation of PG::Result#result_status. (Lars Kanis)
Add some documentation to PG::Result#fnumber (fix for #139)
Bugfixes:
#47, #104
New Methods for PostgreSQL 9 and async API support: PG
::library_version
::ping
escape_literal
escape_identifier
set_default_encoding
check
New Samples:
This release also comes with a collection of contributed sample scripts for doing resource-utilization reports, graphing database statistics, monitoring for replication lag, shipping WAL files for replication, automated tablespace partitioning, etc. See the samples/ directory.
Make builds against PostgreSQL earlier than 8.3 fail with a descriptive message instead of a compile failure.
Made use of a finished PG::Connection raise a PG::Error instead of a fatal error (#110).
Added missing BSDL license file (#108)
Reorganization of modules/classes to be better Ruby citizens (with backward-compatible aliases):
Created toplevel namespace 'PG' to correspond with the gem name.
Renamed PGconn to PG::Connection (with ::PGconn alias)
Renamed PGresult to PG::Result (with ::PGresult alias)
Declare all constants inside PG::Constants, then include them in PG::Connection and PG::Result for backward-compatibility, and in PG for convenience.
Split the extension source up by class/module.
Removed old compatibility code for PostgreSQL versions < 8.3
Documentation:
Clarified licensing, updated to Ruby 1.9's license.
Merged authors list, added some missing people to the Contributor's list.
Cleaned up the sample/ directory
Making contact info a bit clearer, link to the Google+ page and the mailing list
Enhancements:
Added a convenience method: PG.connect -> PG::Connection.new
Bugfixes:
Fixed LATIN5-LATIN10 Postgres<->Ruby encoding conversions
Fix for the 1.8.7 breakage introduced by the st.h fix for alternative Ruby implementations (#97 and #98). Thanks to Lars Kanis for the patch.
Encode error messages with the connection's encoding under 1.9 (#96)
Made rake-compiler a dev dependency, as Rubygems doesn't use the Rakefile for compiling the extension. Thanks to eolamey@bitbucket and Jeremy Evans for pointing this out.
Added an explicit include for ruby/st.h for implementations that need it (fixes #95).
PG::Connection#wait_for_notify
send nil as the payload argument if the NOTIFY didn't have one.
accept a nil argument for no timeout (Sequel support)
Fixed API docs
Taint and encode event name and payload
Handle errors while rb_thread_select()ing in PG::Connection#block. (Brian Weaver).
Fixes for Win32 async queries (RafaĆ Bigaj)
Memory leak fixed: Closing opened WSA event. (rafal)
Fixes for #66 Win32 asynchronous queries hang on connection error. (rafal)
Fixed a typo in PG::Connection#error_message's documentation
fixing unused variable warnings for ruby 1.9.3 (Aaron Patterson)
Build system bugfixes
Converted to Hoe
Updates for the Win32 binary gem builds (Lars Kanis)
Enhancements:
Added a PG::Result#values method to fetch all result rows as an Array of Arrays. Thanks to Jason Yanowitz (JYanowitz at enovafinancial dot com) for the patch.
Bugfixes:
Add an include guard for pg.h
Simplify the common case require of the ext
Include the extconf header
Fix compatibility with versions of PostgreSQL without PQgetCancel. (fixes #36)
Fix require for natively-compiled extension under Windows. (fixes #55)
Change rb_yield_splat() to rb_yield_values() for compatibility with Rubinius. (fixes #54)
Enhancements:
Added support for the payload of NOTIFY events (w/Mahlon E. Smith)
Updated the build system with Rubygems suggestions from RubyConf 2010
Bugfixes:
Fixed issue with PG::Connection#wait_for_notify that caused it to miss notifications that happened after the LISTEN but before the wait_for_notify.
Bugfixes.
Bugfixes, better Windows support.