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

Advanced visibility for SQLite #3895

Merged
merged 1 commit into from
Feb 3, 2023

Conversation

rodrigozhou
Copy link
Collaborator

What changed?
Implement SQLite query converter for advanced visibility.
Update sqlite/visibility.go DB interface to advanced visibility.

Why?
Support advanced visibility for SQLite.

How did you test it?
Existing tests.
Started local server, and ran samples with custom search attributes.

Potential risks
None, sqlite is supported only for dev, and mostly using in-memory database.

Is hotfix candidate?
No.

@rodrigozhou rodrigozhou requested a review from a team as a code owner February 3, 2023 00:13
@@ -204,5 +204,7 @@ func buildDSNAttr(cfg *config.SQL) (url.Values, error) {
// assume pragma
parameters.Add("_pragma", fmt.Sprintf("%s=%s", key, value))
}
// set time format
parameters.Add("_time_format", "sqlite")
Copy link
Collaborator Author

Choose a reason for hiding this comment

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

This line to make the SQLite driver module to format datetime using a supported SQLite format for datetime. Previously, without this setting, it was using time.String() to write datetime to the table.

Copy link
Member

@alexshtin alexshtin left a comment

Choose a reason for hiding this comment

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

Reviewed together with @rodrigozhou. Some minor issues needs to be addressed but generally LGTM.

@rodrigozhou rodrigozhou merged commit bd2d3b3 into temporalio:master Feb 3, 2023
@rodrigozhou rodrigozhou deleted the adv-vis-sqlite branch February 3, 2023 08:47
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.

2 participants