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

add CMR graphql functionalities #61

Open
briannapagan opened this issue Jun 11, 2024 · 3 comments
Open

add CMR graphql functionalities #61

briannapagan opened this issue Jun 11, 2024 · 3 comments
Labels
enhancement New feature or request

Comments

@briannapagan
Copy link
Collaborator

NASA has created a GraphQL interface for accessing CMR: https://github.com/nasa/cmr-graphql

Some of the advantages of this way to query are supposed to be 1) performance and 2) the ability to search across different schemas, which can be a huge pain point for users of the regular CMR API. Internally we are beginning to pass code around to demonstrate how to pythonically call CMR-GraphQL, and I have been wondering whether those of us maintaining python_cmr should invest time to bring the ability to query from GraphQL as an option within python_cmr.

@mfisher87
Copy link

GraphQL's self-describing-ness is also huge. We could for example generate an API client: https://github.com/mirumee/ariadne-codegen

@frankinspace
Copy link
Collaborator

I agree adding support to query cmr's graphql endpoints should be on the roadmap for this library. IMO, this library should exclusively utilize CMR's graphql endpoints.

I also agree with @mfisher87 that we should utilize some level of code-generation to build out the library.

Perhaps it would make sense to add a cmr.graphql module so this option could be explored without breaking the existing interface? Eventually we might be able to start rewriting the existing functions to just call this new graphql module.

@frankinspace frankinspace added the enhancement New feature or request label Jun 11, 2024
@mfisher87
Copy link

I think based on some discussions during today's hack week @doug-newman-nasa may be able to provide some context about performance to this discussion. I think someone said that there are areas of the GraphQL API that are limited by CMR performance, and could technically perform worse, and this library could abstract away the need for that knowledge, always doing what's most performant.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

3 participants