Abstract away "database" implementations and remove strong coupling of DB implementation with APIs#46
Open
smukil wants to merge 3 commits intocloudspannerecosystem:mainfrom
Open
Conversation
- Also removes cloud-spanner specific fields from the return type. Specifically `StructType.Field` is removed from the return type. Removing this tightly coupled logic is required to allow new DB implementations.
ac38a61 to
e7383eb
Compare
…f DB implementation with APIs 1. Abstracts SpannerDatabase with clear APIs 2. Introduces CloudSpannerDatabase as an implementation of SpannerDatabase 3. Removes further tight coupling with the cloud spanner client by adding a SpannerFieldInfo dataclass to replace usage of StructType.Field
f4b7635 to
e0068d8
Compare
1. The global database_instances is moved to exec_env.py to avoid circular imports. 2. SpannerFiledInfo.typename populated with the correct name now 3. Remove all cloud spanner refs from database.py
e0068d8 to
652a073
Compare
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Commit 1:- Standardize return type for execute_query() functions
Commit 2:-
SpannerFieldInfo dataclass to replace usage of StructType.Field