NASA-PDS / registry-mgr

Standalone Registry Manager application responsible for managing the PDS Registry (https://github.com/NASA-PDS/registry) schemas and indexes.
https://nasa-pds.github.io/registry
Other
0 stars 2 forks source link

As a user, I want to query OpenSearch for staged data via a CLI command #59

Closed alexdunnjpl closed 1 year ago

alexdunnjpl commented 1 year ago

This is a duplicate/extension of a corresponding registry ticket

📖 Additional Details

@jordanpadams to suggest details for this new registry-mgr subcommand.

⚖️ Acceptance Criteria

Given When I perform Then I expect

⚙️ Engineering Details

jordanpadams commented 1 year ago

@alexdunnjpl I think the last option sounds best:

or do we want to provide just a raw query interface like registry-mgr query-products @path-to-some-file.json

Then we can provide a cookbook of JSON "recipes" for various queries people may want to perform. this way we can build up this cookbook and just link off to the various JSON files.

@tloubrieu-jpl @alexdunnjpl thoughts?

alexdunnjpl commented 1 year ago

@jordanpadams If that's the case, what's the difference between our new CLI command (which will presumably still take OpenSearch URL and auth file as arguments), and a simple-enough curl call?

Arguably we're abstracting away the implementation detail of our backend being OpenSearch, but is that useful?

I think that if we're going to bother to do this, it may be worth considering unifying the configuration (OS url, auth, etc) within a single file - assuming that the typical use-case is that a single deployment works with a single OpenSearch instance. Then you actually get some return on investment because you can

registry-mgr query @path/to/something.json

and the need to point to your OS instance and auth file is obviated.

Does that scan?

tloubrieu-jpl commented 1 year ago

The registry dashboards are fulfilling this requirement, see https://github.com/NASA-PDS/registry/issues/148