Skip to content

ATLAS-5400: Fix PUT response when blocking from empty blocked list - #749

Open
sheetalshah1007 wants to merge 1 commit into
apache:masterfrom
sheetalshah1007:ATLAS-5400
Open

ATLAS-5400: Fix PUT response when blocking from empty blocked list#749
sheetalshah1007 wants to merge 1 commit into
apache:masterfrom
sheetalshah1007:ATLAS-5400

Conversation

@sheetalshah1007

Copy link
Copy Markdown
Contributor

What changes were proposed in this pull request?

Follow-up to ATLAS-5375 (#729).
If the blocked list on a relationship was empty and a client blocked a tag, the graph was updated correctly — but the PUT response could still show the old edge (tag propagated, nothing blocked). GET right after PUT showed the right state.

This patch fixes that PUT response for empty → blocked (first block and block after unblock):

  • Write the blocked list with remove-then-set (copy-on-write)
  • Read it back with getListProperty, matching how it is written
  • Reload the relationship edge before building the PUT body

Entity tag updates still run in the background; no API change.

How was this patch tested?

  • Tested the scenario manually on running Atlas server
  • Additionally, added a test which checks that blocking from an empty list updates PUT and GET before the background task finishes. Existing unblock tests still pass.
    mvn -pl repository -Dtest=ClassificationPropagationWithTasksTest,ClassificationPropagationTasksTest,ClassificationTaskTest,ClassificationPropagateTaskFactoryTest test

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.

1 participant