Project

General

Profile

Actions

Bug #17738

closed

duplicate key value violates unique constraint in dynflow_steps

Added by Marco Menzel almost 8 years ago. Updated about 5 years ago.

Status:
Duplicate
Priority:
Normal
Assignee:
-
Category:
-
Target version:
-
Difficulty:
Triaged:
No
Fixed in Releases:
Found in Releases:

Description

ERROR: Sequel::UniqueConstraintViolation
Mysql2::Error: Duplicate entry '4cd571a5-56d5-4235-9404-15cf4c7d52d1-1' for key 'PRIMARY'

Detail: execution_plan_uuid already exists in dynflow_steps
Statement:    INSERT INTO `dynflow_steps` (`execution_plan_uuid`, `id`, `data`, `state`, `started_at`, `ended_at`, `real_time`, `execution_time`, `action_id`, `progress_done`, `progress_weight`) VALUES ('4cd571a5-56d5-4235-9404-15cf4c7d52d1', 1, '{\"execution_plan_id\":\"4cd571a5-56d5-4235-9404-15cf4c7d52d1\",\"id\":1,\"state\":\"pending\",\"class\":\"Dynflow::ExecutionPlan::Steps::PlanStep\",\"action_class\":\"Actions::ForemanAnsible::PlayHostRoles\",\"action_id\":1,\"error\":null,\"started_at\":null,\"ended_at\":null,\"execution_time\":0.0,\"real_time\":0.0,\"progress_done\":0,\"progress_weight\":0,\"children\":[]}', 'pending', NULL, NULL, 0.0, 0.0, 1, 0, 0)
 UPDATE `dynflow_execution_plans` SET `uuid` = '4cd571a5-56d5-4235-9404-15cf4c7d52d1', `data` = '{\"id\":\"4cd571a5-56d5-4235-9404-15cf4c7d52d1\",\"class\":\"Dynflow::ExecutionPlan\",\"state\":\"planning\",\"result\":\"pending\",\"root_plan_step_id\":1,\"run_flow\":{\"class\":\"Dynflow::Flows::Concurrence\",\"flows\":[]},\"finalize_flow\":{\"class\":\"Dynflow::Flows::Sequence\",\"flows\":[]},\"step_ids\":[1],\"started_at\":\"2016-12-19 14:26:15\",\"ended_at\":null,\"execution_time\":null,\"real_time\":0.0,\"execution_history\":[]}', `state` = 'planning', `result` = 'pending', `started_at` = '2016-12-19 14:26:15', `ended_at` = NULL, `real_time` = 0.0, `execution_time` = NULL WHERE (`uuid` = '4cd571a5-56d5-4235-9404-15cf4c7d52d1')

and a second time an insert, a little bit different in the same transaction:

 INSERT INTO `dynflow_steps` (`execution_plan_uuid`, `id`, `data`, `state`, `started_at`, `ended_at`, `real_time`, `execution_time`, `action_id`, `progress_done`, `progress_weight`) VALUES ('4cd571a5-56d5-4235-9404-15cf4c7d52d1', 1, '{\"execution_plan_id\":\"4cd571a5-56d5-4235-9404-15cf4c7d52d1\",\"id\":1,\"state\":\"running\",\"class\":\"Dynflow::ExecutionPlan::Steps::PlanStep\",\"action_class\":\"Actions::ForemanAnsible::PlayHostRoles\",\"action_id\":1,\"error\":null,\"started_at\":\"2016-12-19 14:26:15\",\"ended_at\":null,\"execution_time\":0.0,\"real_time\":0.0,\"progress_done\":0,\"progress_weight\":0,\"children\":[]}', 'running', '2016-12-19 14:26:15', NULL, 0.0, 0.0, 1, 0, 0)


Files

full-trace-17738.txt full-trace-17738.txt 20.8 KB Marco Menzel, 12/20/2016 01:17 AM

Related issues 1 (0 open1 closed)

Related to Ansible - Bug #17701: Ansible Button on Host page emits two ansible tasksClosedActions
Actions #1

Updated by Dominic Cleal almost 8 years ago

  • Project changed from Foreman to foreman-tasks
Actions #2

Updated by Marek Hulán almost 8 years ago

Could you please attach the whole trace you're getting?

Actions #3

Updated by Marek Hulán almost 8 years ago

Based on action name, it's coming from Ansible plugin.

Actions #4

Updated by Marco Menzel almost 8 years ago

Hallo,

sure, here is the full trace. thx

Actions #5

Updated by Marek Hulán almost 8 years ago

  • Description updated (diff)

Could be potentially related to #17701?

Actions #6

Updated by Marek Hulán almost 8 years ago

  • Related to Bug #17701: Ansible Button on Host page emits two ansible tasks added
Actions #7

Updated by Marco Menzel almost 8 years ago

Hello, the fix in "#17701 - Ansible Button on Host page emits two ansible tasks seems" to work. Multiple roles not tested yet. thx

Actions #8

Updated by Tomer Brisker about 5 years ago

  • Status changed from New to Duplicate
Actions

Also available in: Atom PDF