Skip to content

Add adapter logic that calls spanner to create user saved search#1245

Merged
jcscottiii merged 1 commit intomainfrom
jcscottiii/adapter-create-user-saved-search
Mar 10, 2025
Merged

Add adapter logic that calls spanner to create user saved search#1245
jcscottiii merged 1 commit intomainfrom
jcscottiii/adapter-create-user-saved-search

Conversation

@jcscottiii
Copy link
Collaborator

@jcscottiii jcscottiii commented Mar 8, 2025

This is the layer between the httpserver and spanner.

It parses out the error if the user has too many saved searches.

After Spanner returns the ID, the adapter layer gets the full details from Spanner in a separate call. With the full details, it translates it into the SavedSearchResponse that is eventually returned.

Possible future changes

  • In the future, we could change the spanner logic to get the full details in a separate transaction after the row is created. This would simplify the adapter layer. But we would need to look at the other places that use CreateNewUserSavedSearch.

@jcscottiii jcscottiii requested review from KyleJu and jrobbins March 8, 2025 00:33
This is the layer between the httpserver and spanner.

It parses out the error if the user has too many saved searches.
@jcscottiii jcscottiii force-pushed the jcscottiii/adapter-create-user-saved-search branch from d1c9944 to 1ec4682 Compare March 10, 2025 00:01
@jcscottiii jcscottiii added this pull request to the merge queue Mar 10, 2025
Merged via the queue into main with commit 7900860 Mar 10, 2025
6 checks passed
@jcscottiii jcscottiii deleted the jcscottiii/adapter-create-user-saved-search branch March 10, 2025 18:17
@jcscottiii jcscottiii mentioned this pull request Mar 12, 2025
@jcscottiii jcscottiii linked an issue Mar 13, 2025 that may be closed by this pull request
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.

[ENHANCEMENT] Backend has piping to create and delete saved searches

2 participants