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

Adding /api/artifacts/<group_id>/<artifact_id> endpoint #1008

Merged
merged 3 commits into from
Apr 19, 2022

Conversation

jyoo980
Copy link
Collaborator

@jyoo980 jyoo980 commented Apr 15, 2022

Summary of Work

Closes #998

jyoo980 added 2 commits April 14, 2022 09:44
  * New method: `WebDatabase#getArtifact(Artifact.groupId, Artifact.artifactId)
  * Tests added in:
    * `ArtifactTableTests.scala`
    * `SqlDatabaseTests.scala`
  * `Meta` instance created for `Artifact.ArtifactId`.
  * Endpoints added along with documentation, return value is of type
    `Page[ArtifactMetadataResponse]`.
  * `WebDatabase#getArtifact: Future[Option[Artifact]]` has been refactored to
    `WebDatabase#getArtifact: Future[Seq[Artifact]]` given the fact that there
     can be more than one artifact with the same `group_id` and `artifcact_id`
     can be diff. versions.
   * Tests added for endpoints.
@jyoo980 jyoo980 requested review from mlachkar and adpi2 April 15, 2022 15:50
@jyoo980 jyoo980 self-assigned this Apr 15, 2022
  * Adding a test for `/api/artifacts/<group_id>/<artifact_id>
    * Group id is invalid, but artifact id is valid.
    * Group id is valid, but artifact id is invalid.
Copy link
Member

@adpi2 adpi2 left a comment

Choose a reason for hiding this comment

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

Looks very good! Thanks!

@adpi2 adpi2 merged commit 561acb6 into main Apr 19, 2022
@jyoo980 jyoo980 deleted the yoo/add-artifact-data-endpoint branch April 19, 2022 16:26
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.

Add endpoint api/artifacts/<group_id>/<artifact_id> to obtain metadata for a given artifact
2 participants