exception.Conflict does not give specifics

Bug #1599296 reported by Shawn Berger
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
OpenStack Identity (keystone)
Fix Released
Low
Richard

Bug Description

When attempting to create a duplicate entity, the exception raised only provides the resource type that was involved in the request [0]. It would be nice to know exactly what caused the unique constraint to fail. Many deployers are creating multiple keystone objects simultaneously, and so it can get confusing when trying to decipher what error goes with what object that was trying to be created.

[0] http://cdn.pasteraw.com/dh2hbk5m6hkhagpbjog07ve2ud1z71j

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to keystone (master)

Fix proposed to branch: master
Review: https://review.openstack.org/337892

Changed in keystone:
assignee: nobody → Shawn Berger (slberger)
status: New → In Progress
Dave Chen (wei-d-chen)
Changed in keystone:
importance: Undecided → Low
Revision history for this message
Lance Bragstad (lbragstad) wrote : Re: Keystone error message for duplicate entries doesn't have enough information

Automatically unassigning due to inactivity.

Changed in keystone:
assignee: Shawn Berger (slberger) → nobody
status: In Progress → Triaged
Richard (csravelar)
Changed in keystone:
assignee: nobody → Richard (csravelar)
summary: - Keystone error message for duplicate entries doesn't have enough
- information
+ exception.Conflict does not give specifics
description: updated
tags: added: sql user-experience
Revision history for this message
Richard (csravelar) wrote :

An easier way to find out what objects raised a duplicate error is enabling Debug found here: http://docs.openstack.org/developer/fuel-docs/userdocs/fuel-user-guide/troubleshooting/debug-mode.html

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to keystone (master)

Fix proposed to branch: master
Review: https://review.openstack.org/405104

Changed in keystone:
status: Triaged → In Progress
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to keystone (master)

Reviewed: https://review.openstack.org/405104
Committed: https://git.openstack.org/cgit/openstack/keystone/commit/?id=f5b6912e6828d23eab062273e4aff1d88dfec9bb
Submitter: Jenkins
Branch: master

commit f5b6912e6828d23eab062273e4aff1d88dfec9bb
Author: “Richard <email address hidden>
Date: Thu Dec 1 04:33:13 2016 +0000

    Print name with duplicate error on user creation

    Add the ability to print the duplicate user name along with the
    duplicate error message when recieving a conflict type of user

    Change-Id: Ice4ae7e66245991769b792325c950cbed516551a
    Partial-Bug: #1599296

Changed in keystone:
assignee: Richard (csravelar) → Steve Martinelli (stevemar)
Revision history for this message
Steve Martinelli (stevemar) wrote :

Final patch to close out the bug: https://review.openstack.org/#/c/409010/4

Changed in keystone:
assignee: Steve Martinelli (stevemar) → Richard (csravelar)
Revision history for this message
OpenStack Infra (hudson-openstack) wrote :

Reviewed: https://review.openstack.org/409010
Committed: https://git.openstack.org/cgit/openstack/keystone/commit/?id=34f1201a2f1250d77ca21c51e89c2edd313c8597
Submitter: Jenkins
Branch: master

commit 34f1201a2f1250d77ca21c51e89c2edd313c8597
Author: “Richard <email address hidden>
Date: Fri Dec 9 08:13:15 2016 +0000

    Add id to conflict error if caused by duplicate id

    This patch adds test coverage for duplicate erros on objects that
    would raise an exception conflict by duplicate ids. It also adds
    the id of the object in place of the name in the duplicate error
    message if a name field for the object cannot be found.

    Closes-Bug: #1599296

    Change-Id: Ief9ef3d29ee9ac2da1c205247601399fb6f79d7b

Changed in keystone:
status: In Progress → Fix Released
Changed in keystone:
milestone: none → ocata-2
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix included in openstack/keystone 11.0.0.0b2

This issue was fixed in the openstack/keystone 11.0.0.0b2 development milestone.

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Change abandoned on keystone (master)

Change abandoned by Steve Martinelli (<email address hidden>) on branch: master
Review: https://review.openstack.org/337892
Reason: this was fixed by https://review.openstack.org/409010

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.