Simon Data user story

Check out the user story from Simon Data at How Simon Data addressed their runaway analytics complexity with Cube.js - Cube.js Blog.

Learn how Cube.js is deployed at Simon Data to deliver speed, flexibility, and stability for their customer data platform :rocket: :fireworks:

This is an incredible implementation that resonates well with my use case. Would love to hear more about the tech behind the schema versioning and how the data warehouse views match the cube.

1 Like

Thanks @Ethan_Veres and welcome to the Cube.js forum :smiley:

All credit for the blog post goes to Louis Zuckerman. Heโ€™ll be on the monthly community call tomorrow (May 12th) at 9 am PT to discuss the user story.

Hi @Ethan_Veres, and thanks for the great question.

In our framework the Cube and View are tightly coupled and need to be constructed together specifically for the queries theyโ€™ll serve. We built this framework to support a developer building all three (Query, Cube, and View) at once on their laptop along with the web application features that rely on them.

We wanted to make development iteration for this part of the process as quick and convenient as possible, since it canโ€™t be automated, and then automate everything else around deploying it to eliminate tedious repetition and minimize errors.

The View is the dynamic part that changes when deploying into snowflake, and this is how we can deploy common, reusable cubes into data warehouses with different tables. The details of how we do that are very specific to our implementation but the general idea is writing the Views as templates (a SELECT statement with variables for the table and column names in the FROM clauses) and then rendering the template with parameters specific to each data warehouse it is being deployed into.

As for schema versioning, Cube.js supports this via authentication token payload properties. You can include the information you need to select a schema (name, version, whatever) in the token when sending requests to Cube.js server. Then in your Cube.js server config you can read the schema info properties from the auth token and use them to set the app ID (contextToAppId) and fetch cubes (repositoryFactory) for the schema version from your API or from files bundled with the Cube.js server.

I hope this helps. Happy hacking!

1 Like

:bowing_man: @louiszuckerman.

The schema versioning discussion can also be found at the 24:52 mark of the monthly call recording