You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: modules/manage/pages/schema-reg/schema-id-validation.adoc
+37-9Lines changed: 37 additions & 9 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -37,11 +37,17 @@ To use schema ID validation:
37
37
38
38
ifndef::env-cloud[]
39
39
By default, server-side schema ID validation is disabled in Redpanda. To enable schema ID validation, change the xref:reference:cluster-properties.adoc#enable_schema_id_validation[`enable_schema_id_validation`] cluster property from its default value of `none` to either `redpanda` or `compat`:
40
+
endif::[]
41
+
42
+
ifdef::env-cloud[]
43
+
By default, server-side schema ID validation is disabled in Redpanda. To enable schema ID validation, change the xref:reference:properties/cluster-properties.adoc#enable_schema_id_validation[`enable_schema_id_validation`] cluster property from its default value of `none` to either `redpanda` or `compat`:
44
+
endif::[]
40
45
41
46
* `none`: Schema validation is disabled (no schema ID checks are done). Associated topic properties cannot be modified.
42
47
* `redpanda`: Schema validation is enabled. Only Redpanda topic properties are accepted.
43
48
* `compat`: Schema validation is enabled. Both Redpanda and compatible topic properties are accepted.
44
49
50
+
ifndef::env-cloud[]
45
51
For example, use `rpk` to set the value of `enable_schema_id_validation` to `redpanda` through the Admin API:
To enable schema ID validation, set the `enable_schema_id_validation` cluster property to either `redpanda` or `compat`:
55
-
56
-
* `none`: Schema validation is disabled (no schema ID checks are done). Associated topic properties cannot be modified.
57
-
* `redpanda`: Schema validation is enabled. Only Redpanda topic properties are accepted.
58
-
* `compat`: Schema validation is enabled. Both Redpanda and compatible topic properties are accepted.
59
-
60
-
See xref:manage:cluster-maintenance/config-cluster.adoc[]
60
+
See xref:manage:cluster-maintenance/config-cluster.adoc[].
61
61
endif::[]
62
62
63
63
=== Set subject name strategy per topic
@@ -87,6 +87,7 @@ When <<enable-schema-id-validation,schema ID validation is enabled>>, Redpanda u
87
87
88
88
To customize the subject name strategy per topic, set the following client topic properties:
89
89
90
+
ifndef::env-cloud[]
90
91
* Set xref:reference:properties/topic-properties.adoc#redpandakeyschemavalidation[`redpanda.key.schema.id.validation`] to `true` to enable key schema ID validation for the topic, and set xref:reference:properties/topic-properties.adoc#redpandakeysubjectnamestrategy[`redpanda.key.subject.name.strategy`] to the desired subject name strategy for keys of the topic (default: `TopicNameStrategy`).
91
92
* Set xref:reference:properties/topic-properties.adoc#redpandavalueschemavalidation[`redpanda.value.schema.id.validation`] to `true` to enable value schema ID validation for the topic, and set xref:reference:properties/topic-properties.adoc#redpandavaluesubjectnamestrategy[`redpanda.value.subject.name.strategy`] to the desired subject name strategy for values of the topic (default: `TopicNameStrategy`).
92
93
@@ -109,11 +110,38 @@ The `redpanda.` properties have corresponding `confluent.` properties.
* Set `redpanda.key.schema.id.validation` to `true` to enable key schema ID validation for the topic, and set `redpanda.key.subject.name.strategy` to the desired subject name strategy for keys of the topic (default: `TopicNameStrategy`).
118
+
* Set `redpanda.value.schema.id.validation` to `true` to enable value schema ID validation for the topic, and set `redpanda.value.subject.name.strategy` to the desired subject name strategy for values of the topic (default: `TopicNameStrategy`).
119
+
120
+
[NOTE]
121
+
====
122
+
The `redpanda.` properties have corresponding `confluent.` properties.
123
+
124
+
|===
125
+
| Redpanda property | Confluent property
126
+
127
+
| `redpanda.key.schema.id.validation`
128
+
| `confluent.key.schema.validation`
129
+
130
+
| `redpanda.key.subject.name.strategy`
131
+
| `confluent.key.subject.name.strategy`
132
+
133
+
| `redpanda.value.schema.id.validation`
134
+
| `confluent.value.schema.validation`
135
+
136
+
| `redpanda.value.subject.name.strategy`
137
+
| `confluent.value.subject.name.strategy`
138
+
|===
139
+
====
140
+
endif::[]
112
141
113
142
The `redpanda.*` and `confluent.*` properties are compatible. Either or both can be set simultaneously.
114
143
115
144
If `subject.name.strategy` is prefixed with `confluent.`, the available subject name strategies must be prefixed with `io.confluent.kafka.serializers.subject.`. For example, `io.confluent.kafka.serializers.subject.TopicNameStrategy`.
116
-
====
117
145
118
146
NOTE: To support schema ID validation for compressed topics, a Redpanda broker decompresses each batch written to it so it can access the schema ID.
Copy file name to clipboardExpand all lines: modules/reference/partials/properties/cluster-properties.adoc
+4Lines changed: 4 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -5011,10 +5011,13 @@ endif::[]
5011
5011
|===
5012
5012
5013
5013
5014
+
// tag::redpanda-cloud[]
5014
5015
=== enable_schema_id_validation
5015
5016
5016
5017
Controls whether Redpanda validates schema IDs in records and which topic properties are enforced.
5017
5018
5019
+
NOTE: Enabling this property will trigger decompression of message batches for topics on which validation is configured, which may lead to a modest increase in CPU load. Redpanda recommends monitoring CPU utilization after topics are configured.
5020
+
5018
5021
Values:
5019
5022
5020
5023
* `none`: Schema validation is disabled (no schema ID checks are done). Associated topic properties cannot be modified.
0 commit comments