Is the default mysql adapter gem 3 years old?


#1

Hello,

There must be some obvious explanation that I’m missing, but I can’t
figure out why gem install mysql – as many guides messages instruct
– wants to install v 2.7 of the adapter. I’ve tried it on a number
of recently installed systems with recent rubygems, and they all want
to install v 2.7. That version is three and a half years old!

Why aren’t the newer versions in the gem list? Why aren’t the older
versions available? Do people just use their distribution’s mysql
adapter? Is it that 2.7 does the job so nobody bothers to upgrade?

$ gem list --remote mysql

*** REMOTE GEMS ***

mysql (2.7.3, 2.7)
mysql_replication_adapter (0.4.0)
mysql_retry_lost_connection (0.0.1)

Ok, let’s try installing v 2.7.3 as it says that version’s available…

$ sudo gem install -v 2.7.3 mysql
ERROR: could not find gem mysql locally or in a repository

Hmm, ok, let’s just install it

$ sudo gem install mysql – --with-mysql-config=which mysql_config
Building native extensions. This could take a while…
Successfully installed mysql-2.7
1 gem installed

I wonder what other versions there are

$ gem list --details mysql

*** LOCAL GEMS ***

mysql (2.7)
Author:
Homepage: http://www.tmtm.org/en/mysql/ruby/
Installed at: /opt/local/lib/ruby/gems/1.8

MySQL/Ruby provides the same functions for Ruby programs that the
MySQL C API provides for C programs.

Looks like http://www.tmtm.org/en/mysql/ruby/ history has 2.7 released
2005-08-22 (3.5 years ago!), and many newer versions since.


#2

I do not have mysql gem installed at lall - all I use is libmysql-
ruby1.8 library from Ubuntu apt repository. I think this is preferred
way of getting MySQL to work - but please correct me if I’m wrong and
should use gem instead…