WARNING: THIS SITE IS A MIRROR OF GITHUB.COM / IT CANNOT LOGIN OR REGISTER ACCOUNTS / THE CONTENTS ARE PROVIDED AS-IS / THIS SITE ASSUMES NO RESPONSIBILITY FOR ANY DISPLAYED CONTENT OR LINKS / IF YOU FOUND SOMETHING MAY NOT GOOD FOR EVERYONE, CONTACT ADMIN AT ilovescratch@foxmail.com
Skip to content

Conversation

@earies
Copy link

@earies earies commented Nov 18, 2022

Clarify that an Update to a list member targeted in the Path cannot include
those list keys in the value payload either as a direct descendant or ultimate
leafref'd node.

Since you cannot modify the list keys on a targeted Path, disallow the contents
altogether in the payload. At best, the same values could be specified but
since the Path is unprefixed while JSON_IETF encoding currently remains
prefixed, an association needs to be drawn from a schema set perspective.

In addition, this reduces pointless and redundant bytes on the wire.

@earies
Copy link
Author

earies commented Nov 18, 2022

@gcsl - PTAL - this just tightens up the protocol around disallowing list keys to be included in the value payload since they are immutable in this context

@earies
Copy link
Author

earies commented Jun 27, 2023

@dplore - looking for review here. This has been a long standing PR - it looks like some protocol needs to be put in place across various repos to ensure distribution of review - Thx

Copy link
Member

@dplore dplore left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

There is a behavioral change here regarding support for idempotent behavior that I don't think we want to make. See comments.

or replace message specifying a path of `/a/f[k1=10][k2=20]` setting the value
of `k1` to 100 MUST be considered erroneous, and a status code of
`InvalidArgument (3)` specified.
of `k1` to either the same value (10) or an alternate value (100) MUST be
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

To support idempotent behavior, I believe setting a node which is also a list key to the same value it already has should be permitted. Only changing the node's value must be an error.

path, and as their own elements within the value, then this MUST be considered
an error by the target system - and a status code of `InvalidArgument (3)`
specified. Targeting a list member with update or replace operations that
modify it's own keys in either conflicting or identical fashion is not
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

To support idempotent behavior, identical update/replace should be permitted. Agreed that conflicting node / list key values must return an error. I think that is already covered by the last bullet point in this stanza,

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants