rpk topic alter-config
Set, delete, add, and remove key/value configs for a topic.
This command allows you to incrementally alter the configuration for multiple topics at a time.
Incremental altering supports four operations:
-
Setting a key=value pair
-
Deleting a key’s value
-
Appending a new value to a list-of-values key
-
Subtracting (
removing) an existing value from a list-of-values key.
The --regex flag (-r) opts into parsing the input topics as regular expressions
and altering any non-internal topic that matches any of the expressions. The
topic list command accepts the same input regex format, which lets you preview
which topics will be altered.
The --dry option will validate whether the requested configuration change is
valid, but does not apply it.
Use the flag --no-confirm to avoid the confirmation prompt.
Flags
| Value | Type | Description |
|---|---|---|
|
stringArray |
key=value; Value to append to a list-of-values key ( |
|
stringArray |
Key to delete ( |
|
bool |
Dry run: validate the alter request, but do not apply. |
|
string |
Output format ( |
|
bool |
Disable confirmation prompt. |
|
bool |
Parse topics as regex; alter any topic that matches any input topic expression. (New in v26.2.2) |
|
stringArray |
key=value; Pair to set ( |
|
stringArray |
key=value; Value to remove from list-of-values key ( |
Global flags
| Value | Type | Description |
|---|---|---|
|
string |
Redpanda or |
|
stringArray |
Override |
|
bool |
Ignore |
|
string |
|
|
bool |
Enable verbose logging. |