Home |  MySQL Buzz |  FAQ |  Feeds |  Submit your blog feed |  Feedback |  Archive |  Aggregate feed RSS 2.0 English Deutsch Español Français Italiano 日本語 Русский Português 中文
Showing entries 1 to 15

Displaying posts with tag: Load-balancing (reset)

Multi-master support in MySQL Connector/Java
Employee +1 Vote Up -0Vote Down

MySQL Connector/Java has long had support for replication-aware deployment, allowing a single logical Connection object to effectively “pool” connections to both a master and (potentially multiple) slaves.  This allowed scale-out of read load by distribution of read traffic to slaves, while routing write load to the master.  The JDBC specification provides a nice hook to know what’s read-only traffic – Connection.setReadOnly().  When a boolean value of true is passed, a ReplicationConnection will route further commands a selected slave instance, while values of false trigger routing to the master. 

  [Read more...]
MySql Connector/NET 6.7.4 GA has been released
Employee +0 Vote Up -0Vote Down

MySQL Connector/Net 6.7.4, a new version of the all-managed .NET driver for MySQL has been released.  This is the GA, is feature complete. It is recommended for production environments.  It is appropriate for use with MySQL server versions 5.0-5.7.

New features include WinRT Connector, Load Balancing support, Entity Framework 5 and Memcached. 

MySql Connector/NET 6.7.3 Beta 2 has been released
Employee +0 Vote Up -0Vote Down
MySQL Connector/Net 6.7.3, a new version of the all-managed .NET driver for MySQL has been released.  This is the second beta release intended to introduce users to the new features in the release. This release is feature complete, it should be stable enough for users to understand the new features and how we expect them to work. As is the case with all non-GA releases, it should not be used in any production environment. It is appropriate for use with MySQL server versions 5.0-5.7.
Connector/J 5.1.25 Released
Employee +0 Vote Up -0Vote Down

MySQL Connector/J 5.1.25 has been released, and is available in Community and Enterprise flavors on dev.mysql.com and My Oracle Support, respectively.  I’ve already noted the addition of support for connection attributes for MySQL 5.6 – 5.1.25 adds this functionality.  This release also includes a fix for Bug#68733, which caused the special light-weight ping operation to execute only against the master and currently-selected slave, rather than the master plus all active

  [Read more...]
MySQL Connector/Net 6.7.2 Beta has been released
Employee +0 Vote Up -0Vote Down
MySQL Connector/Net 6.7.2, a new version of the all-managed .NET driver for MySQL has been released.  This is the first beta release intended to introduce users to the new features in the release.  This release is feature complete, it should be stable enough for users to understand the new features and how we expect them to work.  As is the case with all non-GA releases, it should not be used in any production environment.  It is appropriate for use with MySQL server versions 5.0-5.7.
MySQL Connector/Net 6.7.1 Alpha 2 has been released
Employee +0 Vote Up -0Vote Down
MySQL Connector/Net 6.7.1, a new version of the all-managed .NET driver for MySQL has been released.  This is the second of two alpha releases intended to introduce users to the new features in the release.  This release is not feature complete and there are significant limitations but it should be stable enough for users to understand the new features and how we expect them to work.  As is the case with all non-GA releases, it should not be used in any production environment.  It is appropriate for use with MySQL server versions 5.0-5.6
MySQL Connector/Net 6.7.0 Alpha has been released
Employee +1 Vote Up -0Vote Down

MySQL Connector/Net 6.7.0, a new version of the all-managed .NET driver for MySQL has been released.  This is the first of two alpha releases intended to introduce users to the new features in the release.  This release is not feature complete and there are significant limitations but it should be stable enough for users to understand the new features and how we expect them to work.  As is the case with all non-GA releases, it should not be used in any production environment.  It is appropriate for use with MySQL server versions 5.0-5.6

More GlassFish loadbalancing tips for Connector/J
Employee +1 Vote Up -0Vote Down

Almost two weeks ago, I encouraged GlassFish users who need load-balanced JDBC connections to MySQL Cluster (or master-master replicated MySQL Server) to set the loadBalanceValidateConnectionOnSwapServer property to true in order to help ensure the connection chosen at re-balance is still usable.  That advice triggered finding a bug (14563127) which will cause the following Exception message:

No operations allowed after connection closed. Connection closed after inability to pick valid new connection during fail-over.

If you implemented the loadBalanceValidateConnectionOnSwapServer property and are seeing the above error message, updating your driver to the

  [Read more...]
Load-balanced JDBC Tip for GlassFish Deployments
Employee +3 Vote Up -0Vote Down

