deadlock on host_details: Missed adding the unique key constraint needed on host_details table in create_schema

This commit is contained in:
Prachi Damle 2012-09-06 16:35:28 -07:00
parent 60f130c509
commit 5629165877

View File

@ -829,7 +829,8 @@ CREATE TABLE `cloud`.`host_details` (
`name` varchar(255) NOT NULL,
`value` varchar(255) NOT NULL,
PRIMARY KEY (`id`),
CONSTRAINT `fk_host_details__host_id` FOREIGN KEY (`host_id`) REFERENCES `host`(`id`) ON DELETE CASCADE
CONSTRAINT `fk_host_details__host_id` FOREIGN KEY (`host_id`) REFERENCES `host`(`id`) ON DELETE CASCADE,
CONSTRAINT UNIQUE KEY `uk_host_id_name` (`host_id`, `name`)
) ENGINE=InnoDB DEFAULT CHARSET=utf8;
CREATE TABLE `cloud`.`mshost` (