By barneyb on April 30, 2009
While tuning my new server, I came across an article on MySQL tuning that does a really great job of laying out the main options that need to be tweaked, as well as explaining what they do. It's several years old, but still applicable. Also worth mentioning that MySQL ships with four "sample" configuration files [...]
Posted in database
By barneyb on April 27, 2009
I've been fighting this god-forsaken query for a week, and can come up with absolutely no explaination for its behaviour. Next time I see you, I'll buy you a beer if you can help me understand what's going on. There are two tables involved, and here are their CREATE statements:
CREATE TABLE `sequence` ( — contains [...]
Posted in database
By barneyb on April 15, 2009
I've been bit by this twice in the past few months: comparing database columns that aren't the same type is really really expensive. If you've only got a few rows, no big deal, but if you've got a few hundred thousand (or a few tens of millions) it makes a huge difference. And varchar is [...]
Posted in aside, database
By barneyb on February 4, 2009
This is the final expected RC for CFGrovoy 1.0 and includes a couple more API tweaks (backwards compatible, of course). Bad form to do this right now, but like the attributes-to-params change, I want to get them in before the 1.0 release so I can build the next round of enhancements without mucking up the [...]
Posted in cfml, database, development, groovy, tools
By barneyb on December 16, 2008
Last night I added a new log field to PotD and since I did it live on my prod instance, I wrapped it with a bunch of error handling so that if anything went wrong it wouldn't affect users, it just wouldn't log the new data. (No, this is not my standard operating procedure – [...]
Posted in database
By barneyb on December 10, 2008
About four and a half years ago I wrote a little event tracking app that accepts a timestamp and a list of tags, and then provides a pile of ways to report on the data. Think Twitter, except a couple years earlier, and designed for consumption by software, not people, at least at the individual [...]
Posted in ajax, database, development, javascript, tools
By barneyb on December 5, 2008
I just committed a minor update to my award winning schema tool that allows you to write your migrations as CFM files, as well as CFCs and SQL files. The naming convention is the same (migrationNNNNNN.cfm), and the entire file represents the only minor version for that migration step.
What I've found over time is that [...]
Posted in cfml, database, tools
By barneyb on November 3, 2008
Joe Rinehart made a very good post about the state of "ORM" in CFML. Namely, that there isn't any. There are several abstract persistence frameworks for CFCs, but no real ORM solutions.
Like Joe, I've been using Hibernate/Groovy to back a lot of CFML applications of late and it's wonderful. Certainly not without some downsides, but [...]
Posted in cfml, database, development, groovy, tools
By barneyb on July 12, 2008
I've just released 1.0RC of CF Groovy, including Hibernate support. You can download it, or view the demo app. The download includes both the demo and the runtime engine.
The big new feature is Hibernate support, of course. Here are a couple snippets from the demo app. First, the entity class:
package com.barneyb
import javax.persistence.*
@Entity
class User extends AbstractEntity [...]
Posted in cfml, coldfusion, database, development, groovy, railo, tools
By barneyb on July 2, 2008
After close to two weeks of struggling, I finally managed to deploy pure source to a CFML runtime (Railo, in this case), and get Groovy entities in and out of the database with Hibernate. No compliation, no IDE, no development-mode server, just my Groovy source along with a hacked up CF Groovy. This is very [...]
Posted in cfml, database, development, groovy, java, railo