MySQLニュース

MySQL Connector/J 5.1.2ベータ版がリリースされました。

オリジナル版:http://lists.mysql.com/java/9090

MySQL Connector/J 5.1.2ベータ版(MySQL用のタイプ4のpure-Java JDBCドライバの新バージョン)が リリースされました。

バージョン5.1.2は、MySQL-4.1、MySQL-5.0、MySQL-5.1ベータ版、MySQL-6.0ファルコンアルファリリース用を含んだいくつかのMySQLのバージョンでの使用にふさわしいリリースです。

バージョン5.1.2は、http://dev.mysql.com/downloads/connector/j/5.1.htmlおよびミラーサイトのConnector/Jダウンロードページからソースおよびバイナリ形式で入手可能です。(すべてのミラーサイトが現在において最新であるとは限らないかもしれないことに注意してください。あるミラーサイトでこのバージョンを見つけることができない場合は、再度確認を行うか、あるいは別のダウンロード・サイトを選択してください。)

いつものことですが、アプリケーションに影響を及ぼす動作変更を把握するには、アップグレードの前に、マニュアルの変更ログ(http://dev.mysql.com/doc/refman/5.0/en/cj-news.html)と"Upgrading"の節(http://dev.mysql.com/doc/refman/5.0/en/cj-upgrading.html)をチェックするようお勧めします。

バグレポート、バグ修正、パッチ等の情報をお待ちしておりますので、以下のページをご利用ください。

http://forge.mysql.com/wiki/Contributing

バージョン5.1.2は、いくつかの新たなパフォーマンスの特徴とともに、JDBC-4.0 APIを実施した最初のベータリリースです。

他の試作リリースと同様、このベータリリースは、製品レベルのシステムあるいはクリティカルなデータをもつシステム上ではインストールしないでください。いかなるソフトウェアの新バージョンをインストールする前でも、バックアップをとることが望ましいです。MySQL AB社は、ハイレベルの品質を保証すべく、非常に努力してきましたが、いかなるソフトウェア試作リリースにおいてと同様、バックアップを行なうことによりデータの保護を行なってください。

以下は本製品の新たな特徴です。

  * Setting the configuration property "rewriteBatchedStatements" to "true" will now cause
the driver to rewrite batched prepared statements with more than 3 parameter sets in a
batch into     multi-statements (separated by ";") if they are not plain (i.e. without
SELECT or ON DUPLICATE KEY UPDATE clauses) INSERT or REPLACE statements.

The following features are new, compared to the 5.0 series of Connector/J:

  * JDBC-4.0 ease-of-development features including auto-registration with the
DriverManager via the service provider mechanism, standardized Connection validity checks
and categorized SQLExceptions based on recoverability/retry-ability and class of the
underlying error.

  * JDBC-4.0 standardized unwrapping to interfaces that include vendor extensions

  * Support for JDBC-4.0 XML processing via JAXP interfaces to DOM, SAX and StAX

  * JDBC-4.0 support for setting per-connection client information (which can be viewed in
the comments section of a query via "SHOW PROCESSLIST" on a MySQL server, or can be
extended to support custom persistence of the information via a public interface)

  * Support for JDBC-4.0 NCHAR, NVARCHAR and NCLOB types

  * The driver will automatically adjust the server session variable "net_write_timeout"
when it determines its been asked for a "streaming" result, and resets it to the previous
value when the result set has been consumed. (The configuration property is named
"netTimeoutForStreamingResults", with a unit of seconds, the value '0' means the driver
will not try and adjust this value).

  * Added experimental support for statement "interceptors" via the  
com.mysql.jdbc.StatementInterceptor interface, examples are in
com/mysql/jdbc/interceptors.  Implement this interface to be placed "in between" query
execution, so that it can be influenced (currently experimental).

  * The data (and how it's stored) for ResultSet rows are now behind an interface which
allows us (in some cases) to allocate less memory per row, in that for "streaming" result
sets, we re-use the packet used to read rows, since only one row at a time is ever active.

  * The driver now picks appropriate internal row representation (whole row in one buffer,
or individual byte[]s for each column value) depending on heuristics, including whether or
not the row has BLOB or TEXT types and the overall row-size. The threshold for row size
that will cause the driver to use a buffer rather than individual byte[]s is configured
by the configuration property "largeRowSizeThreshold", which has a default value of 2KB.

  * Setting "rewriteBatchedStatements" to "true" now causes CallableStatements with
batched arguments to be re-written in the form "CALL (...); CALL (...); ..." to send the
batch in as few client-server round trips as possible.
     

This release also includes the following cahnges that are also present in Connector/J
5.0.7 (not yet released):

  * Setting the configuration parameter "useCursorFetch" to "true" for MySQL-5.0+ enables
the use of cursors that allow Connector/J to save memory by fetching result set rows in
chunks (where the chunk size is set by calling setFetchSize() on a Statement or
ResultSet) by using fully-materialized cursors on the server.
     
      The driver will will now automatically set "useServerPrepStmts" to
      "true" when "useCursorFetch" has been set to "true", since the feature
      requires server-side prepared statements in order to function.
 
  * Fixed BUG#28469 - PreparedStatement.getMetaData() for statements containing leading
one-line comments is not returned correctly.

    As part of this fix, we also overhauled detection of DML for executeQuery() and
SELECTs for executeUpdate() in plain and prepared statements to be aware of the same
types of comments.

  * Added configuration property "useNanosForElapsedTime" - for profiling/debugging
functionality that measures elapsed time, should the driver try to use nanoseconds
resolution if available    (requires JDK >= 1.5)?
   
  * Added configuration property "slowQueryThresholdNanos" - if "useNanosForElapsedTime"
is set to "true", and this property is set to a non-zero value the driver will use this
threshold     (in nanosecond units) to determine if a query was slow, instead of using
millisecond units.
     
    Note, that if "useNanosForElapsedTime" is set to "true", and this property is set to
"0" (or left default), then elapsed times will  still be measured in nanoseconds (if
possible), but the slow query threshold will be converted from milliseconds to
nanoseconds, and thus have an upper bound of approximately 2000 millesconds (as that
threshold is represented as an integer, not a long).
     
  * Added configuration properties to allow tuning of TCP/IP socket parameters:
  
    "tcpNoDelay" - Should the driver set SO_TCP_NODELAY (disabling the
                   Nagle Algorithm, default "true")?
 
  "tcpKeepAlive" - Should the driver set SO_KEEPALIVE (default "true")?
 
  "tcpRcvBuf" - Should the driver set SO_RCV_BUF to the given value?
                The default value of '0', means use the platform default
                value for this property.
  
  "tcpSndBuf" - Should the driver set SO_SND_BUF to the given value?
                The default value of '0', means use the platform default
                value for this property.
 
  "tcpTrafficClass" - Should the driver set traffic class or
                      type-of-service fields? See the documentation
                      for java.net.Socket.setTrafficClass() for more
                      information. 

  * Give more information in EOFExceptions thrown out of MysqlIO (how many bytes the
driver expected to read, how many it actually read, say that communications with the
server were unexpectedly lost).
  
  * Setting "useDynamicCharsetInfo" to "false" now causes driver to use static lookups for
collations as well (makes ResultSetMetadata.isCaseSensitive() much more efficient, which
leads to performance increase for ColdFusion, which calls this method for every column on
every table it sees, it appears).
 
  * Driver detects when it is running in a ColdFusion MX server (tested with version 7),
and uses the configuration bundle "coldFusion", which sets useDynamicCharsetInfo to
"false" (see previous entry), and sets useLocalSessionState and autoReconnect to "true".

  * FixedBUG#28851- parser in client-side prepared statements silently consumes
character following '/' if it's not a multi-line comment.
  
  * FixedBUG#28596- parser in client-side prepared statements runs to end of statement,
rather than end-of-line for '#' comments. Also added support for '--' single-line
comments.

MySQLや関連ソリューションに関するお問い合わせ、お見積などがございましたら、ご連絡ください。

お問い合わせ各MySQL保守サービス見積依頼スマートスタイルOSSストア

ページトップへ