@@ -457,81 +457,6 @@ func registerKVContention(r registry.Registry) {
457457 })
458458}
459459
460- func registerKVQuiescenceDead (r registry.Registry ) {
461- r .Add (registry.TestSpec {
462- Name : "kv/quiescence/nodes=3" ,
463- Skip : "https://github.com/cockroachdb/cockroach/issues/156357" ,
464- Owner : registry .OwnerKV ,
465- Cluster : r .MakeClusterSpec (4 , spec .WorkloadNode ()),
466- CompatibleClouds : registry .AllExceptAWS ,
467- Suites : registry .Suites (registry .Nightly ),
468- Leases : registry .EpochLeases ,
469- SkipPostValidations : registry .PostValidationNoDeadNodes ,
470- Run : func (ctx context.Context , t test.Test , c cluster.Cluster ) {
471- settings := install .MakeClusterSettings (install.ClusterSettingsOption {
472- "sql.stats.automatic_collection.enabled" : "false" ,
473- })
474- c .Start (ctx , t .L (), option .NewStartOpts (option .NoBackupSchedule ), settings , c .CRDBNodes ())
475- m := c .NewDeprecatedMonitor (ctx , c .CRDBNodes ())
476-
477- db := c .Conn (ctx , t .L (), 1 )
478- defer db .Close ()
479-
480- err := roachtestutil .WaitFor3XReplication (ctx , t .L (), db )
481- require .NoError (t , err )
482-
483- qps := func (f func ()) float64 {
484-
485- numInserts := func () float64 {
486- var v float64
487- if err = db .QueryRowContext (
488- ctx , `SELECT value FROM crdb_internal.node_metrics WHERE name = 'sql.insert.count'` ,
489- ).Scan (& v ); err != nil {
490- t .Fatal (err )
491- }
492- return v
493- }
494-
495- tBegin := timeutil .Now ()
496- before := numInserts ()
497- f ()
498- after := numInserts ()
499- return (after - before ) / timeutil .Since (tBegin ).Seconds ()
500- }
501-
502- const kv = "./cockroach workload run kv --duration=10m --read-percent=0"
503-
504- // Initialize the database with ~10k ranges so that the absence of
505- // quiescence hits hard once a node goes down.
506- c .Run (ctx , option .WithNodes (c .WorkloadNode ()), "./cockroach workload run kv --init --max-ops=1 --splits 10000 --concurrency 100 {pgurl:1}" )
507- c .Run (ctx , option .WithNodes (c .WorkloadNode ()), kv + " --seed 0 {pgurl:1}" )
508- // Measure qps with all nodes up (i.e. with quiescence).
509- qpsAllUp := qps (func () {
510- c .Run (ctx , option .WithNodes (c .WorkloadNode ()), kv + " --seed 1 {pgurl:1}" )
511- })
512- // Graceful shut down third node.
513- m .ExpectDeath ()
514- c .Stop (
515- ctx , t .L (), option .NewStopOpts (option .Graceful (30 )), c .Node (len (c .CRDBNodes ())),
516- )
517- // Measure qps with node down (i.e. without quiescence).
518- qpsOneDown := qps (func () {
519- // Use a different seed to make sure it's not just stepping into the
520- // other earlier kv invocation's footsteps.
521- c .Run (ctx , option .WithNodes (c .WorkloadNode ()), kv + " --seed 2 {pgurl:1}" )
522- })
523-
524- if minFrac , actFrac := 0.8 , qpsOneDown / qpsAllUp ; actFrac < minFrac {
525- t .Fatalf (
526- "QPS dropped from %.2f to %.2f (factor of %.2f, min allowed %.2f)" ,
527- qpsAllUp , qpsOneDown , actFrac , minFrac ,
528- )
529- }
530- t .L ().Printf ("QPS went from %.2f to %2.f with one node down\n " , qpsAllUp , qpsOneDown )
531- },
532- })
533- }
534-
535460func registerKVGracefulDraining (r registry.Registry ) {
536461 r .Add (registry.TestSpec {
537462 Name : "kv/gracefuldraining" ,
0 commit comments