Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Audit record for PUTs should not always use "Update" #2471

Closed
d0roppe opened this issue Jun 4, 2021 · 3 comments
Closed

Audit record for PUTs should not always use "Update" #2471

d0roppe opened this issue Jun 4, 2021 · 3 comments
Assignees
Labels
audit P2 Priority 2 - Should Have

Comments

@d0roppe
Copy link
Collaborator

d0roppe commented Jun 4, 2021

Is your feature request related to a problem? Please describe.
With Audit records on, anything with the PUT command is always treated as an update even when you get a 201 return code, and that is for created.

Describe the solution you'd like
Every PUT that gets a return code of 201 should be treated as a create in the audit record.

Describe alternatives you've considered
A clear and concise description of any alternative solutions or features you've considered.

Acceptance Criteria

  1. GIVEN [a precondition]
    AND [another precondition]
    WHEN [test step]
    AND [test step]
    THEN [verification step]
    AND [verification step]

Additional context
If you are creating a resource that is not version 1 of the resource, should that be also treated as a create if you got a 201. Same for a delete, should that be treated as an update or a delete if it is a soft delete?

@d0roppe d0roppe added the audit label Jun 4, 2021
@lmsurpre lmsurpre changed the title Audit record for batch bundle and single entries using PUT should not always use "Update" Audit record for PUTs should not always use "Update" Aug 16, 2021
@lmsurpre lmsurpre added the P2 Priority 2 - Should Have label Aug 16, 2021
@lmsurpre
Copy link
Member

We do distinguish between creates and updates (for PUTs) for our whole-system history implementation. Please consult that.

@prb112 prb112 self-assigned this Oct 25, 2021
@prb112 prb112 added this to the Sprint 2021-15 milestone Oct 25, 2021
prb112 added a commit that referenced this issue Nov 5, 2021
Signed-off-by: Paul Bastide <pbastide@us.ibm.com>
lmsurpre added a commit that referenced this issue Nov 8, 2021
Audit record for PUTs should not always use "Update" #2471
@d0roppe
Copy link
Collaborator Author

d0roppe commented Nov 9, 2021

Now every Put is recorded as a create in the Audit record. So moving this back to in progress.

@d0roppe
Copy link
Collaborator Author

d0roppe commented Nov 12, 2021

Verified that the Put with a 200 return code is a Update, and a put with a 201 return code is a Create. Verified the same behavior for bulk data import. Closing issue.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
audit P2 Priority 2 - Should Have
Projects
None yet
Development

No branches or pull requests

3 participants