Skip to content

Commit 97bd17c

Browse files
Revert "AKCORE-627 : Add Share Group Commands for Confluent CLI (#3185)" (#3228)
1 parent 2b33073 commit 97bd17c

34 files changed

+26
-701
lines changed

go.mod

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -35,7 +35,7 @@ require (
3535
github.com/confluentinc/ccloud-sdk-go-v2/iam-ip-filtering v0.5.0
3636
github.com/confluentinc/ccloud-sdk-go-v2/identity-provider v0.3.0
3737
github.com/confluentinc/ccloud-sdk-go-v2/kafka-quotas v0.4.0
38-
github.com/confluentinc/ccloud-sdk-go-v2/kafkarest v0.0.0-20250909043602-f80bee0eb280
38+
github.com/confluentinc/ccloud-sdk-go-v2/kafkarest v0.24.0
3939
github.com/confluentinc/ccloud-sdk-go-v2/ksql v0.2.0
4040
github.com/confluentinc/ccloud-sdk-go-v2/mds v0.4.0
4141
github.com/confluentinc/ccloud-sdk-go-v2/metrics v0.2.0

go.sum

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -228,8 +228,8 @@ github.com/confluentinc/ccloud-sdk-go-v2/identity-provider v0.3.0 h1:COUuWIW9GLz
228228
github.com/confluentinc/ccloud-sdk-go-v2/identity-provider v0.3.0/go.mod h1:VHpsi0yWBEhN6Hp2oOyGkRaNJjtnaVfYjpbtB8pnNnk=
229229
github.com/confluentinc/ccloud-sdk-go-v2/kafka-quotas v0.4.0 h1:T9e7lNj/VjxE89+tcpX2RS2NE4rWNWbJjxcO2yehEqM=
230230
github.com/confluentinc/ccloud-sdk-go-v2/kafka-quotas v0.4.0/go.mod h1:7gqwWFIyj2MAGpL/kf6SGXm/pi2Z6qpMJIjKlgEEhhg=
231-
github.com/confluentinc/ccloud-sdk-go-v2/kafkarest v0.0.0-20250909043602-f80bee0eb280 h1:GFVI3pGckhpP66Xb05usB8txzubnnoigZHp292ax5Rg=
232-
github.com/confluentinc/ccloud-sdk-go-v2/kafkarest v0.0.0-20250909043602-f80bee0eb280/go.mod h1:b8v8EIBtpQDx0zAxCpGxhuSWBRAwh/+PRFNtaBR5P7c=
231+
github.com/confluentinc/ccloud-sdk-go-v2/kafkarest v0.24.0 h1:PLmZLAMnY+zgxw687jemgMlqMPmu6OgJssxGlvsjp8M=
232+
github.com/confluentinc/ccloud-sdk-go-v2/kafkarest v0.24.0/go.mod h1:Sb2O1jlHfLgMrZiqLAPqws0WjAVd4HgocZh3D7EZN5k=
233233
github.com/confluentinc/ccloud-sdk-go-v2/ksql v0.2.0 h1:g6OHa1iW3HO3N/YiTAL9Q6Y7rdjMBAjOPYK37akTt0M=
234234
github.com/confluentinc/ccloud-sdk-go-v2/ksql v0.2.0/go.mod h1:0LAvd4VqlaRwKU4yvDEkVCtV43yNezt56+hBe9Lmg7Q=
235235
github.com/confluentinc/ccloud-sdk-go-v2/mds v0.4.0 h1:jIXXhGi+Xn+XYFCErnMvd035QijbYXla1Bo8W7V7lFM=

internal/kafka/command.go

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,6 @@ func New(cfg *config.Config, prerunner pcmd.PreRunner) *cobra.Command {
2424
cmd.AddCommand(newQuotaCommand(prerunner))
2525
cmd.AddCommand(newRegionCommand(prerunner))
2626
cmd.AddCommand(newReplicaCommand(prerunner))
27-
cmd.AddCommand(newShareGroupCommand(prerunner))
2827
cmd.AddCommand(newTopicCommand(cfg, prerunner))
2928

3029
return cmd

internal/kafka/command_share_group.go

Lines changed: 0 additions & 49 deletions
This file was deleted.

internal/kafka/command_share_group_consumer.go

Lines changed: 0 additions & 16 deletions
This file was deleted.

internal/kafka/command_share_group_consumer_list.go

Lines changed: 0 additions & 82 deletions
This file was deleted.

internal/kafka/command_share_group_describe.go

Lines changed: 0 additions & 75 deletions
This file was deleted.

internal/kafka/command_share_group_list.go

Lines changed: 0 additions & 50 deletions
This file was deleted.

pkg/ccloudv2/kafkarest.go

Lines changed: 0 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -307,30 +307,6 @@ func (c *KafkaRestClient) GetKafkaConsumerLag(consumerGroupId, topicName string,
307307
return res, kafkarest.NewError(c.GetUrl(), err, httpResp)
308308
}
309309

310-
func (c *KafkaRestClient) ListKafkaShareGroups() ([]kafkarestv3.ShareGroupData, error) {
311-
res, httpResp, err := c.ShareGroupV3Api.ListKafkaShareGroups(c.kafkaRestApiContext(), c.ClusterId).Execute()
312-
if err != nil {
313-
return nil, kafkarest.NewError(c.GetUrl(), err, httpResp)
314-
}
315-
return res.GetData(), nil
316-
}
317-
318-
func (c *KafkaRestClient) GetKafkaShareGroup(shareGroupId string) (kafkarestv3.ShareGroupData, error) {
319-
res, httpResp, err := c.ShareGroupV3Api.GetKafkaShareGroup(c.kafkaRestApiContext(), c.ClusterId, shareGroupId).Execute()
320-
if err != nil {
321-
return kafkarestv3.ShareGroupData{}, kafkarest.NewError(c.GetUrl(), err, httpResp)
322-
}
323-
return res, nil
324-
}
325-
326-
func (c *KafkaRestClient) ListKafkaShareGroupConsumers(shareGroupId string) ([]kafkarestv3.ShareGroupConsumerData, error) {
327-
res, httpResp, err := c.ShareGroupV3Api.ListKafkaShareGroupConsumers(c.kafkaRestApiContext(), c.ClusterId, shareGroupId).Execute()
328-
if err != nil {
329-
return nil, kafkarest.NewError(c.GetUrl(), err, httpResp)
330-
}
331-
return res.GetData(), nil
332-
}
333-
334310
func (c *KafkaRestClient) GetKafkaPartition(topicName string, partitionId int32) (kafkarestv3.PartitionData, error) {
335311
res, httpResp, err := c.PartitionV3Api.GetKafkaPartition(c.kafkaRestApiContext(), c.ClusterId, topicName, partitionId).Execute()
336312
return res, kafkarest.NewError(c.GetUrl(), err, httpResp)

pkg/cmd/flags.go

Lines changed: 0 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -592,24 +592,6 @@ func AutocompleteConsumerGroups(cmd *cobra.Command, c *AuthenticatedCLICommand)
592592
return suggestions
593593
}
594594

595-
func AutocompleteShareGroups(cmd *cobra.Command, c *AuthenticatedCLICommand) []string {
596-
kafkaREST, err := c.GetKafkaREST(cmd)
597-
if err != nil {
598-
return nil
599-
}
600-
601-
shareGroups, err := kafkaREST.CloudClient.ListKafkaShareGroups()
602-
if err != nil {
603-
return nil
604-
}
605-
606-
suggestions := make([]string, len(shareGroups))
607-
for i, shareGroup := range shareGroups {
608-
suggestions[i] = shareGroup.GetShareGroupId()
609-
}
610-
return suggestions
611-
}
612-
613595
func AddNetworkFlag(cmd *cobra.Command, c *AuthenticatedCLICommand) {
614596
cmd.Flags().String("network", "", "Network ID.")
615597
RegisterFlagCompletionFunc(cmd, "network", func(cmd *cobra.Command, args []string) []string {

0 commit comments

Comments
 (0)