The ZetaSQL Toolkit is a library that helps users use ZetaSQL Java API to perform SQL analysis for multiple query engines, including BigQuery and Cloud Spanner.
Adds support for creating catalog that use resources defined in a JSON object. This is primarily intended for testing purposes, so that users don't need to write their own [BigQuery/Spanner]ResourceProvider for simple testing.
It achieves it by:
Introducing the CatalogResources dataclass and a way to deserialize from a JSON object
Creates resource provider implementations for both BigQuery and Spanner that use a CatalogResources object
Adds support for creating catalog that use resources defined in a JSON object. This is primarily intended for testing purposes, so that users don't need to write their own
[BigQuery/Spanner]ResourceProvider
for simple testing.It achieves it by:
CatalogResources
dataclass and a way to deserialize from a JSON objectCatalogResources
objectExample: