Skip to content

Commit b7fe616

Browse files
authored
Docs ingest data considerations (#32493)
1 parent c327d6d commit b7fe616

22 files changed

+333
-259
lines changed

doc/user/content/ingest-data/mysql/_index.md

+4
Original file line numberDiff line numberDiff line change
@@ -49,3 +49,7 @@ MySQL hosted services.
4949
If there is a hosted service or MySQL distribution that is not listed above but
5050
you would like to use with Materialize, please submit a [feature request](https://github.com/MaterializeInc/materialize/discussions/new?category=feature-requests&labels=A-integration)
5151
or reach out in the Materialize [Community Slack](https://materialize.com/s/chat).
52+
53+
## Considerations
54+
55+
{{% include-md file="shared-content/mysql-considerations.md" %}}

doc/user/content/ingest-data/mysql/amazon-aurora.md

+5-1
Original file line numberDiff line numberDiff line change
@@ -295,6 +295,10 @@ available (also for PostgreSQL)."
295295
296296
{{% mysql-direct/right-size-the-cluster %}}
297297
298-
## Next steps
298+
## D. Explore your data
299299
300300
{{% mysql-direct/next-steps %}}
301+
302+
## Considerations
303+
304+
{{% include-md file="shared-content/mysql-considerations.md" %}}

doc/user/content/ingest-data/mysql/amazon-rds.md

+5-1
Original file line numberDiff line numberDiff line change
@@ -348,6 +348,10 @@ available (also for PostgreSQL)."
348348
349349
{{% mysql-direct/right-size-the-cluster %}}
350350
351-
## Next steps
351+
## D. Explore your data
352352
353353
{{% mysql-direct/next-steps %}}
354+
355+
## Considerations
356+
357+
{{% include-md file="shared-content/mysql-considerations.md" %}}

doc/user/content/ingest-data/mysql/azure-db.md

+5-1
Original file line numberDiff line numberDiff line change
@@ -168,6 +168,10 @@ available(also for PostgreSQL)."
168168
169169
{{% mysql-direct/right-size-the-cluster %}}
170170
171-
## Next steps
171+
## D. Explore your data
172172
173173
{{% mysql-direct/next-steps %}}
174+
175+
## Considerations
176+
177+
{{% include-md file="shared-content/mysql-considerations.md" %}}

doc/user/content/ingest-data/mysql/google-cloud-sql.md

+5-1
Original file line numberDiff line numberDiff line change
@@ -158,6 +158,10 @@ networking configuration, so start by selecting the relevant option.
158158
159159
{{% mysql-direct/right-size-the-cluster %}}
160160
161-
## Next steps
161+
## D. Explore your data
162162
163163
{{% mysql-direct/next-steps %}}
164+
165+
## Considerations
166+
167+
{{% include-md file="shared-content/mysql-considerations.md" %}}

doc/user/content/ingest-data/mysql/self-hosted.md

+5-1
Original file line numberDiff line numberDiff line change
@@ -160,6 +160,10 @@ available(also for PostgreSQL)."
160160
161161
{{% mysql-direct/right-size-the-cluster %}}
162162
163-
## Next steps
163+
## D. Explore your data
164164
165165
{{% mysql-direct/next-steps %}}
166+
167+
## Considerations
168+
169+
{{% include-md file="shared-content/mysql-considerations.md" %}}

doc/user/content/ingest-data/postgres/_index.md

+4
Original file line numberDiff line numberDiff line change
@@ -53,3 +53,7 @@ but you would like to use with Materialize, please submit a [feature
5353
request](https://github.com/MaterializeInc/materialize/discussions/new?category=feature-requests&labels=A-integration)
5454
or reach out in the Materialize [Community
5555
Slack](https://materialize.com/s/chat).
56+
57+
## Considerations
58+
59+
{{% include-md file="shared-content/postgres-considerations.md" %}}

doc/user/content/ingest-data/postgres/alloydb.md

+5-1
Original file line numberDiff line numberDiff line change
@@ -156,6 +156,10 @@ Materialize to your AlloyDB instance and begin the data ingestion process.
156156
157157
{{% postgres-direct/right-size-the-cluster %}}
158158
159-
## Next steps
159+
## D. Explore your data
160160
161161
{{% postgres-direct/next-steps %}}
162+
163+
## Considerations
164+
165+
{{< include-md file="shared-content/postgres-considerations.md" >}}

doc/user/content/ingest-data/postgres/amazon-aurora.md

+5-1
Original file line numberDiff line numberDiff line change
@@ -548,6 +548,10 @@ password for the `materialize` PostgreSQL user you created [earlier](#2-create-a
548548
549549
{{% postgres-direct/right-size-the-cluster %}}
550550
551-
## Next steps
551+
## D. Explore your data
552552
553553
{{% postgres-direct/next-steps %}}
554+
555+
## Considerations
556+
557+
{{< include-md file="shared-content/postgres-considerations.md" >}}

doc/user/content/ingest-data/postgres/amazon-rds.md

+5-1
Original file line numberDiff line numberDiff line change
@@ -617,6 +617,10 @@ start by selecting the relevant option.
617617
618618
{{% postgres-direct/right-size-the-cluster %}}
619619
620-
## Next steps
620+
## D. Explore your data
621621
622622
{{% postgres-direct/next-steps %}}
623+
624+
## Considerations
625+
626+
{{% include-md file="shared-content/postgres-considerations.md" %}}

doc/user/content/ingest-data/postgres/azure-db.md

+5-1
Original file line numberDiff line numberDiff line change
@@ -297,6 +297,10 @@ created [earlier](#2-create-a-publication-and-a-replication-user):
297297
298298
{{% postgres-direct/right-size-the-cluster %}}
299299
300-
## Next steps
300+
## D. Explore your data
301301
302302
{{% postgres-direct/next-steps %}}
303+
304+
## Considerations
305+
306+
{{% include-md file="shared-content/postgres-considerations.md" %}}

doc/user/content/ingest-data/postgres/cloud-sql.md

+5-1
Original file line numberDiff line numberDiff line change
@@ -151,6 +151,10 @@ start by selecting the relevant option.
151151
152152
{{% postgres-direct/right-size-the-cluster %}}
153153
154-
## Next steps
154+
## D. Explore your data
155155
156156
{{% postgres-direct/next-steps %}}
157+
158+
## Considerations
159+
160+
{{% include-md file="shared-content/postgres-considerations.md" %}}

doc/user/content/ingest-data/postgres/neon.md

+5-1
Original file line numberDiff line numberDiff line change
@@ -306,6 +306,10 @@ ingesting data.
306306
307307
{{% postgres-direct/right-size-the-cluster %}}
308308
309-
## Next steps
309+
## D. Explore your data
310310
311311
{{% postgres-direct/next-steps %}}
312+
313+
## Considerations
314+
315+
{{% include-md file="shared-content/postgres-considerations.md" %}}

doc/user/content/ingest-data/postgres/self-hosted.md

+5-1
Original file line numberDiff line numberDiff line change
@@ -485,6 +485,10 @@ start by selecting the relevant option.
485485
486486
{{% postgres-direct/right-size-the-cluster %}}
487487
488-
## Next steps
488+
## D. Explore your data
489489
490490
{{% postgres-direct/next-steps %}}
491+
492+
## Considerations
493+
494+
{{% include-md file="shared-content/postgres-considerations.md" %}}

doc/user/content/ingest-data/sql-server/_index.md

+10-4
Original file line numberDiff line numberDiff line change
@@ -30,8 +30,14 @@ SQL Server Change Data Capture (CDC) in Materialize gives you the following bene
3030
a read-replica to build views on top of your SQL Server data that are
3131
efficiently maintained and always up-to-date.
3232

33-
* **Supported versions:** Materialize supports replicating data from SQL Server 2016
34-
or higher.
33+
## Supported versions
3534

36-
* **Integration Guides**
37-
* [Self-hosted SQL Server](/ingest-data/sql-server/self-hosted/)
35+
Materialize supports replicating data from SQL Server 2016 or higher.
36+
37+
## Integration Guides
38+
39+
- [Self-hosted SQL Server](/ingest-data/sql-server/self-hosted/)
40+
41+
## Considerations
42+
43+
{{% include-md file="shared-content/sql-server-considerations.md" %}}

doc/user/content/ingest-data/sql-server/self-hosted.md

+5-1
Original file line numberDiff line numberDiff line change
@@ -155,6 +155,10 @@ available(also for PostgreSQL)."
155155
156156
{{% sql-server-direct/right-size-the-cluster %}}
157157
158-
## Next steps
158+
## D. Explore your data
159159
160160
{{% sql-server-direct/next-steps %}}
161+
162+
## Considerations
163+
164+
{{% include-md file="shared-content/sql-server-considerations.md" %}}

doc/user/content/sql/create-source/mysql.md

+1-65
Original file line numberDiff line numberDiff line change
@@ -206,71 +206,7 @@ debugging related issues, see [Troubleshooting](/ops/troubleshooting/).
206206

207207
## Known limitations
208208

209-
### Schema changes
210-
211-
{{< include-md file="shared-content/schema-changes-in-progress.md" >}}
212-
213-
{{% schema-changes %}}
214-
215-
### Supported types
216-
217-
Materialize natively supports the following MySQL types:
218-
219-
<ul style="column-count: 3">
220-
<li><code>bigint</code></li>
221-
<li><code>binary</code></li>
222-
<li><code>bit</code></li>
223-
<li><code>blob</code></li>
224-
<li><code>boolean</code></li>
225-
<li><code>char</code></li>
226-
<li><code>date</code></li>
227-
<li><code>datetime</code></li>
228-
<li><code>decimal</code></li>
229-
<li><code>double</code></li>
230-
<li><code>float</code></li>
231-
<li><code>int</code></li>
232-
<li><code>json</code></li>
233-
<li><code>longblob</code></li>
234-
<li><code>longtext</code></li>
235-
<li><code>mediumblob</code></li>
236-
<li><code>mediumint</code></li>
237-
<li><code>mediumtext</code></li>
238-
<li><code>numeric</code></li>
239-
<li><code>real</code></li>
240-
<li><code>smallint</code></li>
241-
<li><code>text</code></li>
242-
<li><code>time</code></li>
243-
<li><code>timestamp</code></li>
244-
<li><code>tinyblob</code></li>
245-
<li><code>tinyint</code></li>
246-
<li><code>tinytext</code></li>
247-
<li><code>varbinary</code></li>
248-
<li><code>varchar</code></li>
249-
</ul>
250-
251-
Replicating tables that contain **unsupported [data types](/sql/types/)** is
252-
possible via the [`TEXT COLUMNS` option](#handling-unsupported-types) for the
253-
following types:
254-
255-
<ul style="column-count: 1">
256-
<li><code>enum</code></li>
257-
<li><code>year</code></li>
258-
</ul>
259-
260-
The specified columns will be treated as `text`, and will thus not offer the
261-
expected MySQL type features. For any unsupported data types not listed above,
262-
use the [`EXCLUDE COLUMNS`](#excluding-columns) option.
263-
264-
### Truncation
265-
266-
Tables replicated into Materialize should not be truncated. If a table is
267-
truncated while replicated, the whole source becomes inaccessible and will not
268-
produce any data until it is recreated. Instead, remove all rows from a table
269-
using an unqualified `DELETE`.
270-
271-
```mzsql
272-
DELETE FROM t;
273-
```
209+
{{< include-md file="shared-content/mysql-considerations.md" >}}
274210

275211
## Examples
276212

doc/user/content/sql/create-source/postgres.md

+1-100
Original file line numberDiff line numberDiff line change
@@ -196,106 +196,7 @@ ingestion progress and debugging related issues, see [Troubleshooting](/ops/trou
196196

197197
## Known limitations
198198

199-
### Schema changes
200-
201-
{{< include-md file="shared-content/schema-changes-in-progress.md" >}}
202-
203-
{{% schema-changes %}}
204-
205-
### Publication membership
206-
207-
PostgreSQL's logical replication API does not provide a signal when users remove
208-
tables from publications. Because of this, Materialize relies on periodic checks
209-
to determine if a table has been removed from a publication, at which time it
210-
generates an irrevocable error, preventing any values from being read from the
211-
table.
212-
213-
However, it is possible to remove a table from a publication and then re-add it
214-
before Materialize notices that the table was removed. In this case, Materialize
215-
can no longer provide any consistency guarantees about the data we present from
216-
the table and, unfortunately, is wholly unaware that this occurred.
217-
218-
To mitigate this issue, if you need to drop and re-add a table to a publication,
219-
ensure that you remove the table/subsource from the source _before_ re-adding it
220-
using the [`DROP SOURCE`](/sql/drop-source/) command.
221-
222-
### Supported types
223-
224-
Materialize natively supports the following PostgreSQL types (including the
225-
array type for each of the types):
226-
227-
<ul style="column-count: 3">
228-
<li><code>bool</code></li>
229-
<li><code>bpchar</code></li>
230-
<li><code>bytea</code></li>
231-
<li><code>char</code></li>
232-
<li><code>date</code></li>
233-
<li><code>daterange</code></li>
234-
<li><code>float4</code></li>
235-
<li><code>float8</code></li>
236-
<li><code>int2</code></li>
237-
<li><code>int2vector</code></li>
238-
<li><code>int4</code></li>
239-
<li><code>int4range</code></li>
240-
<li><code>int8</code></li>
241-
<li><code>int8range</code></li>
242-
<li><code>interval</code></li>
243-
<li><code>json</code></li>
244-
<li><code>jsonb</code></li>
245-
<li><code>numeric</code></li>
246-
<li><code>numrange</code></li>
247-
<li><code>oid</code></li>
248-
<li><code>text</code></li>
249-
<li><code>time</code></li>
250-
<li><code>timestamp</code></li>
251-
<li><code>timestamptz</code></li>
252-
<li><code>tsrange</code></li>
253-
<li><code>tstzrange</code></li>
254-
<li><code>uuid</code></li>
255-
<li><code>varchar</code></li>
256-
</ul>
257-
258-
Replicating tables that contain **unsupported [data types](/sql/types/)** is
259-
possible via the `TEXT COLUMNS` option. The specified columns will be treated
260-
as `text`, and will thus not offer the expected PostgreSQL type features. For
261-
example:
262-
263-
* [`enum`]: the implicit ordering of the original PostgreSQL `enum` type is not
264-
preserved, as Materialize will sort values as `text`.
265-
266-
* [`money`]: the resulting `text` value cannot be cast back to e.g. `numeric`,
267-
since PostgreSQL adds typical currency formatting to the output.
268-
269-
### Truncation
270-
271-
Tables replicated into Materialize should not be truncated. If a table is
272-
truncated while replicated, the whole source becomes inaccessible and will not
273-
produce any data until it is recreated. Instead, remove all rows from a table
274-
using an unqualified `DELETE`.
275-
276-
```mzsql
277-
DELETE FROM t;
278-
```
279-
280-
### Inherited tables
281-
282-
When using [PostgreSQL table inheritance](https://www.postgresql.org/docs/current/tutorial-inheritance.html),
283-
PostgreSQL serves data from `SELECT`s as if the inheriting tables' data is also
284-
present in the inherited table. However, both PostgreSQL's logical replication
285-
and `COPY` only present data written to the tables themselves, i.e. the
286-
inheriting data is _not_ treated as part of the inherited table.
287-
288-
PostgreSQL sources use logical replication and `COPY` to ingest table data, so
289-
inheriting tables' data will only be ingested as part of the inheriting table,
290-
i.e. in Materialize, the data will not be returned when serving `SELECT`s from
291-
the inherited table.
292-
293-
You can mimic PostgreSQL's `SELECT` behavior with inherited tables by creating a
294-
materialized view that unions data from the inherited and inheriting tables
295-
(using `UNION ALL`). However, if new tables inherit from the table, data from
296-
the inheriting tables will not be available in the view. You will need to add
297-
the inheriting tables via `ADD SUBSOURCE` and create a new view (materialized or
298-
non-) that unions the new table.
199+
{{% include-md file="shared-content/postgres-considerations.md" %}}
299200

300201
## Examples
301202

0 commit comments

Comments
 (0)