Monday, November 9, 2009

MySQL Connector/J 5.1

Connector/J 5.1 includes support for JDBC-4.0 functionality, including:

* 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.
* Unwrapping to interfaces that include vendor extensions
* Support for XML processing via JAXP interfaces to DOM, SAX and StAX
* 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

Wednesday, November 4, 2009

Reading Cache Memory

If you read and store any data at all, it will, at some point be read and
stored by the cache memory of the processor. That is what the cache memory
is there for--to automatically increase the execution speed of your program
by temporarily caching the contents of main memory.

If you wish to use the cache as "extra memory" for your data, this is not
how the cache works, and not what it was designed for. It is designed to
bridge the gap between extremely fast processors and slow main memory or
RAM. The cache controller copies areas of main memory that it thinks are
going to be needed to the cache memory, which the processor can then access
at high speeds. If something isn't in the cache, then the processor has to
wait while it is retrieved from main memory.

As far as directly controlling the cache, there are not generally
instructions in the processor for doing this. Instead, you should research
how your particular cache controller functions, and how it expects memory to
be accessed. By insuring your program follows these same patterns, the
cache controller will perform optimally with your program.

It is possible to optimize the execution speed of a program by arranging
your code for optimal use of the cache, but as I will attempt to explain
below, it is generally a waste of time, unless you simply want to know.

Database Management System

A collection of programs that enables you to store, modify, and extract information from a database. There are many different types of DBMSs, ranging from small systems that run on personal computers to huge systems that run on mainframes. The following are examples of database applications:
  • computerized library systems
    • automated teller machines
  • flight reservation systems
    • computerized parts inventory systems