-
Notifications
You must be signed in to change notification settings - Fork 1.9k
docs(getting-started): revamp Getting Started #6013
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
Merged
Merged
Changes from all commits
Commits
Show all changes
13 commits
Select commit
Hold shift + click to select a range
221e03e
docs(getting-started): revamp Getting Started guide for Cloud and Ope…
hassankhan 76f970b
Rewrite Overview
igorlukanin 4cc947d
Rewrite Overviews
igorlukanin 60dd38c
Rewrite Overviews, once again
igorlukanin 7424481
Add Btn (inline button)
igorlukanin cd53533
Make images span full width
igorlukanin 8a3ad7f
Edit Cloud pages
igorlukanin 119dc20
Edit Core pages
igorlukanin cb08466
Lint
igorlukanin da0683d
docs: more
hassankhan c200e26
Fix
igorlukanin eb20886
docs: fixup
hassankhan aad037b
docs: fixup
hassankhan File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
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
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
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,24 @@ | ||
| --- | ||
| title: Getting started with Cube Cloud | ||
| permalink: /getting-started/cloud/overview | ||
| category: Getting Started | ||
| subCategory: Cube Cloud | ||
| menuOrder: 2 | ||
| --- | ||
|
|
||
| First, we'll create a new deployment, connect it to a database, and generate a | ||
| data model from it. Then, we'll run queries using the Developer Playground and | ||
| APIs. Finally, we'll add a pre-aggregation to optimize query latency down to | ||
| milliseconds. | ||
|
|
||
| This guide will walk you through the following tasks: | ||
|
|
||
| - [Create a new deployment](/getting-started/cloud/create-a-deployment) | ||
| - [Generate a data model from a connected data source](/getting-started/cloud/generate-models) | ||
| - [Run queries using the Developer Playground and APIs](/getting-started/cloud/query-data) | ||
| - [Add a pre-aggregation to optimize query performance](/getting-started/cloud/add-a-pre-aggregation) | ||
|
|
||
| If you'd prefer to run Cube locally, then you can refer to [Getting Started | ||
| using Cube Core][ref-getting-started-core-overview] instead. | ||
|
|
||
| [ref-getting-started-core-overview]: /getting-started/core/overview |
125 changes: 125 additions & 0 deletions
125
docs/content/Getting-Started/Cloud/02-Create-a-deployment.mdx
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
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,125 @@ | ||
| --- | ||
| title: Create a deployment | ||
| permalink: /getting-started/cloud/create-a-deployment | ||
| category: Getting Started | ||
| subCategory: Cube Cloud | ||
| menuOrder: 3 | ||
| --- | ||
|
|
||
| In this step, we will create a new deployment in Cube Cloud. A deployment | ||
| represents a data model, configuration, and managed infrastructure. We will use | ||
| it to connect a data source and generate data models. | ||
|
|
||
| ## Create an account | ||
|
|
||
| To continue with this guide, you'll need to have a Cube Cloud account. If you | ||
| don't have one yet, [click here to sign up][cube-cloud-signup] for free. | ||
|
|
||
| ## Create a deployment | ||
|
|
||
| First, [sign in to your Cube Cloud account][cube-cloud-signin]. Then, | ||
| click <Btn>Create Deployment</Btn>: | ||
|
|
||
| <div style="text-align: center"> | ||
| <img | ||
| alt="Cube Cloud Landing Screen with no configured deployments" | ||
| src="https://ucarecdn.com/f3ec1ae0-1d5d-4b5b-9859-9fc145b38e43/" | ||
| style="border: none" | ||
| width="80%" | ||
| /> | ||
| </div> | ||
|
|
||
| Give the deployment a name, select the cloud provider and region of your choice, | ||
| and click <Btn>Next</Btn>: | ||
|
|
||
| <div style="text-align: center"> | ||
| <img | ||
| alt="Cube Cloud Create Deployment Screen" | ||
| src="https://ucarecdn.com/2338323e-0db8-4224-8e7a-3b4daf9c60ec/" | ||
| style="border: none" | ||
| width="80%" | ||
| /> | ||
| </div> | ||
|
|
||
| ## Set up a Cube project | ||
|
|
||
| Next, click <Btn>Create</Btn> to create a new project from scratch: | ||
|
|
||
| <div style="text-align: center"> | ||
| <img | ||
| alt="Cube Cloud Upload Project Screen" | ||
| src="https://ucarecdn.com/46b72b61-b650-4271-808d-55203f1c8d8b/" | ||
| style="border: none" | ||
| width="80%" | ||
| /> | ||
| </div> | ||
|
|
||
| ## Connect a data source | ||
|
|
||
| The last step in creating a deployment is to connect your data source to Cube | ||
| Cloud. First, select the data source from the grid: | ||
|
|
||
| <div style="text-align: center"> | ||
| <img | ||
| alt="Cube Cloud Setup Database Screen" | ||
| src="https://ucarecdn.com/1d656ba9-dd83-4ff4-a59e-8b5f97a9ddcc/" | ||
| style="border: none" | ||
| width="80%" | ||
| /> | ||
| </div> | ||
|
|
||
| <InfoBox> | ||
|
|
||
| Want to use a sample database instead? Select <Btn>PostgreSQL</Btn> and use the | ||
| credentials below: | ||
|
|
||
| <br /> | ||
|
|
||
| | Field | Value | | ||
| | -------- | ------------------ | | ||
| | Host | `demo-db.cube.dev` | | ||
| | Port | `5432` | | ||
| | Database | `ecom` | | ||
| | Username | `cube` | | ||
| | Password | `12345` | | ||
|
|
||
| </InfoBox> | ||
|
|
||
| After selecting the data source, enter valid credentials for it and | ||
| click <Btn>Apply</Btn>. Check the [Connecting to Databases][ref-conf-db] | ||
| page for more details on specific data sources. | ||
|
|
||
| <div style="text-align: center"> | ||
| <img | ||
| alt="Cube Cloud Setup Database Screen" | ||
| src="https://ucarecdn.com/1ccdb149-bcf3-4426-9103-986f092939b7/" | ||
| style="border: none" | ||
| width="80%" | ||
| /> | ||
| </div> | ||
|
|
||
| If you run into issues here, make sure to allow inbound connections from Cube | ||
| Cloud IP addresses to your database. This means you need to enable these IPs in | ||
| your firewall. Using the screenshot in the example above, if you are using AWS, | ||
| this would mean adding new [rules][aws-docs-sec-group-rule] to your database's | ||
| [security group][aws-docs-sec-group]: | ||
|
|
||
| | Source | Protocol | Port range | | ||
| | --------------- | -------- | ---------- | | ||
| | `3.65.255.79` | `TCP` | `5432` | | ||
| | `3.69.4.168` | `TCP` | `5432` | | ||
| | `3.64.153.169` | `TCP` | `5432` | | ||
| | `18.185.128.84` | `TCP` | `5432` | | ||
|
|
||
| Now that the deployment is configured, we can move on to [generating data | ||
| models][ref-getting-started-cloud-generate-models]. | ||
|
|
||
| [aws-docs-sec-group]: | ||
| https://docs.aws.amazon.com/vpc/latest/userguide/security-groups.html | ||
| [aws-docs-sec-group-rule]: | ||
| https://docs.aws.amazon.com/vpc/latest/userguide/security-group-rules.html | ||
| [cube-cloud-signin]: https://cubecloud.dev/auth | ||
| [cube-cloud-signup]: https://cubecloud.dev/auth/signup | ||
| [ref-conf-db]: /config/databases | ||
| [ref-getting-started-cloud-generate-models]: | ||
| /getting-started/cloud/generate-models |
104 changes: 104 additions & 0 deletions
104
docs/content/Getting-Started/Cloud/03-Generate-models.mdx
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
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,104 @@ | ||
| --- | ||
| title: Generate data models | ||
| permalink: /getting-started/cloud/generate-models | ||
| category: Getting Started | ||
| subCategory: Cube Cloud | ||
| menuOrder: 4 | ||
| --- | ||
|
|
||
| In this step, you will generate data models using the connected data source from | ||
| the last step. | ||
|
|
||
| Cube's data models provide a declarative way to define important facts about | ||
| your data and relationships between them. You can create data models from | ||
| scratch or let Cube generate an initial version for you. | ||
|
|
||
| ## Select tables | ||
|
|
||
| Start by selecting the database tables to generate the data schema from, then | ||
| click <Btn>Measures and Dimensions</Btn>: | ||
|
|
||
| <div style="text-align: center"> | ||
| <img | ||
| alt="Cube Cloud Generate Models Screen detected tables from data source for selection" | ||
| src="https://ucarecdn.com/e0420b86-64bc-4e01-aa74-16a7e926f523/" | ||
| style="border: none" | ||
| width="80%" | ||
| /> | ||
| </div> | ||
|
|
||
| ## Measures and dimensions | ||
|
|
||
| Next, you'll see all detected measures and dimensions from the data source. | ||
| Click <Btn>Primary Keys</Btn> to progress to the next step: | ||
|
|
||
| <div style="text-align: center"> | ||
| <img | ||
| alt="Cube Cloud Generate Models Screen showing detected measures and dimensions" | ||
| src="https://ucarecdn.com/e0f8e8c3-9961-4360-ab9f-cfd96306c832/" | ||
| style="border: none" | ||
| width="80%" | ||
| /> | ||
| </div> | ||
|
|
||
| ## Primary keys | ||
|
|
||
| Review the detected primary keys for each cube and click <Btn>Joins</Btn> to | ||
| move to the next step: | ||
|
|
||
| <div style="text-align: center"> | ||
| <img | ||
| alt="Cube Cloud Generate Models Screen showing detected primary keys" | ||
| src="https://ucarecdn.com/e13e8279-e9e9-40df-b8f6-8cf5bb34ee14/" | ||
| style="border: none" | ||
| width="80%" | ||
| /> | ||
| </div> | ||
|
|
||
| ## Joins | ||
|
|
||
| Once again, review the detected joins and relationships and click | ||
|
|
||
| <Btn>Review</Btn>: | ||
|
|
||
| <div style="text-align: center"> | ||
| <img | ||
| alt="Cube Cloud Generate Models Screen showing detected joins" | ||
| src="https://ucarecdn.com/8190bd70-e4e3-4e9f-9cee-e9416ddf964b/" | ||
| style="border: none" | ||
| width="80%" | ||
| /> | ||
| </div> | ||
|
|
||
| ## Review | ||
|
|
||
| The last screen allows you to review all the detected cubes and their | ||
| corresponding measures, dimensions, and joins. If everything looks good, pick | ||
| either <Btn>YAML</Btn> (recommended) or <Btn>JavaScript</Btn> format and | ||
| click <Btn>Confirm & Generate</Btn>: | ||
|
|
||
| <div style="text-align: center"> | ||
| <img | ||
| alt="Cube Cloud Generate Models Screen showing review screen" | ||
| src="https://ucarecdn.com/59e18ad2-b8fc-48dc-b409-d829579048f5/" | ||
| style="border: none" | ||
| width="80%" | ||
| /> | ||
| </div> | ||
|
|
||
| Cube Cloud will now generate the models and spin up your Cube deployment, and in | ||
| a few moments you should see the following screen: | ||
|
|
||
| <div style="text-align: center"> | ||
| <img | ||
| alt="Cube Cloud Deployment Overview Screen" | ||
| src="https://ucarecdn.com/7fa603ae-6100-4492-91e4-564d311f701e/" | ||
| style="border: none" | ||
| width="80%" | ||
| /> | ||
| </div> | ||
|
|
||
| You're now ready for the next step, [querying the | ||
| data][ref-getting-started-cloud-query-cube]. | ||
|
|
||
| [ref-getting-started-cloud-query-cube]: /getting-started/cloud/query-data | ||
Oops, something went wrong.
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.
Uh oh!
There was an error while loading. Please reload this page.