Description
The Mac OS X (and maybe others) implementation of MySQL does not support key lengths greater than 1000 (or 333 for the utf8 charset).
The workaround is to manually change the length of the column in the generated ddl.
This issue appears to be well known and may be fixed in later version of MySQL.
When using Grouper 1.4.0 RC1 and mysql 5.0 and attempting to
initialize via gsh -registry -check, I receive an error : "Specified key was too
long; max key length is 1000 bytes".
mysql> CREATE INDEX attribute_field_value_idx ON grouper_attributes
(field_id, value);
ERROR 1071 (42000): Specified key was too long; max key length is 1000 bytes
mysql> describe grouper_attributes;
value | varchar(1024) | NO | NULL |
mysql> status;
--------------
./mysql5 Ver 14.12 Distrib 5.0.67, for apple-darwin9.5.0 (i686) using
EditLine wrapper
Connection id: 23
Current database: grouper
Current user: root@localhost
SSL: Not in use
Current pager: stdout
Using outfile: ''
Using delimiter: ;
Server version: 5.0.67 Source distribution
Protocol version: 10
Connection: Localhost via UNIX socket
Server characterset: latin1
Db characterset: latin1
Client characterset: latin1
Conn. characterset: latin1
grouper.hibernate.properties :
hibernate.dialect = org.hibernate.dialect.MySQL5Dialect
hibernate.connection.driver_class = com.mysql.jdbc.Driver
hibernate.connection.url = jdbc:mysql://127.0.0.1:3306/grouper