Welcome to Slack!

Open source is at the foundation of MySQL and the biggest and best part of open source is the legion of developers and users who use and contribute to our great product.  It has always been of incredible importance to us to interact with our friends in MySQL space and one of the great ways of doing that is via IRC (Internet Relay Chat) on #freenode.  While that still remains a great option many other systems have been developed that offer other advantages.  One of those is slack.

We wanted to create a slack space where our users could hang out, help each other, and interact with MySQL developers.  We’re in no way wanting to replace IRC but just wanting to make it even easier to solve your MySQL problems and learn about the many great things we are working on.

Head on over to http://mysqlcommunity.slack.com to join in on the fun!

MySQL Router 8.0.4-rc has been released

Dear MySQL users,

MySQL Router 8.0.4-rc is the first release candidate for MySQL Router
8.0 series.

The MySQL Router is a new building block for high availability solutions
based on MySQL InnoDB clusters.

By taking advantage of the new Group Replication technology, and
combined with the MySQL Shell, InnoDB clusters provide an integrated
solution for high availability and scalability for InnoDB based MySQL
databases, that does not require advanced MySQL expertise.

The deployment of applications with high availability requirements is
greatly simplified by MySQL Router. MySQL client connections are
transparently routed to online members of a InnoDB cluster, with MySQL
server outages and cluster reconfigurations being automatically handled
by the Router.

To download MySQL Router 8.0.4-rc, see the “Development Releases” tab at
http://dev.mysql.com/downloads/router. Package binaries are available
for several platforms and also as a source code download.

Documentation for MySQL Router can be found at
http://dev.mysql.com/doc/mysql-router/en/

Enjoy!

