Skip to content

Commit

Permalink
roachtest: improve some comments
Browse files Browse the repository at this point in the history
Epic: None
Release note: None
  • Loading branch information
andreimatei committed May 31, 2024
1 parent f2e7709 commit 28ab430
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 3 deletions.
2 changes: 1 addition & 1 deletion pkg/cmd/roachtest/test_runner.go
Original file line number Diff line number Diff line change
Expand Up @@ -1277,7 +1277,7 @@ func (r *testRunner) runTest(

// We still want to run the post-test assertions even if the test timed out as it
// might provide useful information about the health of the nodes. Any assertion failures
// will will be recorded against, and eventually fail, the test.
// will be recorded against, and eventually fail, the test.
if err := r.postTestAssertions(ctx, t, c, 10*time.Minute); err != nil {
l.Printf("error during post test assertions: %v; see test-post-assertions.log for details", err)
}
Expand Down
9 changes: 7 additions & 2 deletions pkg/roachprod/roachprod.go
Original file line number Diff line number Diff line change
Expand Up @@ -164,7 +164,8 @@ func sortedClusters() []string {

// newCluster initializes a SyncedCluster for the given cluster name.
//
// The cluster name can include a node selector (e.g. "foo:1-3").
// The cluster name can include a node selector (e.g. "foo:1-3"). If the
// selector is missing, the returned cluster includes all the machines.
func newCluster(
l *logger.Logger, name string, opts ...install.ClusterSettingOption,
) (*install.SyncedCluster, error) {
Expand Down Expand Up @@ -969,6 +970,8 @@ sudo chmod 777 /mnt/data1
}

// Install installs third party software.
//
// The cluster name can include a node selector (e.g. "foo:1-3").
func Install(ctx context.Context, l *logger.Logger, clusterName string, software []string) error {
c, err := getClusterFromCache(l, clusterName)
if err != nil {
Expand Down Expand Up @@ -2312,7 +2315,7 @@ func StartFluentBit(
return fluentbit.Install(ctx, l, c, config)
}

// Stop stops Fluent Bit on the cluster identified by clusterName.
// StopFluentBit stops Fluent Bit on the cluster identified by clusterName.
func StopFluentBit(ctx context.Context, l *logger.Logger, clusterName string) error {
if err := LoadClusters(); err != nil {
return err
Expand Down Expand Up @@ -2671,6 +2674,8 @@ func Deploy(

// getClusterFromCache finds and returns a SyncedCluster from
// the local cluster cache.
//
// The cluster name can include a node selector (e.g. "foo:1-3").
func getClusterFromCache(
l *logger.Logger, clusterName string, opts ...install.ClusterSettingOption,
) (*install.SyncedCluster, error) {
Expand Down

0 comments on commit 28ab430

Please sign in to comment.