Having supported a number of successful load-balanced JDBC applications using MySQL Cluster and MySQL Connector/J over the years, I’ve found a few problems that are unique to specific Java app servers.  A recent customer inquiry reminded me of a GlassFish-specific issue, and the Connector/J connection property we introduced to help solve it.  I thought it might be useful to document this here for any GlassFish users looking to deploy a load-balanced JDBC application with MySQL (Cluster or multi-master replication).

If you’re entirely new to the load-balancing functionality in MySQL Connector/J, you may want to review some earlier

  [Read more...]
Connector/J extension points – Load Balancing Strategies
Employee +2 Vote Up -0Vote Down

A fourth and final Connector/J extension point I covered in my JavaOne and Silicon Valley Code Camp presentations is load-balancing strategies.  This exists in order to allow you to define behavior for balancing load across multiple back-end MySQL server instances.  MySQL Connector/J’s load-balancing implementation is a simple internal connection pool.  What appears to your application as a single Connection object can actually have multiple physical connections to MySQL servers underneath (one per configured host/port pair).  At specific points, Connector/J will re-balance and choose another host to

  [Read more...]
Connector/J ping (there will be a test on this)
Employee +2 Vote Up -0Vote Down

MySQL Connector/J has a useful feature which executes a lightweight ping against a server (or, in the case of load-balanced connections, all active pooled internal connections that are retained) to validate the connection. As you might guess, this feature is useful for Java apps which use connection pools, so that the pool can validate the connection. Depending on your connection pool and configuration, this can be done at different times:

  • before the pool returns a connection to the application
  • when the application returns a connection to the pool
  • during periodic checks of idle connections

So, if you want to use this magic light-weight ping process, here’s how you do it:

Specifying a “validation query” in your connection pool that starts with “/* ping */” _exactly_ will cause the

  [Read more...]
Managing load-balanced Connector/J deployments
Employee +6 Vote Up -0Vote Down

Connector/J has long provided an effective means to distribute read/write load across multiple MySQL server instances for Cluster or master-master replication deployments, but until version 5.1.13, managing such deployments frequently required a service outage to redeploy a new configuration.  Given that ease of scaling out by adding additional MySQL Cluster (server) instances is a key element in that product offering, which is also naturally targeted at deployments with very strict availability requirements, we had to add support for online changes of this nature.  It’s also critical for online upgrades – the other option is to take a MySQL Cluster server instance down hard, which loses any in-process transactions and generates application exceptions, if any application is trying to use that particular server instance.

Mark Matthews

  [Read more...]
Connector/J load-balancing for auto-commit-enabled deployments
Employee +4 Vote Up -0Vote Down

In a previous blog post, I wrote about Connector/J’s failover policies, I described three triggers which cause Connector/J to re-balance (potentially selecting a new physical connection to another host):

  • At transaction boundaries (transactions are explicitly committed or rolled back)
  • A communication exception (SQL State starting with “08″) is encountered
  • When a SQLException matches conditions defined by user, using the extension points defined by the loadBalanceSQLStateFailover, loadBalanceSQLExceptionSubclassFailover or loadBalanceExceptionChecker properties.
  • Those conditions fit most needs very well, but there are situations where people are running with

      [Read more...]
    Load-balancing for MySQL Cluster
    Employee +4 Vote Up -0Vote Down

    Shortly after I wrote my last post regarding some advanced Connector/J load-balancing properties, Anirudh published a post describing configuration of RHEL LVS for load-balancing and failover of MySQL Cluster SQL nodes.  It’s an interesting post, and I admit I know very little about RHEL LVS, but it reminded me of problems I experienced when trying to set up load-balanced ColdFusion(!) servers at my last job, years back.  We ended up with a nice hardware load-balancer sitting in front of multiple ColdFusion web servers.  The problems we found were that our application depended upon session state, which was stored (of course) on a single web server.  The load-balancer allowed us to define sticky sessions, which is what we did, but it cost us.

    We

      [Read more...]
    Connector/J’s load-balancing failover policies
    Employee +2 Vote Up -0Vote Down

    Connector/J provides a useful load-balancing implementation for Cluster or multi-master deployments.  As of Connector/J 5.1.12, this same implementation is used under the hood for balancing load between read-only slaves with ReplicationDriver.  When trying to balance workload between multiple servers, though, the driver has to decide when it’s safe to swap servers – doing so in the middle of a transaction would not make applications very happy.  Many of the same principles which apply to autoReconnect also apply here – you don’t want to lose important state information.

    As a result, Connector/J will only try to pick a new server when one of the following happen:

  • At transaction
  •   [Read more...]
    Showing entries 1 to 15

    Planet MySQL © 1995, 2014, Oracle Corporation and/or its affiliates   Legal Policies | Your Privacy Rights | Terms of Use

    Content reproduced on this site is the property of the respective copyright holders. It is not reviewed in advance by Oracle and does not necessarily represent the opinion of Oracle or any other party.