Changes in MySQL Router 8.0.4 (2018-02-07, Release Candidate)


   Functionality Added or Changed

     * Bootstrapping now accepts the --config option and reads
       the [logger] level option's definition. For example, to enable
       bootstrap's debugging mode:
      
       [logger]
       level = DEBUG

       (Bug #27158098)

     * The default ttl metadata option (Time To Live, in
       seconds) changed from 300 to 5. (Bug #26990955, Bug #88140)

     * The new connect_timeout and read_timeout options were
       added. These are defined under the [DEFAULT] namespace and affect
       internal operations, such as metadata server connections. (Bug
       #26877946)

     * Bootstrap now accepts any member of an InnoDB cluster and
       automatically finds and reconnects to a writable primary.  (Bug
       #25489509)

     * The optional routing_strategy configuration option was
       added. The available values are first-available, next-available,
       round-robin, and round-robin-with-fallback.  Previously, these
       strategies were described as scheduling modes by the mode
       configuration option where the read-write mode defaults to the
       first-available strategy, and the read-only mode defaults to the
       round-robin strategy. This preserves previous behavior for these
       modes. (Bug #86261, Bug #26045094, Bug #25852803)

   Bugs Fixed

     * With logging_folder undefined during bootstrap, all logs
       were written to STDERR. Now, normal bootstrap logs are written to
       STDOUT and debug bootstrap logs are written to STDERR. (Bug
       #27232410)

     * Errors were changed to warnings for the following
       conditions: when Router could not connect to a particular
       metadata server, and when Router could not update the default
       metadata cache replicaset. Under these conditions, Router does
       not stop running because there are multiple metadata servers and
       replicasets. (Bug #27226627)

     * Configuring MySQL Router with sockets would create a
       socket that was only accessible by the MySQL Router user.  (Bug
       #27179456, Bug #88667)

     * The commercial .deb packages were missing the
       mysqlrouter_plugin_info tool. (Bug #27122367)

     * The apt purge process did not remove the
       /var/{lib,log,run}/mysqlrouter directories. (Bug #26955232)

     * Bootstrapping would fail when connecting to a MySQL
       Server under high load if an associated bootstrap query took
       longer than 5 seconds. The 5 second read timeout was increased
       from 5 to 30. In addition, command line options were added to
       change the connect and read timeout values.  (Bug #26877946)

     * Improved error text when bootstrapping against a MySQL
       server 8.0 instance that was not part of InnoDB cluster.  (Bug
       #26846040)

     * Router assumed that a resulting socket from accept()ing a
       socket would be always blocking. On Solaris and Windows this
       assumption is not valid, and this resulted in broken connections
       with large result sets. (Bug #26834769)

     * It was difficult to distinguish the "Too many
       connections" between MySQL Server and MySQL Router, so the Router
       variant now reads as "Too many connections to MySQL Router". (Bug
       #26593909)

     * The bundled README.txt was missing Protobuf and Rapid
       JSON references. (Bug #25619654)

     * Some builds were missing the sample configuration file,
       including the Solaris and Oracle Linux binaries. (Bug #25530691)

     * Router would check IPv4 or IPv6 addresses, but not both.
       Now it goes through the list of addresses and first tries to bind
       to an IPv4 address and if it fails then it goes through the same
       address list and tries to bind to an IPv6 address. (Bug
       #25127667)

     * The generated error message from passing in an empty file
       to --master-key-file (or using an empty mysqlrouter.key) was
       improved. (Bug #25111926)

     * Defining multiple logger sections in the configuration
       file would emit an unclear error. Defining multiple logger
       sections is not allowed. (Bug #25095565)

     * Where destinations=metadata-cache, the role attribute was
       not used or validated; only the mode configuration option was
       used. (Bug #25061854)

     * Failed bootstrap commands would leave a generated
       mysqlrouter.conf.tmp file on the system. (Bug #24930442)

     * On Ubuntu Linux, documentation related files were
       installed under both /usr/share/mysql-router/docs and
       /usr/share/doc/mysql-router. Now they are only installed under
       /usr/share/doc/mysql-router for community builds and
       /usr/share/doc/mysql-router-commercial for commercial builds.
       (Bug #24765509)

     * The maximum number of concurrent client connections was
       increased from about 500 to over 5000, a limit now dependent on
       the operation system. To achieve this, select() based fd event
       calls were replaced by poll() (or WSAPoll() on Windows). (Bug
       #22661705, Bug #80260)

     * The --ssl-key and --ssl-cert optional bootstrap
       command-line options were added. They directly use their MySQL
       client's counterparts, and specify the client-side certificate
       and private key to facilitate client-side authentication. This is
       useful when the root account used during bootstrap was created
       with REQUIRE X509, which requires the client to authenticate
       itself when logging in.

On behalf of Oracle MySQL Release Team
Nawaz Nazeer Ahamed

Preparing your Community Connector for MySQL 8 – part 1 – SHA256

As some of you are by now aware we have shipped MySQL version 8.0.4 and with it delivered a change to the default authentication plugin that is used by the server when new users are created and is announced by the server to the client.  This was done to further tighten the security of MySQL.  Please refer to this article for a good explanation of this new authentication plugin and why it is important.

If you are an application user or application developer and you want to use MySQL 8.0.3 or 8.0.4 and make use of this new authentication plugin then you need to make sure that connector you use supports it.  As this is a new plugin, support for it in community connectors is still being developed.  I would encourage you to reach out to the communities that create the connector you use and let them  know you need this support.

This article (and the one coming after it) is for the connector developers.  There are two types of connectors out there.  The first type uses the libmysqlclient C library to implement the protocol.  The second type implements the MySQL client server protocol natively.  This article gives you important information for using libmysqclient in your connector.  A followup article will include relevant information for native implementations.

Which Version Should You Use?

Even though your application may currently link against the libmysqlclient library that comes with MySQL 5.7, this one will only work for authenticating users who are using other plugins such as mysql_native_password or sha256_password.  For all situations where new users would be created using the caching_sha2_password plugin, an updated connector that supports this plugin is required.  MySQL 8.0.4-rc contains libmysqlclient version 21 which fully understands this new plugin and can work with any user accounts.  We are exploring the possibility of backporting support for caching_sha2_password to previous versions of libmysqlclient.

It’s important to understand that the libmysqlclient library that comes with MySQL 8 is backward compatible and can connect to previous versions of the server so there is no significant need to support building against 5.7 and 8.0 versions at the same time.

How Do I Use It?

Exactly the way you have been using it.  The only change to the API related to this new authentication plugin is a new connection option to retrieve the server public key.  Here are the two scenarios and how they might be coded.

Using an SSL connection (same as for 5.7)
In this scenario the users credentials are passed to the server in plain text however they are passed via the SSL connection and are therefore passed securely.

Not using an SSL connection
In this scenario we are not using an SSL connection and so it is vital that the users credentials not get passed “in the clear”.  To facilitate this the servers public key is retrieved and is used for an RSA key exchange.

For for information on creating encrypted connections to the server, please see this page.

Conclusion

Connectors based on libmysqlclient can be updated very easily by simply updating the version of libmysqlclient they link against.

MySQL Connector/Python 8.0.6-rc has been released

Dear MySQL users,

MySQL Connector/Python 8.0.6-rc is the first release candidate version
of the MySQL Connector Python 8.0 series. This series adds support for
the new X DevAPI. The X DevAPI enables application developers to write
code that combines the strengths of the relational and document models
using a modern, NoSQL-like syntax that does not assume previous
experience writing traditional SQL.

To learn more about how to write applications using the X DevAPI, see
http://dev.mysql.com/doc/x-devapi-userguide/en/. For more information
about how the X DevAPI is implemented in MySQL Connector/Python, and its
usage, see http://dev.mysql.com/doc/dev/connector-python.

Please note that the X DevAPI requires MySQL Server version 5.7.12 or
higher with the X Plugin enabled. For general documentation about how to
get started using MySQL as a document store, see
http://dev.mysql.com/doc/refman/5.7/en/document-store.html.

To download MySQL Connector/Python 8.0.6-rc, see the “Development
Releases” tab at http://dev.mysql.com/downloads/connector/python/

Enjoy!

Changes in MySQL Connector/Python 8.0.6 (2018-02-01, Release
Candidate)

Functionality Added or Changed

* A new bdist_wheel distutils command was added to build a
Connector/Python wheel package.
A new –static option was added that enables static
linking for the C extension variant.

* X DevAPI: In the process of refining the definition of
the X DevAPI to cover the most relevant usage scenarios,
the following API components have been removed from the X
DevAPI implementation for Connector/Python:

+ API components that support session configurations.
The mysqlx.config namespace and all members of the
namespace.

+ The create_table, drop_table, create_view,
drop_view, and alter_view methods from the Schema
class.

* A Pylint test was added for the mysqlx module.

* A new Modify.patch() method was added to the X DevAPI as
a way to change several document attributes in one
operation; otherwise known as a JSON Merge Patch via RFC
7386.

* The create_index() method was added to the Collection
API.

* The transaction API was extended to allow setting
savepoints. The following methods have been added to the
Session object:

+ set_savepoint([name]): executes the SAVEPOINT name
SQL statement to generate a savepoint. If a name is
not provided (or None), one is generated.
The SAVEPOINT statement sets a named transaction
savepoint with a name of identifier. If the current
transaction has a savepoint with the same name, the
old savepoint is deleted and a new one is set.

+ release_savepoint(name): executes the RELEASE name
SQL statement to release a savepoint.
The RELEASE SAVEPOINT statement removes the named
savepoint from the set of savepoints of the current
transaction. No commit or rollback occurs. It
returns an error if the savepoint does not exist.

+ rollback_to(name): executes the ROLLBACK TO name SQL
statement to rollback a savepoint.
The ROLLBACK TO identifier command reverts the state
of the transaction back to what was when executed
the command SAVEPOINT identifier.
Names passed to these functions are checked to make sure
that the name is not null or an empty string. Names such
as ”, “”, , and so on, are not allowed even though
they are allowed by the server. For more information, see
SAVEPOINT, ROLLBACK TO SAVEPOINT, and RELEASE SAVEPOINT
Syntax
(http://dev.mysql.com/doc/refman/5.7/en/savepoint.html).

Bugs Fixed

* On Enterprise Linux 7, SSL connections could fail due to
the Python 2.7.9 or higher requirement. Since EL7
backported the SSL module from Python 3 (PEP466) into its
default Python 2.7.5, SSL connections are now enabled on
EL7. (Bug #27368032)

* MySQL Server 8.0 utf8mb4 collations were missing from
Connector/Python. (Bug #27277964)

* The LICENSE and README files were missing from the C
extension ( “cext”) builds. (Bug #26912787)

* Python 3.6 is now officially supported and tested.

On Behalf of Oracle/MySQL Release Engineering Team
Prashant Tekriwal