Skip to content

Add ExactMatch flag to packages API #33544

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

Closed
PulsarFX opened this issue Feb 10, 2025 · 1 comment · Fixed by #34173
Closed

Add ExactMatch flag to packages API #33544

PulsarFX opened this issue Feb 10, 2025 · 1 comment · Fixed by #34173
Labels
topic/packages type/proposal The new feature has not been accepted yet but needs to be discussed first.
Milestone

Comments

@PulsarFX
Copy link

Feature Description

Currently the API for /packages/{owner} localhost:3000/api/swagger/package/listPackages
(Gets all packages of an owner)
is defined with the following parameters:

  • page number
  • limit items
  • type of package
  • q name filter

The problem is, that the name filter is treated with the LIKE operator. There is no way to do an exact name search.

-> Please add a flag to do an exact name search.

Background:
Our repository is very, very big with lots of nuget packages (100k packages and counting) that share parts of the same name, like a base package package.name.part and lots of specialized packages like package.name.part.subA, package.name.part.subB, ...

there is no way to filter for package.name.part, as it will always include all other packages aswell. This makes it impossible to do a performant lookup of what is present in the registry. Or is there?
Currently I query the whole registry which takes about 5 minutes to finish using package/listPackages with not q filter and do the grouping in code.
Earlier I used the nuget api directly, but it is much slower than listPackages.

-> It would be nice to have an API where the latest version of each package could be fetched, and then an API to get all versions of an package.

Screenshots

No response

@PulsarFX PulsarFX added the type/proposal The new feature has not been accepted yet but needs to be discussed first. label Feb 10, 2025
@KN4CK3R
Copy link
Member

KN4CK3R commented Apr 10, 2025

Added with #34173.

@lunny lunny added this to the 1.24.0 milestone Apr 10, 2025
@lunny lunny closed this as completed in bec9233 Apr 13, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
topic/packages type/proposal The new feature has not been accepted yet but needs to be discussed first.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants