Fixed compilation with PostgreSQL 9.2.
Now, it doesn't compile with 9.1, though, but that's old anyway ;-)
Now, it doesn't compile with 9.1, though, but that's old anyway ;-)
Removed patch version from the extension's version.
Features won't change between patch versions but only between minor versions.
Features won't change between patch versions but only between minor versions.
src/Makefile: Make sure to re-create postrr.control on 'make all'.
postrr.control: Set relocatable to false.
The extension may not be relocated, except when it's created because it used
another schema (postrr) internally.
The extension may not be relocated, except when it's created because it used
another schema (postrr) internally.
Added support for installing PostRR as an extension.
* Added initial control file (generated by configure from .in)
* Moved postrr.sql to postrr--VERSION.sql
* Abort, if the SQL file is loaded directly (-> force the use of the
extension)
* Simply use 'DROP EXTENSION' in uninstall_postrr.sql
* Added initial control file (generated by configure from .in)
* Moved postrr.sql to postrr--VERSION.sql
* Abort, if the SQL file is loaded directly (-> force the use of the
extension)
* Simply use 'DROP EXTENSION' in uninstall_postrr.sql
pgtest.sh: Added dump/restore commands.
CData: Added support for undefined values.
NaN will be treated as undefined value.
NaN will be treated as undefined value.
PostRR_update(): Fixed handling of multiple columns in the same table.
Previously, after updating the first column, the next columns would already
find a matching timeslice (by timestamp), thus updating the old value.
Now, all old data will simply be removed (for timeslices which are strictly
older than the new timestamp (by timestamp)). This ensures that all data
related to the old timestamp is removed.
Note: However, this *might* destroy unrelated data as well in case a user
stores additional information in that table. For now, I will simply ignore
that as I don't see any reasonable justification for doing so ;-)
Previously, after updating the first column, the next columns would already
find a matching timeslice (by timestamp), thus updating the old value.
Now, all old data will simply be removed (for timeslices which are strictly
older than the new timestamp (by timestamp)). This ensures that all data
related to the old timestamp is removed.
Note: However, this *might* destroy unrelated data as well in case a user
stores additional information in that table. For now, I will simply ignore
that as I don't see any reasonable justification for doing so ;-)
RRTimeslice: Added cast from timestamptz to rrtimeslice.
PostRR_update(): Use rrtimeslice_cmp() to decide how to do the update.
That is, added support for overwriting old values and reporting errors if the
given timestamp is older than the appropriate timestamp in the database (which
is the entry having the same sequence number).
That is, added support for overwriting old values and reporting errors if the
given timestamp is older than the appropriate timestamp in the database (which
is the entry having the same sequence number).
RRTimeslice: Added rrtimeslice_cmp().
This function compares two timeslices by timestamp. It returns values less
than zero, zero or greater than zero if the first timestamp is smaller than,
equal to or greater than the second.
Values -2 / 2 indicate that the sequence numbers don't match while values
-1 / 1 indicate that they do match.
This function compares two timeslices by timestamp. It returns values less
than zero, zero or greater than zero if the first timestamp is smaller than,
equal to or greater than the second.
Values -2 / 2 indicate that the sequence numbers don't match while values
-1 / 1 indicate that they do match.
postrr.sql: Removed unnecessary aliases.
Rather, turn them into comments ;-)
Rather, turn them into comments ;-)
postrr.sql: Don't use 'EXECUTE' in PostRR_update().
This will, hopefully, improve performance a bit.
This will, hopefully, improve performance a bit.
configure: Don't output the build date in the summary.
This was broken anyway and is not used in any other place.
This was broken anyway and is not used in any other place.
CData: Use errdetail() rather than errhint() to report details ;-)
RRTimeslice: Quote the lower/upper bounds in the range output.
RRTimeslice: Updated output format to <range> #<seq>/<num>.
That is, format the timeslice in a range format (cf. tstzrange in PostgreSQL
9.2). I suppose this is easier to read for humans, even though it's a bit
longer. Also, include the number of timeslices in addition to the sequence
number as well. This way, we're able to unambiguously parse the output.
That is, format the timeslice in a range format (cf. tstzrange in PostgreSQL
9.2). I suppose this is easier to read for humans, even though it's a bit
longer. Also, include the number of timeslices in addition to the sequence
number as well. This way, we're able to unambiguously parse the output.
CData: Fixed handling of whitespace + garbage detection at end of input.
WTF happened there?!? ;-)
WTF happened there?!? ;-)
RRTimeslice: Don't encode invalid (0) intervals in the output function.
postrr.h: Updated prototype for rrtimeslice_to_timestamptz().
RRTimeslice: Use TimestampTz rather than timestamp without time zone.
This will, hopefully, avoid a whole lota problems when it comes to using
PostRR with daylight savings time, different time zones, etc.
This will, hopefully, avoid a whole lota problems when it comes to using
PostRR with daylight savings time, different time zones, etc.
base: Include extra version information in postrr_version() output.
pgtest.sh: Make it possible to specify PG_CONFIG thru the environment.
uninstall_postrr.sql: Drop table "postrr.rrarchives".
postrr.sql: Added PostRR_update() functions.
These functions may be used to insert or update a value in an archive. The
functions expect a timestamp and double precision value as arguments to
describe the new values. The postrr.rrarchives will then be used to look up
the actual place where to store the values (there may be multiple ones).
There are currently two overloaded versions of this function. One accepts the
name of an archive and the other expects the definition of an archive as
arguments. The latter is meant to be used for internal purposes while the
other is meant to be used by the user. This is not enforced in any way, though
(and I don't see any reason to do so).
These functions may be used to insert or update a value in an archive. The
functions expect a timestamp and double precision value as arguments to
describe the new values. The postrr.rrarchives will then be used to look up
the actual place where to store the values (there may be multiple ones).
There are currently two overloaded versions of this function. One accepts the
name of an archive and the other expects the definition of an archive as
arguments. The latter is meant to be used for internal purposes while the
other is meant to be used by the user. This is not enforced in any way, though
(and I don't see any reason to do so).
postrr.sql: Added 'postrr.rrarchives' table.
This table will be used to store "Round Robin Archive" definitions. Each
archive has a name which may be used to identify the archive and a description
of the table(s) that store the values of the archive. Each entry specifies the
table as well as the RRTimeslice and CData columns to be used for storing the
values.
This table will be used to store "Round Robin Archive" definitions. Each
archive has a name which may be used to identify the archive and a description
of the table(s) that store the values of the archive. Each entry specifies the
table as well as the RRTimeslice and CData columns to be used for storing the
values.
pgtest.sh: Added documentation for 'restart'.
pgtest.sh: Added 'restart' command.
This will restart the PostgreSQL server in the background if it was running
previously.
This will restart the PostgreSQL server in the background if it was running
previously.
CData: Check both arguments of CData_update() for NULL.
CData: Declared CData_update() as not strict.
Any or all arguments may in fact be NULL. This happens, e.g., when updating
single CData columns one by one. In this case, use the other argument as
return value, i.e. leaving it unmodified.
Any or all arguments may in fact be NULL. This happens, e.g., when updating
single CData columns one by one. In this case, use the other argument as
return value, i.e. leaving it unmodified.
CData: Include CF function in output string.
This makes all information available that are required to regenerate the same
CData object from the stringified version.
This makes all information available that are required to regenerate the same
CData object from the stringified version.
pgtest.sh: Exit with status zero when using the 'help' command.
pgtest.sh: Improved help/usage output.
pgtest.sh: Changed PostgreSQL port to 2345.
This is somewhat related to the default port (5432) but we can probably be
fairly sure this is not used otherwise.
This is somewhat related to the default port (5432) but we can probably be
fairly sure this is not used otherwise.
pgtest.sh: 'setup': Create database for the current user.
… rather than using a hard-coded value.
… rather than using a hard-coded value.
postrr_comments.sql: Added comment for CData type.
postrr.7: Added a short description for the CData data type.
configure: Added a few "checking ..." messages for convenience.
configure.ac: Replaced place-holder help text.
autogen.sh: Improved "help" output.
CData: added a cast to double precision.
The cast may only be done explicitly.
The cast may only be done explicitly.
CData: Added cdata_update().
This function may be used to update an existing data set by "merging" another
data set according to the consolidation function.
This function may be used to update an existing data set by "merging" another
data set according to the consolidation function.
RRTimeslice: added a cast to timestamp.
RRTimeslice: Changed all comparison operators to compare SEQ only.
Else, a b-tree won't work (d'oh!).
Else, a b-tree won't work (d'oh!).
rrtimeslice: Added hash function and operator class.
pgtest.sh: Pass additional arguments to client and start.
Also, check for any additional arguments in all other commands.
Also, check for any additional arguments in all other commands.
CData: Added casts from integer and numeric to cdata.
Both casts are marked 'AS ASSIGNMENT'.
Both casts are marked 'AS ASSIGNMENT'.
CData: Use float8 rather than double.
This makes the storage size explicit.
This makes the storage size explicit.
uninstall_postrr.sql: Drop CData type and all related functions, casts, too.
CData: Added support for a type modifier.
The type modifier may be any of 'MIN', 'AVG', 'MAX', specifying the
consolidation function to be used.
The type modifier may be any of 'MIN', 'AVG', 'MAX', specifying the
consolidation function to be used.
CData: fixed typo: RRTIMESLICE → CDATA.
Since the affected macro basically did the same, this error did not matter
much, though.
Since the affected macro basically did the same, this error did not matter
much, though.
Added initial version of the CData data type.
For now, the type provides simple input and output functions only.
For now, the type provides simple input and output functions only.
pgtest.sh: Added a small helper script to setup/run a PG test setup.
Initial import of PostRR -- the PostgreSQL Round-Robin Extension.
For now, this is an early and highly experimental incomplete draft ;-)
The current version provides a new data type "RRTimeslice" implementing basic
round-robin features. It is defined by the length of the slice and the number
of slices before wrapping around, both specified using the type modifier. It
provides basic comparison operators and an operator class for the btree
indexing method.
For now, this is an early and highly experimental incomplete draft ;-)
The current version provides a new data type "RRTimeslice" implementing basic
round-robin features. It is defined by the length of the slice and the number
of slices before wrapping around, both specified using the type modifier. It
provides basic comparison operators and an operator class for the btree
indexing method.