Skip to content
This repository was archived by the owner on Nov 24, 2025. It is now read-only.

Locking down snap/ queue/ update status endpoints for a CDN#5930

Merged
ocket8888 merged 6 commits intoapache:masterfrom
srijeet0406:CDN-12819
Jun 23, 2021
Merged

Locking down snap/ queue/ update status endpoints for a CDN#5930
ocket8888 merged 6 commits intoapache:masterfrom
srijeet0406:CDN-12819

Conversation

@srijeet0406
Copy link
Copy Markdown
Contributor

What does this PR (Pull Request) do?

  • This PR is not related to any Issue
    This PR adds the cdn locking capability to the snap/ queue/ update status endpoints.

Which Traffic Control components are affected by this PR?

  • Traffic Ops
  • CI tests

What is the best way to verify this PR?

Make sure all the unit/ API tests pass.
Run TO and TP locally.
As user A, send an API request to grab the lock for a particular CDN foo.
Now, try to snap foo as user A -> this should succeed
After this, log in to TO as another user B, and try to snap foo as user B -> this should fail because A has the lock for foo
Try to snap any other CDN as user B or A -> both operations should pass
Repeat the same tests for queueing and updating status of he servers on a CDN

If this is a bug fix, what versions of Traffic Control are affected?

  • master

The following criteria are ALL met by this PR

  • This PR includes tests
  • This PR does not include documentation
  • This PR does not include an update to CHANGELOG.md
  • This PR includes any and all required license headers
  • This PR DOES NOT FIX A SERIOUS SECURITY VULNERABILITY (see the Apache Software Foundation's security guidelines for details)

Additional Information

@ocket8888 ocket8888 added new feature A new feature, capability or behavior Traffic Ops related to Traffic Ops labels Jun 14, 2021
@ocket8888 ocket8888 self-assigned this Jun 14, 2021
Copy link
Copy Markdown
Contributor

@ocket8888 ocket8888 left a comment

Choose a reason for hiding this comment

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

Functionality works as described, the only failing tests are the ones that are failing currently on master due to known locale issues.

@ocket8888 ocket8888 merged commit bba3dc4 into apache:master Jun 23, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

new feature A new feature, capability or behavior Traffic Ops related to Traffic Ops

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants