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

sessionctx: change @@tidb_enable_gogc_tuner default value to 0 #49420

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Show file tree
Hide file tree
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
2 changes: 1 addition & 1 deletion pkg/sessionctx/variable/tidb_vars.go
Original file line number Diff line number Diff line change
Expand Up @@ -1375,7 +1375,7 @@ const (
DefTiDBServerMemoryLimitSessMinSize = 128 << 20
DefTiDBMergePartitionStatsConcurrency = 1
DefTiDBServerMemoryLimitGCTrigger = 0.7
DefTiDBEnableGOGCTuner = true
DefTiDBEnableGOGCTuner = false
// DefTiDBGOGCTunerThreshold is to limit TiDBGOGCTunerThreshold.
DefTiDBGOGCTunerThreshold float64 = 0.6
DefTiDBGOGCMaxValue = 500
Expand Down
2 changes: 2 additions & 0 deletions pkg/sessionctx/variable/varsutil_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,7 @@ import (
"github.com/pingcap/tidb/pkg/kv"
"github.com/pingcap/tidb/pkg/parser/mysql"
"github.com/pingcap/tidb/pkg/parser/terror"
"github.com/pingcap/tidb/pkg/util/gctuner"
"github.com/stretchr/testify/require"
)

Expand Down Expand Up @@ -92,6 +93,7 @@ func TestNewSessionVars(t *testing.T) {
require.Equal(t, DefTiDBAnalyzeVersion, vars.AnalyzeVersion)
require.Equal(t, DefCTEMaxRecursionDepth, vars.CTEMaxRecursionDepth)
require.Equal(t, int64(DefTiDBTmpTableMaxSize), vars.TMPTableSize)
require.Equal(t, DefTiDBEnableGOGCTuner, gctuner.EnableGOGCTuner.Load())

assertFieldsGreaterThanZero(t, reflect.ValueOf(vars.MemQuota))
assertFieldsGreaterThanZero(t, reflect.ValueOf(vars.BatchSize))
Expand Down