github.com/cockroachdb/cockroach@v20.2.0-alpha.1+incompatible/pkg/acceptance/cluster/testconfig.proto (about)

     1  // Copyright 2016 The Cockroach Authors.
     2  //
     3  // Use of this software is governed by the Business Source License
     4  // included in the file licenses/BSL.txt.
     5  //
     6  // As of the Change Date specified in that file, in accordance with
     7  // the Business Source License, use of this software will be governed
     8  // by the Apache License, Version 2.0, included in the file
     9  // licenses/APL.txt.
    10  
    11  syntax = "proto2";
    12  package cockroach.acceptance.cluster;
    13  option go_package = "cluster";
    14  
    15  import "gogoproto/gogo.proto";
    16  
    17  // InitMode specifies different ways to initialize the cluster.
    18  enum InitMode {
    19    option (gogoproto.goproto_enum_prefix) = false;
    20  
    21    // INIT_COMMAND starts every node with a join flag and issues the
    22    // init command.
    23    INIT_COMMAND = 0;
    24  
    25    // INIT_BOOTSTRAP_NODE_ZERO uses the legacy protocol of omitting the
    26    // join flag from node zero.
    27    INIT_BOOTSTRAP_NODE_ZERO = 1;
    28  
    29    // INIT_NONE starts every node with a join flag and leaves the
    30    // cluster uninitialized.
    31    INIT_NONE = 2;
    32  }
    33  
    34  // StoreConfig holds the configuration of a collection of similar stores.
    35  message StoreConfig {
    36    optional int32 max_ranges = 2 [(gogoproto.nullable) = false];
    37  }
    38  
    39  // NodeConfig holds the configuration of a collection of similar nodes.
    40  message NodeConfig {
    41    optional string version = 1 [(gogoproto.nullable) = false];
    42    repeated StoreConfig stores = 2 [(gogoproto.nullable) = false];
    43  }
    44  
    45  message TestConfig {
    46    optional string name = 1 [(gogoproto.nullable) = false];
    47    repeated NodeConfig nodes = 2 [(gogoproto.nullable) = false];
    48    // Duration is the total time that the test should run for. Important for
    49    // tests such as TestPut that will run indefinitely.
    50    optional int64 duration = 3 [(gogoproto.nullable) = false, (gogoproto.casttype) = "time.Duration"];
    51    optional InitMode init_mode = 4 [(gogoproto.nullable) = false];
    52    // When set, the cluster is started as quickly as possible, without waiting
    53    // for ranges to replicate, or even ports to be opened.
    54    optional bool no_wait = 5 [(gogoproto.nullable) = false];
    55  }