Skip to content

Commit 2cdc77a

Browse files
feat: change enum values to lowercase and drop fk_ prefix (#1621)
Signed-off-by: Manan Gupta <manan@planetscale.com>
1 parent 94ddf23 commit 2cdc77a

File tree

4 files changed

+8
-8
lines changed

4 files changed

+8
-8
lines changed

content/en/docs/18.0/user-guides/vschema-guide/advanced-vschema.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -200,6 +200,6 @@ Each keyspace can be configured to run with a different foreign key mode -
200200
```json
201201
{
202202
"sharded": true,
203-
"foreignKeyMode": "FK_MANAGED"
203+
"foreignKeyMode": "managed"
204204
}
205205
```

content/en/docs/18.0/user-guides/vschema-guide/foreign-keys.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ For running foreign keys in Vitess, the users have a few options. Let's explore
77

88
### Vitess Unaware of Foreign Keys
99

10-
Users can run Vitess such that it doesn't know about or care for the foreign key constraints existing on MySQL. To run Vitess in this mode, `foreignKeyMode` VSchema property has to be set to `FK_UNMANAGED` for the given keyspace. This is the default mode for Vitess as well.
10+
Users can run Vitess such that it doesn't know about or care for the foreign key constraints existing on MySQL. To run Vitess in this mode, `foreignKeyMode` VSchema property has to be set to `unmanaged` for the given keyspace. This is the default mode for Vitess as well.
1111

1212
It is up to the users to configure the foreign keys in MySQL such that rows that are related by foreign keys end up living in the same shard.
1313
To this end, users can configure tables related by foreign keys to use the same shared vindex. More detail about this can be read in [shared vindexes](../shared-vindexes/#foreign-keys).
@@ -24,7 +24,7 @@ To this end, users can configure tables related by foreign keys to use the same
2424
Please note, that in this version of Vitess, this mode is experimental and should be used cautiously.
2525
{{< /info >}}
2626

27-
Users can run Vitess such that it keeps track of all the foreign key constraints using the schema tracker. To run Vitess in this mode, `foreignKeyMode` VSchema property has to be set to `FK_MANAGED` for the given keyspace.
27+
Users can run Vitess such that it keeps track of all the foreign key constraints using the schema tracker. To run Vitess in this mode, `foreignKeyMode` VSchema property has to be set to `managed` for the given keyspace.
2828

2929
In this mode, Vitess takes care of splitting up DMLs that would cause updates on a child table in a foreign key constraint. All the queries on MySQL are executed such that InnoDB doesn't end up running any updates which don't make their way into the binary log. This allows VReplication to work properly, thus relaxing one of the limitations of the previous approach.
3030

@@ -38,6 +38,6 @@ For more details on what operations Vitess takes please refer to the [design doc
3838

3939
### Vitess Disallows Foreign Keys
4040

41-
Users can run Vitess such that it explicitly disallows any DDL statements that try to create a foreign key constraint. To run Vitess in this mode, `foreignKeyMode` VSchema property has to be set to `FK_DISALLOW` for the given keyspace.
41+
Users can run Vitess such that it explicitly disallows any DDL statements that try to create a foreign key constraint. To run Vitess in this mode, `foreignKeyMode` VSchema property has to be set to `disallow` for the given keyspace.
4242

4343
This mode is for users that don't use foreign keys and want to prevent accidentally introducing them in their schema.

content/en/docs/19.0/user-guides/vschema-guide/advanced-vschema.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -200,6 +200,6 @@ Each keyspace can be configured to run with a different foreign key mode -
200200
```json
201201
{
202202
"sharded": true,
203-
"foreignKeyMode": "FK_MANAGED"
203+
"foreignKeyMode": "managed"
204204
}
205205
```

content/en/docs/19.0/user-guides/vschema-guide/foreign-keys.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ For running foreign keys in Vitess, the users have a few options. Let's explore
77

88
### Vitess Unaware of Foreign Keys
99

10-
Users can run Vitess such that it doesn't know about or care for the foreign key constraints existing on MySQL. To run Vitess in this mode, `foreignKeyMode` VSchema property has to be set to `FK_UNMANAGED` for the given keyspace. This is the default mode for Vitess as well.
10+
Users can run Vitess such that it doesn't know about or care for the foreign key constraints existing on MySQL. To run Vitess in this mode, `foreignKeyMode` VSchema property has to be set to `unmanaged` for the given keyspace. This is the default mode for Vitess as well.
1111

1212
It is up to the users to configure the foreign keys in MySQL such that rows that are related by foreign keys end up living in the same shard.
1313
To this end, users can configure tables related by foreign keys to use the same shared vindex. More detail about this can be read in [shared vindexes](../shared-vindexes/#foreign-keys).
@@ -24,7 +24,7 @@ To this end, users can configure tables related by foreign keys to use the same
2424
Please note, that in this version of Vitess, this mode is experimental and should be used cautiously.
2525
{{< /info >}}
2626

27-
Users can run Vitess such that it keeps track of all the foreign key constraints using the schema tracker. To run Vitess in this mode, `foreignKeyMode` VSchema property has to be set to `FK_MANAGED` for the given keyspace.
27+
Users can run Vitess such that it keeps track of all the foreign key constraints using the schema tracker. To run Vitess in this mode, `foreignKeyMode` VSchema property has to be set to `managed` for the given keyspace.
2828

2929
In this mode, Vitess takes care of splitting up DMLs that would cause updates on a child table in a foreign key constraint. All the queries on MySQL are executed such that InnoDB doesn't end up running any updates which don't make their way into the binary log. This allows VReplication to work properly, thus relaxing one of the limitations of the previous approach.
3030

@@ -38,6 +38,6 @@ For more details on what operations Vitess takes please refer to the [design doc
3838

3939
### Vitess Disallows Foreign Keys
4040

41-
Users can run Vitess such that it explicitly disallows any DDL statements that try to create a foreign key constraint. To run Vitess in this mode, `foreignKeyMode` VSchema property has to be set to `FK_DISALLOW` for the given keyspace.
41+
Users can run Vitess such that it explicitly disallows any DDL statements that try to create a foreign key constraint. To run Vitess in this mode, `foreignKeyMode` VSchema property has to be set to `disallow` for the given keyspace.
4242

4343
This mode is for users that don't use foreign keys and want to prevent accidentally introducing them in their schema.

0 commit comments

Comments
 (0)