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 synonym getters #2046

Merged

Conversation

Courey
Copy link
Contributor

@Courey Courey commented Mar 6, 2024

Title

feat: add gets to synonym server

Description

This PR adds 2 functions. One for getting synonyms by uuid and one for getting or searching synonyms by eventId.
The search utilizes opensearch.

Reviewers

@dakota002 - he can review this pr for style and syntax

Changes

Adds two server functions that are currently unused.

Acceptance Criteria

there are server functions to

  • get synonyms by uuid
  • get/search synonyms by eventId

Related Issue(s)

Resolves #1935

Testing

syntax and style only. Function is unused and we have not established our db testing methodology yet. A PR will be forthcoming with tests for this and all other functions in the server when that has been decided.

@Courey Courey requested a review from dakota002 March 6, 2024 19:47
Comment on lines 25 to 28
if (!Items.length)
throw new Response(null, {
status: 404,
})
Copy link
Contributor

Choose a reason for hiding this comment

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

This 404 response might be better moved to whatever routes end up using the function and just returning an empty array if none exist

@Courey Courey requested a review from dakota002 March 7, 2024 12:26
@dakota002
Copy link
Contributor

This PR should fix the CI issue: #2047

@Courey Courey force-pushed the courey/get_synonyms_by_ids_server_only branch from 80d8ad3 to 58f6eea Compare March 7, 2024 16:58
@dakota002 dakota002 merged commit c2a0ff7 into nasa-gcn:main Mar 7, 2024
5 checks passed
@Courey Courey deleted the courey/get_synonyms_by_ids_server_only branch March 7, 2024 16:59
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.

Create functions to get synonyms by uuid and by eventId
2 participants