github dolthub/dolt v0.50.13
0.50.13

latest releases: v1.43.13, v1.43.12, v1.43.11...
2 years ago

Merged PRs

dolt

  • 4688: go/libraries/doltcore/sqle/cluster: Add the ability to generate a keypair, serve a JWKS, and sign outbound RPCs with a JWT.
  • 4679: go/store/nbs: remove mmapTableIndex
  • 4669: go/doltcore/actions: Added special case handling for renamed tables on dolt reset --hard
    fix for #751
  • 4636: Support --amend in dolt_commit
    Fixes #4595: dolt_commit procedure does not support --amend

go-mysql-server

  • 1377: make json ordering tests less strict
    We shouldn't include tests for ordering between two MySQL "json object" types. MySQL notes that their ordering is unspecified but deterministic.
    The new storage format has a different deterministic ordering than the old storage format in dolt.
  • 1376: Revert "remove having clause from prepending rows (#1368)"
    This reverts commit f179734a7fe27eae530e6e6cf6525e1f236824ea.
  • 1375: don't escape <, >, or & when printing json
  • 1374: enum zero() is 1
  • 1369: Deleted handler_test_common.go (only used in handler_test.go)
    This prevents testify libraries from being included in binaries that depend on the server package.
  • 1368: remove having clause from prepending rows
  • 1367: Fix logic for replacing expressions with alias references in OrderBy clause
    The previous code in pushdownSort was able to replace a missing column reference with an alias reference when that column was aliased, but it wasn't able to correctly replace compound expressions such as ORDER BY BINARY(mytable.mycol) due to how we tracked only the missing column references and didn't consider the sort field expression as a whole.
    This change expands that alias substitution support so that it looks at the entire sort field expression (i.e. not just the individual named references inside it) and replaces missing sort fields with alias references only when the entire sort field expression matches the aliased expression.
    This fixes an issue with Prisma compatibility with Dolt (#4511).
  • 1366: Fixes filtering for null values on json extract
    This PR fixes two issues:
    • JSON_EXTRACT returning json null values when it should be returning sql null values if a path is unresolvable.
    • The relative ordering between json null values, sql null values, and json values.
  • 1364: Updated and expanded engine examples
    The README.md had an updated example, but the actual _example/main.go file did not. I've expanded the example file a bit to include information on setting up users, and slightly simplified the README.md example. I've also added tests for everything, so that if anything breaks, we'll know we need to update both the example file and the README.md portion.
  • 1363: Convert errors during ComPrepare to SQLError
    We were already converting errors in ComStmtExecute, ComMultiQuery, and ComQuery to SQLError so that the correct error codes would be sent to clients. This change adds that support to ComPrepare, too.
    Added a unit test for that case and took the opportunity to simplify the interface for CastSQLError a little bit.
    This change helps get Prisma support a little further along (#4511), but it doesn't look like it fully resolves everything Prisma needs to work with Dolt.
  • 1361: Fixed collation check on foreign key columns
  • 1358: fix example package
    close #1357
    This fixes runtime panic raised by example app in /_example.
    I checked SQL client can obtain response in my local machine.
    ~/go-mysql-server/_example$ go build
    ~/go-mysql-server/_example$ ./_example
    $ mysql --host=127.0.0.1 --port=3306 --database=mydb -u root
    Reading table information for completion of table and column names
    You can turn off this feature to get a quicker startup with -A
    Welcome to the MySQL monitor.  Commands end with ; or \g.
    Your MySQL connection id is 1
    Server version: 5.7.9-Vitess
    Copyright (c) 2000, 2022, Oracle and/or its affiliates.
    Oracle is a registered trademark of Oracle Corporation and/or its
    affiliates. Other names may be trademarks of their respective
    owners.
    Type 'help;' or '\h' for help. Type '\c' to clear the current input statement.
    mysql> select * from mytable;
    +----------+-------------------+-------------------------------+---------------------+
    | name     | email             | phone_numbers                 | created_at          |
    +----------+-------------------+-------------------------------+---------------------+
    | Evil Bob | evilbob@gmail.com | ["555-666-555","666-666-666"] | 2018-04-18 09:41:13 |
    | Jane Doe | jane@doe.com      | []                            | 2018-04-18 09:41:13 |
    | John Doe | john@doe.com      | ["555-555-555"]               | 2018-04-18 09:41:13 |
    | John Doe | johnalt@doe.com   | []                            | 2018-04-18 09:41:13 |
    +----------+-------------------+-------------------------------+---------------------+
    4 rows in set (0.00 sec)
  • 1356: add tests for sql type Zero() functions
    Implementers of GMS might expect similar values to be returned by Convert() and Zero(). For decimal and enum implementations this was not the case and has been fixed.
  • 1355: Allow any select statement for CREATE TABLE AS SELECT ...
    Also fixes a semantics bug in the schema produced by some such statements.
  • 1348: fix visibility for on duplicate key update
    Currently, we treat plan.InsertInto.Source independently from Destination, and is not considered one of InsertInto's children. It is evaluated much later in the analysis process in the rule resolveInsertRules in a similar way as subqueries (we recurse the analyzer on it). This is problematic if we want to reference tables from Source.
    In this PR, I resolve the tables for InsertInto.Source and added extra logic to correctly index those tables' columns.
    There is a special case for on duplicate key update <expr> in that the LHS of the expr can only see Insert.Destination while the RHS can see Insert.Destination and Insert.Source.
    Partial fix for: #4562
    Note: This does not work for CTEs
    This is only kind of a fix for the issue. The right way to fix this is probably to completely resolve InsertInto.Source before doing anything else, but I wasn't able to get that working yet.
  • 1339: Update DateAdd/DateSub to return correct types.
    This change fixes #4376
    Previous implementation was hard-coded to return sql.Date, but now we are following the MySQL standard and return a type based on the inputs.
    The tests in the repo are verifying that the correct data is returned, but we're not testing the actual SQL data that is received, so none of our tests are catching this case yet. We should open a new work item to start testing the actual SQL that's being returned by dolt. For this bug, testing was performed using a local version of dolt with these changes.
    The failing query from the original bug is now working:
    SELECT NOW(), DATE_ADD(NOW(), INTERVAL 14 DAY), dolt_version();
    +----------------------------+----------------------------------+----------------+
    | NOW()                      | DATE_ADD(NOW(), INTERVAL 14 DAY) | dolt_version() |
    +----------------------------+----------------------------------+----------------+
    | 2022-10-18 18:53:24.406345 | 2022-11-01 18:53:24.406345       | 0.50.4         |
    +----------------------------+----------------------------------+----------------+
    1 row in set (0.02 sec)
    

Closed Issues

  • 2984: Column aliasing with alias name the same as column name during aggregation queries results in column not found error (in some cases)
  • 4595: dolt_commit procedure does not support --amend
  • 1357: _example/main.go raises panic

Latency

Read Tests MySQL Dolt Multiple
covering_index_scan 1.93 2.71 1.4
groupby_scan 12.3 17.32 1.4
index_join 1.16 4.57 3.9
index_join_scan 1.12 3.82 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.58 2.9
select_random_points 0.3 0.75 2.5
select_random_ranges 0.35 1.12 3.2
table_scan 30.81 63.32 2.1
types_table_scan 70.55 189.93 2.7
reads_mean_multiplier 2.6
Write Tests MySQL Dolt Multiple
bulk_insert 0.001 0.001 1.0
oltp_delete_insert 3.36 11.04 3.3
oltp_insert 1.7 2.76 1.6
oltp_read_write 5.47 17.01 3.1
oltp_update_index 1.7 4.82 2.8
oltp_update_non_index 1.61 5.18 3.2
oltp_write_only 2.43 8.13 3.3
types_delete_insert 3.3 13.22 4.0
writes_mean_multiplier 2.8
Overall Mean Multiple 2.7

Don't miss a new dolt release

NewReleases is sending notifications on new releases.