Skip to content

feat: auto-use kafka cluster after creation#142

Merged
wtrocki merged 2 commits intomasterfrom
auto-use-after-create
Dec 9, 2020
Merged

feat: auto-use kafka cluster after creation#142
wtrocki merged 2 commits intomasterfrom
auto-use-after-create

Conversation

@craicoverflow
Copy link
Contributor

@craicoverflow craicoverflow commented Dec 9, 2020

This PR adds an improvement suggested in #50

The issue with this is that the bootstrap server host is not available at this stage and so ClusterHost will be empty in the config.

Now when you create a Kafka cluster it is automatically used.

❯ rhoas kafka create --name "mykafka"                  
Creating Kafka cluster
Created Kafka cluster:
{
    "id": "1lQQ9rh4l3R5sVmGRMBnJHoo1Wv",
    "kind": "Kafka",
    "href": "/api/managed-services-api/v1/kafkas/1lQQ9rh4l3R5sVmGRMBnJHoo1Wv",
    "status": "accepted",
    "cloud_provider": "aws",
    "multi_az": true,
    "region": "us-east-1",
    "owner": "ephelan@redhat.com",
    "name": "mykafka",
    "created_at": "2020-12-09T15:11:26.251220494Z",
    "updated_at": "2020-12-09T15:11:26.251220494Z"
}
❯ rhoas kafka status                 
  ID                            NAME      STATUS    
 ----------------------------- --------- ---------- 
  1lQQ9rh4l3R5sVmGRMBnJHoo1Wv   mykafka   accepted

To achieve this, now only the Kafka Cluster ID id stored in the config, the Host and Name are fetched in real-time from the API, providing validation and ensuring the fields are up-to-date. See 3825190 (#142)

Also related: #135

@craicoverflow
Copy link
Contributor Author

This is still a WIP, discussion around implementation considerations is ongoing in #135

@craicoverflow craicoverflow force-pushed the auto-use-after-create branch 2 times, most recently from 59c6a43 to 3825190 Compare December 9, 2020 15:09
@wtrocki
Copy link
Collaborator

wtrocki commented Dec 9, 2020

Verified. This will conflict with stuff I have so let's merge it.

@wtrocki wtrocki merged commit 1c2a4c0 into master Dec 9, 2020
@wtrocki wtrocki deleted the auto-use-after-create branch December 9, 2020 15:46
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

rhoas kafka status fails when we create kafka [Feedback] Creation of the kafka cluster should update currently used kafka

2 participants