<?xml version="1.0" encoding="UTF-8"?>
<feed xml:lang="en-US" xmlns="http://www.w3.org/2005/Atom">
  <title>Nick Sieger: ActiveRecord JDBC 0.5</title>
  <id>tag:blog.nicksieger.com,2005:Typo</id>
  <generator uri="http://www.typosphere.org" version="4.0">Typo</generator>
  <link rel="self" type="application/atom+xml" href="http://blog.nicksieger.com/xml/atom10/article/272/feed.xml"/>
  <link rel="alternate" type="text/html" href="http://blog.nicksieger.com/articles/2007/09/02/activerecord-jdbc-0-5"/>
  <updated>2007-09-03T03:24:16+00:00</updated>
  <entry>
    <author>
      <name>Jon Tirsen</name>
    </author>
    <id>urn:uuid:13bad3ea-70b1-46e9-8c1e-a55b508b7537</id>
    <published>2007-09-03T03:24:16+00:00</published>
    <updated>2007-09-03T03:24:16+00:00</updated>
    <title>Comment on ActiveRecord JDBC 0.5 by Jon Tirsen</title>
    <link rel="alternate" type="text/html" href="http://blog.nicksieger.com/articles/2007/09/02/activerecord-jdbc-0-5#comment-273"/>
    <content type="html">&lt;p&gt;Don&amp;#8217;t forget you need to require the jar files for each database you need to use.&lt;/p&gt;</content>
  </entry>
  <entry>
    <author>
      <name>Nick Sieger</name>
    </author>
    <id>urn:uuid:ed536239-db15-4a7d-963b-469c4b020d8f</id>
    <published>2007-09-02T04:47:26+00:00</published>
    <updated>2007-09-02T04:47:26+00:00</updated>
    <title>ActiveRecord JDBC 0.5</title>
    <link rel="alternate" type="text/html" href="http://blog.nicksieger.com/articles/2007/09/02/activerecord-jdbc-0-5"/>
    <category term="jruby" scheme="http://blog.nicksieger.com/articles/tag/jruby"/>
    <category term="activerecord" scheme="http://blog.nicksieger.com/articles/tag/activerecord"/>
    <content type="html">&lt;p&gt;This one&amp;#8217;s a bit late &amp;#8211; consider it part of my &lt;a href="/articles/2007/07/13/pause"&gt;get-caught-up-since-unclogging-the-clogged-blog&lt;/a&gt; series.&lt;/p&gt;

&lt;p&gt;ActiveRecord JDBC 0.5 is out, so you may have heard (it went out the door a week ago Friday; c.f.
&lt;a href="http://blogs.sun.com/arungupta/entry/activerecord_jdbc_0_5_simplified"&gt;Arun&lt;/a&gt; and &lt;a href="http://www.bloglines.com/blog/ThomasEEnebo?id=36"&gt;Tom&lt;/a&gt;). The major feature you get in this version is a new &lt;code&gt;database.yml&lt;/code&gt;
configuration style:&lt;/p&gt;

&lt;div class="typocode"&gt;&lt;pre&gt;&lt;code class="typocode_default "&gt;development:
  adapter: mysql
  database: blog_development
  username: root
  password:&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;

&lt;p&gt;Ok, ok, so what&amp;#8217;s the big deal? This is just Rails&amp;#8217; default database configuration. Well, that&amp;#8217;s the
point &amp;#8211; you no longer have to know anything about JDBC URLs, driver class names, and all that.  We&amp;#8217;ve baked it in for you.  This should make it easier than ever to try out your Rails application on JRuby, as the only piece of manual configuration left for you is the ugly bit of JRuby-specific code you need to &lt;a href="http://www.headius.com/jrubywiki/index.php/Running_Rails_with_ActiveRecord-JDBC"&gt;activate ActiveRecord-JDBC&lt;/a&gt; lurking right above the &lt;code&gt;Rails::Initializer&lt;/code&gt;:&lt;/p&gt;

&lt;div class="typocode"&gt;&lt;pre&gt;&lt;code class="typocode_ruby "&gt;&lt;span class="keyword"&gt;if&lt;/span&gt; &lt;span class="constant"&gt;RUBY_PLATFORM&lt;/span&gt; &lt;span class="punct"&gt;=~&lt;/span&gt; &lt;span class="punct"&gt;/&lt;/span&gt;&lt;span class="regex"&gt;java&lt;/span&gt;&lt;span class="punct"&gt;/&lt;/span&gt;
  &lt;span class="ident"&gt;require&lt;/span&gt; &lt;span class="punct"&gt;'&lt;/span&gt;&lt;span class="string"&gt;rubygems&lt;/span&gt;&lt;span class="punct"&gt;'&lt;/span&gt;
  &lt;span class="ident"&gt;gem&lt;/span&gt; &lt;span class="punct"&gt;'&lt;/span&gt;&lt;span class="string"&gt;ActiveRecord-JDBC&lt;/span&gt;&lt;span class="punct"&gt;'&lt;/span&gt;
  &lt;span class="ident"&gt;require&lt;/span&gt; &lt;span class="punct"&gt;'&lt;/span&gt;&lt;span class="string"&gt;jdbc_adapter&lt;/span&gt;&lt;span class="punct"&gt;'&lt;/span&gt;
&lt;span class="keyword"&gt;end&lt;/span&gt;&lt;/code&gt;&lt;/pre&gt;&lt;/div&gt;

&lt;p&gt;If we can obliterate the need for this last bit of code, and make it easy to obtain the necessary driver bits, I&amp;#8217;ll feel good enough to call this thing a 1.0 product.&lt;/p&gt;</content>
  </entry>
</feed>
