mozilla/picl-idp — pull request #273 by chilts (2013-11-05 04:53:35+00:00)
Title: Update mysql to v2.0.0-alpha9, so we can get transactions

This is a test PR for #261. It's an update for the `mysql` package to v2.0.0-alpha9. Even though this package is "alpha" it is recommended since it is bordering on stable and is really a release candidate. It gets us some other things too, so we should probably use it as a baseline going forward.

v2.0.0 gives us transactions so this is at least the first step. However, there are two caveats with this PR.

1) prior to this my `npm test` would have one failure. Now I have two (the same and one other). Can anyone confirm they also have one. I haven't quite figured out either fix yet.

2) When trying to do the `createSchema()` in the `db/mysql.js` file, it was originally failing hence my comment above using `options.multipleStatements = true;`. In v0.9.6 this option was supposedly available though it obviously seemed to allow multiple transactions anyway. In v2.0.0 this looks to have been closed.

My suggestion is for me to split up the contents of `db/schema.sql` and feed them one by one to the DB in `createSchema()` and then we can remove the `multipleStatements` option.