Merged PRs
dolt
- 4348: go/libraries/doltcore/remotesrv: When uploading a file, pass table file details to the HTTP handler as query params in the URL, instead of stashing them in a shared map.
- 4336: sql-server: Let sql-server expose a remotesapi service to allow cloning, fetching and read replication from its databases.
dolt sql-server
gets a new configuration option,--remotesapi-port
, which if supplied will cause the sql-server process to run a remotesapi service. The service will expose the databases in the sql-server for access as a dolt remote from a dolt CLI or sql-server process.
Includes the following changes in the behavior ofgo/utils/remotesrv
:go/utils/remotesrv
now logs with logrusgo/utils/remotesrv
can serve gRPC and HTTP traffic over the same port.go/utils/remotesrv
gRPC service, when generating file server URLs, will echo the request's:authority
header as the hostname component of the host URL component if-http-host
is not supplied. This changes the old default, which waslocalhost
.
- 4334: Fixes progress reporting bugginess
Fixes #3149 and similar issues withdolt clone
,dolt push
,dolt pull
.
This PR largely simplifies the EphemeralPrinter code and adds a test to ensure that the printer leaves the cursor at the start of a line. Both the POSIX and Windows clear line implementations rely on that behavior which I believe was previously broken.
go-mysql-server
- 1259: Add sponsor button to GitHub
- 1258: Bug Fix: change
unix_timestamp(<expr>)
to return 0 when it can't convertexpr
to a date
MySQL's implementation ofunix_timestamp(<expr>)
returns0
when the expression can't be converted to a date and logs a warning. This PR changes Dolt to have the same behavior. It also includes a bug fix forctx.ClearWarnings
to correctly clear warnings.mysql> select unix_timestamp(1577995200); +----------------------------+ | unix_timestamp(1577995200) | +----------------------------+ | 0 | +----------------------------+ 1 row in set, 1 warning (0.00 sec) mysql> select unix_timestamp("jason"); +-------------------------+ | unix_timestamp("jason") | +-------------------------+ | 0.000000 | +-------------------------+ 1 row in set, 1 warning (0.00 sec) mysql> show warnings; +---------+------+-----------------------------------+ | Level | Code | Message | +---------+------+-----------------------------------+ | Warning | 1292 | Incorrect datetime value: 'jason' | +---------+------+-----------------------------------+ 1 row in set (0.00 sec)
- 1257: allow compare decimals with different precision and scale
- 1252: Reimplemented LIKE expressions to add collation support
Previously, we were converting the patterns fromLIKE
expressions into patterns that the standard regex parser would understand. Said parser does not support collations (as implemented in MySQL), therefore this is a custom-developed pattern matcher forLIKE
expressions that fully supports collations.
This is ONLY for patterns on theLIKE
expression. We still need to implement full regex parsing to supportREGEXP_LIKE
.. Once we haveREGEXP_LIKE
completed, we may revert this back to the regex conversion process, but that will be no time soon.
This also fixes #4303 - 1244: use decimal type for arithmetic functions
fixes #4269
sum will be either float64 or decimal.Decimal type, but return type is decided on the type of the child expression of sum expression. This causes some test results to be modified into int from float.
the test results indecimal.Decimal
type is hard to get the exact matching using its convert method, so result is checked in string format by usingStringFixed()
method of the decimal.Decimal result value.
vitess
- 190: Adding back support for using reserved keywords unquoted in InsertInto
I previously excludedreserved_sql_id
and only includedsql_id
because I didn't think reserved keywords should be allowed as identifiers in insert into columns without being quoted, but it appears we have tests in Dolt that rely on that (e.g.sql-diff.bats calls: INSERT INTO test (pk, int, string, boolean, float, uint, uuid) values ...
) and I figured if we can support those without the quoting, it seems like a nice feature for customers, so I switched back toreserved_sql_id
.
It is confusing that we refer to identifiers as "reserved" keywords when they don't require backtick quoting though and would be nice to tidy that up in our grammar in the future. - 189: Grammar fixes for customer issue using non-reserved keywords in
insert into
statements
A customer reported an issue on Discord with usinginsert into t(pk, comment) values (1, 1)
. Comment is a keyword, but not a reserved keyword, so this is valid syntax, but our parser was failing on it.
A few changes to tidy up:- Updated tests to trigger the customer reported parsing bug when an (unquoted) keyword is used in a list of columns in an insert into statement.
- renamed
column_name_safe_reserved_keyword
tocolumn_name_safe_keyword
, since the contents are keywords, but are not "reserved" keywords that need to be backtick quoted - fixed a bug with recursion for insert into column names (
ins_column_list
rule) - removed
avg
,count
,sum
,min
,max
from lists of reserved keywords, since they are not reserved in MySQL and can parse correctly in tests without being backtick quoted. - added some more comments to try and make the intent of different grammar rules clearer.
- 188: Support Varchar(MAX)
related to #2261 - 187: CTEs on unions parse
Closed Issues
- 4055: Can't migrate dolthub/restaurants on dev
- 4349: Is there a way to release momory?
- 3149: Upload units do not properly update
- 4342: Better build instructions
- 4343: Problem with flatbuffers submodule
- 1232: Case-sensitive comparison of string literal
Latency
Read Tests | MySQL | Dolt | Multiple |
---|---|---|---|
covering_index_scan | 1.93 | 6.55 | 3.4 |
groupby_scan | 12.3 | 22.28 | 1.8 |
index_join | 1.18 | 17.01 | 14.4 |
index_join_scan | 1.14 | 16.12 | 14.1 |
index_scan | 30.26 | 73.13 | 2.4 |
oltp_point_select | 0.15 | 0.57 | 3.8 |
oltp_read_only | 2.91 | 9.56 | 3.3 |
select_random_points | 0.3 | 1.37 | 4.6 |
select_random_ranges | 0.35 | 1.37 | 3.9 |
table_scan | 30.81 | 70.55 | 2.3 |
types_table_scan | 69.29 | 601.29 | 8.7 |
reads_mean_multiplier | 5.7 |
Write Tests | MySQL | Dolt | Multiple |
---|---|---|---|
bulk_insert | 0.001 | 0.001 | 1.0 |
oltp_delete_insert | 2.91 | 19.65 | 6.8 |
oltp_insert | 1.47 | 7.98 | 5.4 |
oltp_read_write | 5.09 | 36.89 | 7.2 |
oltp_update_index | 1.47 | 9.39 | 6.4 |
oltp_update_non_index | 1.44 | 6.55 | 4.5 |
oltp_write_only | 2.3 | 26.2 | 11.4 |
types_delete_insert | 2.97 | 155.8 | 52.5 |
writes_mean_multiplier | 11.9 |
Overall Mean Multiple | 8.3 |
---|
New Format (__DOLT__
)
Read Tests | MySQL | Dolt | Multiple |
---|---|---|---|
covering_index_scan | 2.0 | 2.76 | 1.4 |
groupby_scan | 12.52 | 17.32 | 1.4 |
index_join | 1.18 | 4.57 | 3.9 |
index_join_scan | 1.16 | 3.96 | 3.4 |
index_scan | 30.26 | 54.83 | 1.8 |
oltp_point_select | 0.15 | 0.47 | 3.1 |
oltp_read_only | 2.97 | 8.28 | 2.8 |
select_random_points | 0.3 | 0.73 | 2.4 |
select_random_ranges | 0.35 | 1.12 | 3.2 |
table_scan | 30.81 | 64.47 | 2.1 |
types_table_scan | 70.55 | 569.67 | 8.1 |
reads_mean_multiplier | 3.1 |
Write Tests | MySQL | Dolt | Multiple |
---|---|---|---|
bulk_insert | 0.001 | 0.001 | 1.0 |
oltp_delete_insert | 3.55 | 11.65 | 3.3 |
oltp_insert | 1.58 | 2.81 | 1.8 |
oltp_read_write | 5.18 | 17.01 | 3.3 |
oltp_update_index | 1.58 | 5.18 | 3.3 |
oltp_update_non_index | 1.58 | 5.47 | 3.5 |
oltp_write_only | 2.43 | 8.28 | 3.4 |
types_delete_insert | 3.36 | 12.75 | 3.8 |
writes_mean_multiplier | 2.9 |
Overall Mean Multiple | 3.0 |
---|