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

ci/tidb/check_2: remove realtikv tests #975

Merged
merged 2 commits into from
May 18, 2022
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
73 changes: 0 additions & 73 deletions jenkins/pipelines/ci/tidb/tidb_ghpr_check_2.groovy
Original file line number Diff line number Diff line change
Expand Up @@ -63,8 +63,6 @@ node("master") {
println "go image: ${POD_GO_IMAGE}"
}

def sessionTestSuitesString = "testPessimisticSuite"

def run_with_pod(Closure body) {
def label = "jenkins-check-2-${BUILD_NUMBER}"
def cloud = "kubernetes"
Expand Down Expand Up @@ -132,70 +130,6 @@ def upload_test_result(reportDir) {
}
}

def test_suites = { suites,option ->
run_with_pod {
deleteDir()
unstash 'tidb'
container("golang") {
timeout(1320) {
ws = pwd()
def tikv_refs = "${FILE_SERVER_URL}/download/refs/pingcap/tikv/${TIKV_BRANCH}/sha1"
def tikv_sha1 = sh(returnStdout: true, script: "curl ${tikv_refs}").trim()
tikv_url = "${FILE_SERVER_URL}/download/builds/pingcap/tikv/${tikv_sha1}/centos7/tikv-server.tar.gz"

def pd_refs = "${FILE_SERVER_URL}/download/refs/pingcap/pd/${PD_BRANCH}/sha1"
def pd_sha1 = sh(returnStdout: true, script: "curl ${pd_refs}").trim()
pd_url = "${FILE_SERVER_URL}/download/builds/pingcap/pd/${pd_sha1}/centos7/pd-server.tar.gz"
dir("go/src/github.com/pingcap/tidb") {
try {
sh"""
curl ${tikv_url} | tar xz
curl ${pd_url} | tar xz bin
make failpoint-enable

# Disable pipelined pessimistic lock temporarily until tikv#11649 is resolved
echo -e "[pessimistic-txn]\npipelined = false" > tikv.toml

bin/pd-server -name=pd1 --data-dir=pd1 --client-urls=http://127.0.0.1:2379 --peer-urls=http://127.0.0.1:2378 -force-new-cluster &> pd1.log &
bin/tikv-server --pd=127.0.0.1:2379 -s tikv1 --addr=0.0.0.0:20160 --advertise-addr=127.0.0.1:20160 --advertise-status-addr=127.0.0.1:20165 -C tikv.toml -f tikv1.log &

bin/pd-server -name=pd2 --data-dir=pd2 --client-urls=http://127.0.0.1:2389 --peer-urls=http://127.0.0.1:2388 -force-new-cluster &> pd2.log &
bin/tikv-server --pd=127.0.0.1:2389 -s tikv2 --addr=0.0.0.0:20170 --advertise-addr=127.0.0.1:20170 --advertise-status-addr=127.0.0.1:20175 -C tikv.toml -f tikv2.log &

bin/pd-server -name=pd3 --data-dir=pd3 --client-urls=http://127.0.0.1:2399 --peer-urls=http://127.0.0.1:2398 -force-new-cluster &> pd3.log &
bin/tikv-server --pd=127.0.0.1:2399 -s tikv3 --addr=0.0.0.0:20190 --advertise-addr=127.0.0.1:20190 --advertise-status-addr=127.0.0.1:20185 -C tikv.toml -f tikv3.log &

cd session
export log_level=error
go install gotest.tools/gotestsum@latest
gotestsum --format standard-verbose --junitfile "junit-report.xml" -- -with-tikv -pd-addrs=127.0.0.1:2379,127.0.0.1:2389,127.0.0.1:2399 -timeout 20m -vet=off ${option} '${suites}'
#go test -with-tikv -pd-addrs=127.0.0.1:2379 -timeout 20m -vet=off
"""
}catch (Exception e){
sh "cat ${ws}/go/src/github.com/pingcap/tidb/pd1.log || true"
sh "cat ${ws}/go/src/github.com/pingcap/tidb/tikv1.log || true"
sh "cat ${ws}/go/src/github.com/pingcap/tidb/pd2.log || true"
sh "cat ${ws}/go/src/github.com/pingcap/tidb/tikv2.log || true"
sh "cat ${ws}/go/src/github.com/pingcap/tidb/pd3.log || true"
sh "cat ${ws}/go/src/github.com/pingcap/tidb/tikv3.log || true"
throw e
}finally {
junit testResults: "**/junit-report.xml"
sh """
set +e
killall -9 -r -q tikv-server
killall -9 -r -q pd-server
set -e
"""
upload_test_result("session/junit-report.xml")
}
}
}
}
}
}


try {
stage("Pre-check"){
if (!params.force){
Expand Down Expand Up @@ -292,13 +226,6 @@ try {


if (ghprbTargetBranch == "master"){
tests["test session with real tikv suites ${sessionTestSuitesString}"] = {
test_suites(sessionTestSuitesString, "-check.f")
}
tests["test session with real tikv exclude suites ${sessionTestSuitesString}"] = {
test_suites(sessionTestSuitesString, "-check.exclude")
}

tests["New Collation Enabled"] = {
run_with_pod {
deleteDir()
Expand Down