release_tracks: [GA, ALPHA, BETA]

help_text:
  brief: |
    Update a Managed Service for Apache Kafka topic.
  description: |
    Update a Managed Service for Apache Kafka topic.

  examples: |
    To update an attribute in a topic, such as the partitions, for a cluster named mycluster
    located in us-central1, run the following:

      $ {command} mytopic \
          --cluster=mycluster \
          --location=us-central1 \
          --partitions=3

request:
  collection: managedkafka.projects.locations.clusters.topics
  modify_request_hooks:
  - googlecloudsdk.command_lib.managed_kafka.util:PatchConfigs

arguments:
  resource:
    help_text: Identifies the topic to be updated.
    spec: !REF googlecloudsdk.command_lib.managed_kafka.resources:topic
  params:
  - group:
      required: true
      params:
      - _REF_: googlecloudsdk.command_lib.managed_kafka.flags:partitions
      - group:
          mutex: true
          params:
          - _REF_: googlecloudsdk.command_lib.managed_kafka.flags:configs
          - _REF_: googlecloudsdk.command_lib.managed_kafka.flags:clear-configs
