Skip to content

Commit 1a7024b

Browse files
authored
Merge branch 'main' into ryans_patch
2 parents 7c8a6a5 + 6d58818 commit 1a7024b

File tree

531 files changed

+6737
-4246
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

531 files changed

+6737
-4246
lines changed

.gitignore

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,7 @@ yarn.lock
2929
yarn.error-log
3030
.comments
3131
yarn-error.log
32+
frontmatter-validation-errors.log
3233

3334
# Output files used by scripts to verify links
3435
sidebar_links.txt
@@ -57,5 +58,8 @@ docs/whats-new/changelog/index.md
5758
**.translate
5859
ClickHouse/
5960

60-
# Ignore generated table of contents files
61+
62+
# Ignore table of contents files
6163
docs/cloud/reference/release-notes-index.md
64+
docs/whats-new/changelog/index.md
65+
docs/cloud/manage/api/api-reference-index.md

clickhouseapi.js

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -40,8 +40,10 @@ function groupEndpointsByPrefix(spec) {
4040
}
4141

4242
function generateDocusaurusMarkdown(spec, groupedEndpoints, prefix) {
43-
let markdownContent = `---\nsidebar_label: ${prefix.charAt(0).toUpperCase() + prefix.slice(1)}\n`;
44-
markdownContent += `title: ${prefix.charAt(0).toUpperCase() + prefix.slice(1)}\n---\n`;
43+
let markdownContent = `---\nsidebar_label: '${prefix.charAt(0).toUpperCase() + prefix.slice(1)}'\n`;
44+
markdownContent += `title: '${prefix.charAt(0).toUpperCase() + prefix.slice(1)}'\n`;
45+
markdownContent += `slug: /cloud/manage/api/${prefix}-api-reference\n`;
46+
markdownContent += `description: 'Cloud API reference documentation for ${prefix}'\n---\n`;
4547

4648
for (const path in groupedEndpoints) {
4749
for (const method in groupedEndpoints[path]) {

contribute/contrib-writing-guide.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -265,6 +265,7 @@ slug: /integrations/sql-clients/clickhouse-client-local
265265
sidebar_label: clickhouse-client
266266
title: clickhouse-client and clickhouse-local
267267
---
268+
268269
import Tabs from '@theme/Tabs';
269270
import TabItem from '@theme/TabItem';
270271

contribute/style-guide.md

Lines changed: 89 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,21 +1,37 @@
11
# ClickHouse docs style guide
22

3-
In this document, you will find a number of style guidelines for writing documentation.
4-
The rules in this guide are intended to assist in helping us to create a high
5-
quality documentation offering on par with the quality of ClickHouse itself.
3+
In this document, you will find a number of style guidelines for writing ClickHouse
4+
documentation. As documentation is a collective effort, these guidelines are
5+
intended to help all of us ensure quality and consistency across our documentation.
66

77
## YAML front matter
88

9-
Begin every new markdown document with YAML front-matter:
9+
Begin every new Markdown document with YAML front-matter:
1010

1111
```markdown
1212
---
13-
title: Using a clickhouse-local database
14-
sidebar_label: Using clickhouse-local database
13+
title: 'Using a clickhouse-local database'
14+
sidebar_label: 'Using clickhouse-local database'
1515
slug: /chdb/guides/clickhouse-local
16-
description: Learn how to use a clickhouse-local database with chDB
17-
keywords: [chdb, clickhouse-local]
16+
description: 'Learn how to use a clickhouse-local database with chDB'
17+
keywords: ['chdb', 'clickhouse-local']
1818
---
19+
```
20+
21+
### Associated markdown rule or CI check
22+
23+
#### front-matter validation
24+
25+
There is a custom Docusaurus plugin which runs on build that makes the following
26+
checks on front-matter:
27+
28+
- title, description and slug are specified.
29+
- keywords use flow style arrays with single quoted items e.g.
30+
`keywords: ['integrations']`
31+
- single quotes are used for title, description, slug, sidebar_label
32+
- there is an empty line after the YAML frontmatter block
33+
34+
For implementation details see [plugins/frontmatter-validation](https://github.com/ClickHouse/clickhouse-docs/tree/main/plugins/frontmatter-validation)
1935

2036
## Explicit header tags
2137

@@ -91,6 +107,38 @@ Code blocks:
91107
- Have a title (optional) such as 'Query' or 'Response'
92108
- Use language `response` if it is for the result of a query.
93109

110+
### Highlighting
111+
112+
You can highlight lines in a code block using the following keywords:
113+
114+
- `highlight-next-line`
115+
- `highlight-start`
116+
- `highlight-end`
117+
118+
These keywords should be added as comments in the codeblock with the appropriate
119+
escape symbol for the codeblock language.
120+
121+
For example, if the codeblock is SQL:
122+
123+
```text
124+
SELECT UserID, count(UserID) AS Count
125+
-- highlight-next-line
126+
FROM mv_hits_URL_UserID
127+
WHERE URL = 'http://public_search'
128+
GROUP BY UserID
129+
ORDER BY Count DESC
130+
LIMIT 10;
131+
```
132+
133+
If the codeblock is a response:
134+
135+
```text
136+
10 rows in set. Elapsed: 0.026 sec.
137+
# highlight-next-line
138+
Processed 335.87 thousand rows,
139+
13.54 MB (12.91 million rows/s., 520.38 MB/s.)
140+
```
141+
94142
### Associated markdown rule or CI check
95143

96144
- [`MD040` enforces that codeblocks have a language specified](/scripts/.markdownlint-cli2.yaml)
@@ -158,4 +206,37 @@ export function Anchor(props) {
158206
```
159207
- Replace `<span id="some-id"></span>` with `Anchor id="some-id"/>`
160208

209+
### Floating pages
210+
211+
In order to prevent pages from becoming 'floating' or 'orphaned' it is
212+
necessary that you add a newly created page to `sidebars.js`. We have a [custom
213+
docusaurus plugin](plugins/checkFloatingPages.js) to catch dangling pages.
214+
215+
If there is some specific reason that you need to bypass this check, you can
216+
add an exception to `floating-pages-exceptions.txt` in the plugins directory.
217+
218+
When adding a new page from the ClickHouse/ClickHouse repo this check will fail
219+
unless the file is in a folder which [`sidebars.js`](https://github.com/ClickHouse/clickhouse-docs/blob/main/sidebars.js)
220+
uses with `type: autogenerated` to generate the navigation items from the markdown
221+
files in the folder.
222+
223+
If you've added a new page on ClickHouse/ClickHouse and this check is failing.
224+
225+
For example:
226+
227+
```text
228+
✅ All markdown files passed frontmatter validation.
229+
Loaded 3 exceptions from /opt/clickhouse-docs/plugins/floating-pages-exceptions.txt
230+
Skipping excepted page: index
231+
Skipping excepted page: integrations/language-clients/java/client-v1
232+
Skipping excepted page: integrations/language-clients/java/jdbc-v1
233+
�[31m1 floating pages found:�[0m
234+
- /opt/clickhouse-docs/docs/operations/query-condition-cache.md
235+
```
236+
237+
You will need to open a PR on docs repo to add this page to [`floating-pages-exceptions.txt`](https://github.com/ClickHouse/clickhouse-docs/blob/main/plugins/floating-pages-exceptions.txt). Once it is merged
238+
you can then rerun the docs check on the ClickHouse/ClickHouse repo which
239+
should pass. Finally open another PR on the docs repo again to remove the
240+
file from the exception list and add it to `sidebars.js` in the appropriate
241+
sidebar.
161242

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,9 @@
11
---
2+
description: 'Changelog for 2025'
3+
note: 'This file is autogenerated by the yarn new-build'
24
slug: /whats-new/changelog/
35
sidebar_position: 2
4-
sidebar_label: 2025
5-
title: 2025 Changelog
6-
note: This file is autogenerated by the yarn new-build
6+
sidebar_label: '2025'
7+
title: '2025 Changelog'
78
---
89

docs/_snippets/_GCS_authentication_and_bucket.md

Lines changed: 9 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -6,46 +6,47 @@ import GCS_create_service_account_a from '@site/static/images/integrations/data-
66
import GCS_create_service_account_2 from '@site/static/images/integrations/data-ingestion/s3/GCS-create-service-account-2.png';
77
import GCS_create_service_account_3 from '@site/static/images/integrations/data-ingestion/s3/GCS-create-service-account-3.png';
88
import GCS_guide_key from '@site/static/images/integrations/data-ingestion/s3/GCS-guide-key.png';
9+
import Image from '@theme/IdealImage';
910

1011
<details>
1112
<summary>Create GCS buckets and an HMAC key</summary>
1213

1314
### ch_bucket_us_east1 {#ch_bucket_us_east1}
1415

15-
<img src={GCS_bucket_1} alt="Creating a GCS bucket in US East 1" />
16+
<Image size="md" img={GCS_bucket_1} alt="Creating a GCS bucket in US East 1" border />
1617

1718
### ch_bucket_us_east4 {#ch_bucket_us_east4}
1819

19-
<img src={GCS_bucket_2} alt="Creating a GCS bucket in US East 4" />
20+
<Image size="md" img={GCS_bucket_2} alt="Creating a GCS bucket in US East 4" border />
2021

2122
### Generate an Access key {#generate-an-access-key}
2223

2324
### Create a service account HMAC key and secret {#create-a-service-account-hmac-key-and-secret}
2425

2526
Open **Cloud Storage > Settings > Interoperability** and either choose an existing **Access key**, or **CREATE A KEY FOR A SERVICE ACCOUNT**. This guide covers the path for creating a new key for a new service account.
2627

27-
<img src={GCS_create_service_account_key} alt="Generating a service account HMAC key in GCS" />
28+
<Image size="md" img={GCS_create_service_account_key} alt="Generating a service account HMAC key in GCS" border />
2829

2930
### Add a new service account {#add-a-new-service-account}
3031

3132
If this is a project with no existing service account, **CREATE NEW ACCOUNT**.
3233

33-
<img src={GCS_create_service_account_0} alt="Adding a new service account in GCS" />
34+
<Image size="md" img={GCS_create_service_account_0} alt="Adding a new service account in GCS" border />
3435

3536
There are three steps to creating the service account, in the first step give the account a meaningful name, ID, and description.
3637

37-
<img src={GCS_create_service_account_a} alt="Defining a new service account name and ID in GCS" />
38+
<Image size="md" img={GCS_create_service_account_a} alt="Defining a new service account name and ID in GCS" border />
3839

3940
In the Interoperability settings dialog the IAM role **Storage Object Admin** role is recommended; select that role in step two.
4041

41-
<img src={GCS_create_service_account_2} alt="Selecting IAM role Storage Object Admin in GCS" />
42+
<Image size="md" img={GCS_create_service_account_2} alt="Selecting IAM role Storage Object Admin in GCS" border />
4243

4344
Step three is optional and not used in this guide. You may allow users to have these privileges based on your policies.
4445

45-
<img src={GCS_create_service_account_3} alt="Configuring additional settings for the new service account in GCS" />
46+
<Image size="md" img={GCS_create_service_account_3} alt="Configuring additional settings for the new service account in GCS" border />
4647

4748
The service account HMAC key will be displayed. Save this information, as it will be used in the ClickHouse configuration.
4849

49-
<img src={GCS_guide_key} alt="Retrieving the generated HMAC key for GCS" />
50+
<Image size="md" img={GCS_guide_key} alt="Retrieving the generated HMAC key for GCS" border />
5051

5152
</details>

docs/_snippets/_S3_authentication_and_bucket.md

Lines changed: 18 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
import Image from '@theme/IdealImage';
12
import s3_1 from '@site/static/images/_snippets/s3/s3-1.png';
23
import s3_2 from '@site/static/images/_snippets/s3/s3-2.png';
34
import s3_3 from '@site/static/images/_snippets/s3/s3-3.png';
@@ -27,85 +28,85 @@ In this procedure, we'll be creating a service account user, not a login user.
2728

2829
2. In "users", select **Add users**
2930

30-
<img src={s3_1} alt="create_iam_user_0"/>
31+
<Image size="md" img={s3_1} alt="AWS IAM Management Console - Adding a new user" border force/>
3132

3233
3. Enter the user name and set the credential type to **Access key - Programmatic access** and select **Next: Permissions**
3334

34-
<img src={s3_2} alt="create_iam_user_1"/>
35+
<Image size="md" img={s3_2} alt="Setting user name and access type for IAM user" border force/>
3536

3637
4. Do not add the user to any group; select **Next: Tags**
3738

38-
<img src={s3_3} alt="create_iam_user_2"/>
39+
<Image size="md" img={s3_3} alt="Skipping group assignment for IAM user" border force/>
3940

4041
5. Unless you need to add any tags, select **Next: Review**
4142

42-
<img src={s3_4} alt="create_iam_user_3"/>
43+
<Image size="md" img={s3_4} alt="Skipping tag assignment for IAM user" border force/>
4344

4445
6. Select **Create User**
4546

4647
:::note
4748
The warning message stating that the user has no permissions can be ignored; permissions will be granted on the bucket for the user in the next section
4849
:::
4950

50-
<img src={s3_5} alt="create_iam_user_4"/>
51+
<Image size="md" img={s3_5} alt="Creating the IAM user with no permissions warning" border force/>
5152

5253
7. The user is now created; click on **show** and copy the access and secret keys.
5354
:::note
5455
Save the keys somewhere else; this is the only time that the secret access key will be available.
5556
:::
5657

57-
<img src={s3_6} alt="create_iam_user_5"/>
58+
<Image size="md" img={s3_6} alt="Viewing and copying the IAM user access keys" border force/>
5859

5960
8. Click close, then find the user in the users screen.
6061

61-
<img src={s3_7} alt="create_iam_user_6"/>
62+
<Image size="md" img={s3_7} alt="Finding the newly created IAM user in the users list" border force/>
6263

6364
9. Copy the ARN (Amazon Resource Name) and save it for use when configuring the access policy for the bucket.
6465

65-
<img src={s3_8} alt="create_iam_user_7"/>
66+
<Image size="md" img={s3_8} alt="Copying the ARN of the IAM user" border force/>
6667

6768
### Create an S3 bucket {#create-an-s3-bucket}
6869
1. In the S3 bucket section, select **Create bucket**
6970

70-
<img src={s3_9} alt="create_s3_bucket_0"/>
71+
<Image size="md" img={s3_9} alt="Starting the S3 bucket creation process" border force/>
7172

7273
2. Enter a bucket name, leave other options default
7374
:::note
7475
The bucket name must be unique across AWS, not just the organization, or it will emit an error.
7576
:::
7677
3. Leave `Block all Public Access` enabled; public access is not needed.
7778

78-
<img src={s3_a} alt="create_s3_bucket_2"/>
79+
<Image size="md" img={s3_a} alt="Configuring the S3 bucket settings with public access blocked" border force/>
7980

8081
4. Select **Create Bucket** at the bottom of the page
8182

82-
<img src={s3_b} alt="create_s3_bucket_3"/>
83+
<Image size="md" img={s3_b} alt="Finalizing S3 bucket creation" border force/>
8384

8485
5. Select the link, copy the ARN, and save it for use when configuring the access policy for the bucket.
8586

8687
6. Once the bucket has been created, find the new S3 bucket in the S3 buckets list and select the link
8788

88-
<img src={s3_c} alt="create_s3_bucket_4"/>
89+
<Image size="md" img={s3_c} alt="Finding the newly created S3 bucket in the buckets list" border force/>
8990

9091
7. Select **Create folder**
9192

92-
<img src={s3_d} alt="create_s3_bucket_5"/>
93+
<Image size="md" img={s3_d} alt="Creating a new folder in the S3 bucket" border force/>
9394

9495
8. Enter a folder name that will be the target for the ClickHouse S3 disk and select **Create folder**
9596

96-
<img src={s3_e} alt="create_s3_bucket_6"/>
97+
<Image size="md" img={s3_e} alt="Setting the folder name for ClickHouse S3 disk usage" border force/>
9798

9899
9. The folder should now be visible on the bucket list
99100

100-
<img src={s3_f} alt="create_s3_bucket_7"/>
101+
<Image size="md" img={s3_f} alt="Viewing the newly created folder in the S3 bucket" border force/>
101102

102103
10. Select the checkbox for the new folder and click on **Copy URL** Save the URL copied to be used in the ClickHouse storage configuration in the next section.
103104

104-
<img src={s3_g} alt="create_s3_bucket_8"/>
105+
<Image size="md" img={s3_g} alt="Copying the S3 folder URL for ClickHouse configuration" border force/>
105106

106107
11. Select the **Permissions** tab and click on the **Edit** button in the **Bucket Policy** section
107108

108-
<img src={s3_h} alt="create_s3_bucket_9"/>
109+
<Image size="md" img={s3_h} alt="Accessing the S3 bucket policy configuration" border force/>
109110

110111
12. Add a bucket policy, example below:
111112
```json
Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,4 @@
1+
import Image from '@theme/IdealImage';
12
import ip_allow_list_check_list from '@site/static/images/_snippets/ip-allow-list-check-list.png';
23
import ip_allow_list_add_current_ip from '@site/static/images/_snippets/ip-allow-list-add-current-ip.png';
34

@@ -6,10 +7,10 @@ import ip_allow_list_add_current_ip from '@site/static/images/_snippets/ip-allow
67

78
From your ClickHouse Cloud services list choose the service that you will work with and switch to **Settings**. If the IP Access List does not contain the IP Address or range of the remote system that needs to connect to your ClickHouse Cloud service, then you can resolve the problem with **Add IPs**:
89

9-
<img src={ip_allow_list_check_list} class="image" alt="Check to see if the service allows traffic" />
10+
<Image size="md" img={ip_allow_list_check_list} alt="Check to see if the service allows traffic from your IP address in the IP Access List" border />
1011

1112
Add the individual IP Address, or the range of addresses that need to connect to your ClickHouse Cloud service. Modify the form as you see fit and then **Save**.
1213

13-
<img src={ip_allow_list_add_current_ip} class="image" alt="Add your current IP address" />
14+
<Image size="md" img={ip_allow_list_add_current_ip} alt="Add your current IP address to the IP Access List in ClickHouse Cloud" border />
1415

1516
</details>

0 commit comments

Comments
 (0)