genome/genome — pull request #272 by acoffman (2014-12-05 18:19:53+00:00)
Title: Convert SR User label field to text type.

This migration will convert the software result user label column to type `text` which effectively makes it unbounded in width. This is needed for CLE reporting metadata.

According to the Postgres 9.2 release docs (http://www.postgresql.org/docs/9.2/static/release-9-2.html), doing this column widening should not result in a full table lock. It is however, unclear to me if this will result in index rebuilds.

Additionally, this migration adds a new index on the `label` column as the specific query being run in reporting would not utilize any of the existing composite indexes. This index building has to be performed outside of a transaction (as indicated in the migration) in order for the `CONCURRENTLY` modifier to work. I believe that this is desirable to avoid a table lock even though we lose the transactional nature of doing both parts of the migration together.