Thursday, October 2, 2008

Features from the Google patch at Launchpad.net

I have published a few features from the Google patch in bzr branches at launchpad.net. There is one branch for 5.0 and one for 5.1. More features will be published over time. The 5.0 branch has:
  • show patches - provides SHOW PATCHES to display installed patches. Courtesy of  Jeremy Cole at Proven Scaling and others at Percona
  • innodb disallow writes - provides SET GLOBAL INNODB_DISALLOW_WRITES to temporarily block any file system changes by InnoDB (so you can take a backup). Courtesy of Justin Tolmer at Google.
  • innodb fast mutex - makes the InnoDB mutex and rw-mutex scale better on SMP and disables the InnoDB malloc heap as glibc (ptmalloc) or mtmalloc are more than good enough. Courtesy of Ben Handy at Google.
The 5.1 branch has:
  • show patches - provides SHOW PATCHES to display installed patches. Courtesy of  Jeremy Cole at Proven Scaling and others at Percona
  • show global mutex stats - provides SHOW GLOBAL MUTEX STATUS to display mutex contention stats for mutexes other than ones internal to InnoDB. Courtesy of Mark Callaghan at Google.

7 comments:

Kevin Burton said...

Mark,

What version of MySQL did you branch from for your 5.0 build?

Is this just a trunk branch from the official MySQL bzr 5.0 tree?

Kevin

Mark Callaghan said...

It is from the MySQL 5.0 trunk.

kovyrin.info said...

Hi Mark,

Is there any chance these will get ported to 5.1? We're especially interested in scalability improvements patches.

Thanks,
Alexey Kovyrin

Mark Callaghan said...

The fast mutex patch is available for MySQL 5.1 at http://code.google.com/p/google-mysql-tools/wiki/Mysql5Patches. It isn't in my launchpad branch because it is based on the InnoDB plugin. A lot of the code in the big Google patch has been ported to 5.1 internally, so eventually other patches will be made available. The next features on my list to publish patches for are:
* multiple background IO threads in Innodb
* configurable background IO rate limiting for Innodb

Percona has already published different implementations for these.

A patch for global transaction IDs will also be published soon.

Kevin Burton said...

Hey Mark.

I saw Percona's implementation of multiple background threads... I assume you're implementation was started before theirs?

Have you audited their code? What are the advantages of your code?

You said:

"A lot of the code in the big Google patch has been ported to 5.1 internally, so eventually other patches will be made available."

.... I assume this means inside Google internally not inside MySQL/Sun.

While Drizzle is great I'd still like to see MySQL adopt these patches. Some of us are going to be on MySQL for a while.

Kevin

Mark Callaghan said...

I haven't looked at the change that Percona uses. One difference is that their change is ready for you to use today.

I can't do anything about the rate at which others incorporate features we publish. I can make them easier to use (small patches per feature are better than one big patch). Percona has done a great job at picking up features that customers need.

Kevin Burton said...

I think the biggest ease of incorporation feature is to post isolated patches.

I'll be the first to admit that this is difficult. At Rojo and now Spinn3r we have forked branches of code that I can't really re-merge because I've branched VERY far from the trunk.

Hopefully, git, bzr, et all will help this problem in the future though.

We're probably going to be isolating certain features from V2 and releasing individual patches for them (innodb freeze was first, KILL IF_IDLE is next, probably followed by transactional replication).

Hopefully this helps with adoption....

Kevin

Post a Comment