This patch strips out our old version of Snappy and uses the OS version
instead. All our supported OSes have the latest version of Snappy in
their base repositories.
This does the following:
* Switch resource manager to a singleton which reduces the amount of
times the XML data is scanned and objects allocated.
* Make the I_S tables use the FE implementation of the system catalog
* Make the I_S.columnstore_columns table use the RID list cache
* Make the extentmap pre-allocate a vector instead of many small allocs
This fix improves the performance of ExeMgr by doing the following:
* Significantly reduces the amount of time the xml configuration is
scanned
* Uses a much faster way to determine the CPU core count
* Reduces the amount of times certain allocations are executed
* Rowgroup pre-allocates vectors for 1024 rows
This improves performance for the first query of a connection and the
performance for smaller result sets. It may well improve performance in
other areas too.
We already use the OS library with our headers, we are just lucky this
has worked so far. This patch removes the source and switches the the OS
headers instead.
If there is only one packet in the buffer it is possible that the read
doesn't contain the whole packet, the resulting in the buffer pointer
going less than 0 and bad things happening.
Fixes the following:
* Compression ratio calculation was incorrect
* Possible issues due to system catalog thread ID usage
* Compressed file size data count was leaking many FDs when the table
wasn't compressed
* Compressed file size data count was allocating random large amounts
of RAM and then leaking it when the table wasn't compressed
* Add INFORMATION_SCHEMA.COLUMNSTORE_FILES which contains information
about files
* Remove file information from COLUMNSTORE_EXTENTS (due to above)
* Hide columns with Object ID < 3000 (internal columns)
* Fix bad calculation in data_size columns
* Fix minor memory leak
* Add compressedSize() function to IDBFileSystem to get the used file
size for a compressed file
* Add columnstore_info schema with utility stored procedures to access
the information_schema tables
It is possible to have a VARCHAR column that isn't NUL terminated, an
example of this is a union of two CHAR columns. So the length should
always act as a terminator when there is no NUL.
Functions such as reverse() that do float/double to string conversion
use printf's %g to do it. Unfortunately this adds a '+' symbol before
the exponent symbol. MariaDB doesn't do this.
This patch builds the string in a way that does not have that problem,
it resembles the way it is done elsewhere in the codebase.
In MariaDB (unlike MySQL) max/min time values include msec of 999999.
This means that subtime() with saturated values can be off by one
second.
For this calculation I have modified add_time (which also does
subtime()) to have a saturated value including 999999 msec. This fixes
the subtime test in the regression suite.
Datetime has internal int value which is very different to MySQL's int
value. This patch differentiates between the two and also fixes a column
width issue which appeared once the datetime handling was fixed.
* The year() function did not handle float/double input correctly
* Makedate() did not handle year < 100 conversion
* 0 date was converted to NULL for some functions
In addition makedate did