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

[AUD-1833] Refactor "Get Tracks" endpoint #2855

Merged
merged 10 commits into from
Apr 7, 2022
Merged

Conversation

rickyrombo
Copy link
Contributor

Description

Updates the "Get Tracks" endpoint:

  • Renames "Get Tracks" to "Get Bulk Tracks"
  • Adds "permalink" query parameter
  • Removes "route", "slug", and "handle" parameters from documentation without breaking backwards compatibility
  • Fixes response documentation without breaking backwards compatibility
  • Adds support for getting multiple tracks by IDs

Removes new "Get Tracks By Ids" endpoint:

  • Double checked that we're not calling it anywhere in AudiusProject repos
  • Seems redundant with "Get Bulk Tracks"

Tests

  • Verified the Swagger output shows "Get Bulk Tracks" and a list response
  • Checked that using slug/handle still gives a single object response (if no routes/permalinks present)
  • Checked that using route still works for one or many tracks
  • Checked that using ids works for one or many tracks
  • Checked that using new permalink param works for one or many tracks

How will this change be monitored? Are there sufficient logs?

❗ looking for ideas here.

@rickyrombo rickyrombo added the discovery-node Discovery Node (previously known as Discovery Provider) label Apr 6, 2022
Copy link
Member

@raymondjacobson raymondjacobson left a comment

Choose a reason for hiding this comment

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

Let's just make sure to soak this well on staging

discovery-provider/src/api/v1/tracks.py Show resolved Hide resolved
discovery-provider/src/api/v1/tracks.py Show resolved Hide resolved
discovery-provider/src/api/v1/tracks.py Outdated Show resolved Hide resolved
@gitguardian
Copy link

gitguardian bot commented Apr 7, 2022

⚠️ GitGuardian has uncovered 2 secrets following the scan of your pull request.

Please consider investigating the findings and remediating the incidents. Failure to do so may lead to compromising the associated services or software components.

🔎 Detected hardcoded secrets in your pull request
GitGuardian id Secret Commit Filename
3086103 Generic High Entropy Secret 7989a5d discovery-provider/integration_tests/tasks/test_anchor_program_indexer.py View secret
3086103 Generic High Entropy Secret 648c889 discovery-provider/integration_tests/tasks/test_anchor_program_indexer.py View secret
🛠 Guidelines to remediate hardcoded secrets
  1. Understand the implications of revoking this secret by investigating where it is used in your code.
  2. Replace and store your secrets safely. Learn here the best practices.
  3. Revoke and rotate these secrets.
  4. If possible, rewrite git history. Rewriting git history is not a trivial act. You might completely break other contributing developers' workflow and you risk accidentally deleting legitimate data.

To avoid such incidents in the future consider


🦉 GitGuardian detects secrets in your source code to help developers and security teams secure the modern development process. You are seeing this because you or someone else with access to this repository has authorized GitGuardian to scan your pull request.

Our GitHub checks need improvements? Share your feedbacks!

@rickyrombo rickyrombo merged commit bdd05e5 into master Apr 7, 2022
@rickyrombo rickyrombo deleted the mjp-get-bulk-tracks branch April 7, 2022 19:42
@AudiusProject AudiusProject deleted a comment from linear bot Sep 11, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
discovery-node Discovery Node (previously known as Discovery Provider) size/L
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants