Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
8 changes: 4 additions & 4 deletions go/vt/vttablet/tabletserver/txthrottler/tx_throttler.go
Original file line number Diff line number Diff line change
Expand Up @@ -249,7 +249,7 @@ func (t *txThrottler) Open() (err error) {
}
log.Info("txThrottler: opening")
t.throttlerRunning.Set(1)
t.state, err = newTxThrottlerState(t.topoServer, t.config, t.target.Keyspace, t.target.Shard, t.target.Cell)
t.state, err = newTxThrottlerState(t.topoServer, t.config, t.target)
return err
}

Expand Down Expand Up @@ -294,7 +294,7 @@ func (t *txThrottler) Throttle(priority int) (result bool) {
return result
}

func newTxThrottlerState(topoServer *topo.Server, config *txThrottlerConfig, keyspace, shard, cell string) (*txThrottlerState, error) {
func newTxThrottlerState(topoServer *topo.Server, config *txThrottlerConfig, target *querypb.Target) (*txThrottlerState, error) {
maxReplicationLagModuleConfig := throttler.MaxReplicationLagModuleConfig{Configuration: config.throttlerConfig}

t, err := throttlerFactory(
Expand Down Expand Up @@ -325,8 +325,8 @@ func newTxThrottlerState(topoServer *topo.Server, config *txThrottlerConfig, key
topoServer,
result.healthCheck, /* LegacyTabletRecorder */
cell,
keyspace,
shard,
target.Keyspace,
target.Shard,
discovery.DefaultTopologyWatcherRefreshInterval,
discovery.DefaultTopoReadConcurrency))
}
Expand Down