Implement V3Event API (EventCollectionDate) with Spanner backend#1810
Implement V3Event API (EventCollectionDate) with Spanner backend#1810keyurva merged 11 commits intodatacommonsorg:masterfrom
Conversation
Summary of ChangesHello, I'm Gemini Code Assist1! I'm currently reviewing this pull request and will post my feedback shortly. In the meantime, here's a summary to help you and other reviewers quickly get up to speed! This pull request introduces a new V3Event API endpoint focused on retrieving event collection dates. It establishes a robust data flow from the API request through the dispatcher and datasource layers, leveraging a Spanner backend for efficient data retrieval. The changes also include necessary updates to the protobuf and gRPC infrastructure, ensuring the new API is fully integrated and performant. Highlights
Changelog
Using Gemini Code AssistThe full guide for Gemini Code Assist can be found on our documentation page, here are some quick tips. Invoking Gemini You can request assistance from Gemini at any point by creating a comment using either
Customization To customize Gemini Code Assist for GitHub experience, repository maintainers can create a configuration file and/or provide a custom code review style guide (such as PEP-8 for Python) by creating and adding files to a Limitations & Feedback Gemini Code Assist may make mistakes. Please leave feedback on any instances where its feedback is incorrect or counter productive. You can react with 👍 and 👎 on @gemini-code-assist comments. If you're interested in giving your feedback about your experience with Gemini Code Assist for GitHub and other Google products, sign up here. You can also get AI-powered code generation, chat, as well as code reviews directly in the IDE at no cost with the Gemini Code Assist IDE Extension. Footnotes
|
There was a problem hiding this comment.
Code Review
This pull request successfully implements the V3Event API, specifically for EventCollectionDate requests, with a Spanner backend. The changes are well-structured, spanning from the protobuf definitions to the data source implementations. New query logic for Spanner is introduced, accompanied by thorough tests and golden files. The necessary wiring through the dispatcher, handler, and caching layers is also correctly handled. I have one suggestion for the remote client implementation to maintain consistency with repository guidelines.
89787e5 to
856e8ee
Compare
juliawu
left a comment
There was a problem hiding this comment.
Thank you for hooking this up, and adding tests!
| RETURN DISTINCT | ||
| SUBSTR(dateNode.value, 1, 7) AS month | ||
| ORDER BY | ||
| month`, |
There was a problem hiding this comment.
Can you tell me a bit more about why "month" is the right time resolution to use here?
There was a problem hiding this comment.
After chatting with Natalie, it seems that month is the finest level of granularity we support for events:
Line 29 in 81b8f27
keyurva
left a comment
There was a problem hiding this comment.
Thanks for the review!
| RETURN DISTINCT | ||
| SUBSTR(dateNode.value, 1, 7) AS month | ||
| ORDER BY | ||
| month`, |
There was a problem hiding this comment.
After chatting with Natalie, it seems that month is the finest level of granularity we support for events:
Line 29 in 81b8f27
1cc7a2d
force_join_orderhint suggested by the spanner team.v2/eventon prod and the newv3/eventendpoint locally for the requestnode=country/LBR&property=<-location{typeOf:FireEvent}->dateand the responses were the same.country/USAwere different. Will follow-up separately with Natalie if its a data issue or if we need to update the query.country/USA