Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

roachprod: remove ClusterImpl interface #72887

Merged
merged 1 commit into from
Nov 18, 2021

Conversation

RaduBerinde
Copy link
Member

The ClusterImpl interface was useful when roachprod had some (very
limited) support for Cassandra, but that has been removed. We're left
with an unnecessary indirection that lacks documentation. The code
doesn't follow any layering, with Cockroach working directly with
SyncedCluster internals and plenty of cockroach-specific code in
SyncedCluster.

This commit removes this interface and improves the documentation of
the methods that are simplified.

Release note: None

@cockroach-teamcity
Copy link
Member

This change is Reviewable

Copy link
Member

@rail rail left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Woo, this is so much cleaner and I bet easier for Goland to resolve definitions. LGTM, you just forgot to change h to c in one spot.

Reviewed 6 of 6 files at r1, all commit messages.
Reviewable status: :shipit: complete! 0 of 0 LGTMs obtained (waiting on @healthy-pod, @RaduBerinde, and @stevendanna)


pkg/roachprod/install/cockroach.go, line 715 at r1 (raw file):

}

func (h *SyncedCluster) getEnvVars() []string {

The linter says s/h/c ;)

The ClusterImpl interface was useful when roachprod had some (very
limited) support for Cassandra, but that has been removed. We're left
with an unnecessary indirection that lacks documentation. The code
doesn't follow any layering, with `Cockroach` working directly with
`SyncedCluster` internals and plenty of cockroach-specific code in
`SyncedCluster`.

This commit removes this interface and improves the documentation of
the methods that are simplified.

Release note: None
Copy link
Member Author

@RaduBerinde RaduBerinde left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

TFTR!

Reviewable status: :shipit: complete! 0 of 0 LGTMs obtained (waiting on @healthy-pod, @rail, and @stevendanna)


pkg/roachprod/install/cockroach.go, line 715 at r1 (raw file):

Previously, rail (Rail Aliiev) wrote…

The linter says s/h/c ;)

Removed the receiver altogether.

Copy link
Member

@rail rail left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

:lgtm: :shipit:

Reviewed 1 of 1 files at r2, all commit messages.
Reviewable status: :shipit: complete! 1 of 0 LGTMs obtained (waiting on @healthy-pod and @stevendanna)

@RaduBerinde
Copy link
Member Author

bors r+

@craig
Copy link
Contributor

craig bot commented Nov 18, 2021

Build succeeded:

@craig craig bot merged commit 4c8c0d4 into cockroachdb:master Nov 18, 2021
@RaduBerinde RaduBerinde deleted the roachprod-no-iface branch November 21, 2021 11:48
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.

3 participants