Skip to content

Commit

Permalink
add requested changes
Browse files Browse the repository at this point in the history
Signed-off-by: Divya Madala <[email protected]>
  • Loading branch information
Divyaasm committed May 8, 2024
1 parent dc42bef commit a6cd3cf
Show file tree
Hide file tree
Showing 5 changed files with 9 additions and 9 deletions.
4 changes: 2 additions & 2 deletions jenkins/opensearch/benchmark-test-endpoint.jenkinsfile
Original file line number Diff line number Diff line change
Expand Up @@ -130,14 +130,14 @@ parameters {
captureSegmentReplicationStat: CAPTURE_SEGMENT_REPLICATION_STAT,
telemetryParams: TELEMETRY_PARAMS
)
stash includes: 'test_execution.*', name: "benchmark"
stash includes: 'test_execution*.csv', name: "benchmark"

}
}
post {
always {
unstash "benchmark"
archiveArtifacts artifacts: 'test_execution.*'
archiveArtifacts artifacts: 'test_execution*.csv'
postCleanup()
}
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -57,6 +57,6 @@ def run_tests(self) -> None:
with BenchmarkCreateCluster.create(self.args, self.test_manifest, config, current_workspace) as test_cluster:
benchmark_test_suite = BenchmarkTestSuite(test_cluster.endpoint_with_port, self.security, self.args, test_cluster.fetch_password())
try:
benchmark_test_suite.execute()
retry_call(benchmark_test_suite.execute, tries=3, delay=60, backoff=2)
finally:
subprocess.check_call(f"docker rm docker-container-{self.args.stack_suffix}", cwd=os.getcwd(), shell=True, stdout=subprocess.PIPE, stderr=subprocess.PIPE)
4 changes: 2 additions & 2 deletions src/test_workflow/benchmark_test/benchmark_test_suite.py
Original file line number Diff line number Diff line change
Expand Up @@ -91,8 +91,8 @@ def convert(self, results: str) -> None:
with open(results) as file:
data = json.load(file)
formatted_data = pd.json_normalize(data["results"]["op_metrics"])
formatted_data.to_csv(os.path.join(os.getcwd(), "test_execution.csv"), index=False)
df = pd.read_csv(os.path.join(os.getcwd(), "test_execution.csv"))
formatted_data.to_csv(os.path.join(os.getcwd(), f"test_execution_{self.args.stack_suffix}.csv"), index=False)
df = pd.read_csv(os.path.join(os.getcwd(), f"test_execution_{self.args.stack_suffix}.csv"))
pd.set_option('display.width', int(2 * shutil.get_terminal_size().columns))
pd.set_option('display.max_rows', None)
pd.set_option('display.max_columns', None)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -29,8 +29,8 @@
runBenchmarkTestScript.readFile({file=/tmp/workspace/benchmark.ini})
runBenchmarkTestScript.writeFile({file=/tmp/workspace/benchmark.ini, text=})
runBenchmarkTestScript.sh(set +x && ./test.sh benchmark-test --cluster-endpoint opensearch-ABCxdfdfhyfk.com --workload nyc-taxis --benchmark-config /tmp/workspace/benchmark.ini --user-tag run-type:test,security-enabled:true --suffix 307 --test-procedure append-no-conflicts --telemetry-params '{"telemetry_setting":"value"}')
benchmark-test-endpoint.stash({includes=test_execution.*, name=benchmark})
benchmark-test-endpoint.stash({includes=test_execution*.csv, name=benchmark})
benchmark-test-endpoint.unstash(benchmark)
benchmark-test-endpoint.archiveArtifacts({artifacts=test_execution.*})
benchmark-test-endpoint.archiveArtifacts({artifacts=test_execution*.csv})
benchmark-test-endpoint.postCleanup()
postCleanup.cleanWs({disableDeferredWipeout=true, deleteDirs=true})
Original file line number Diff line number Diff line change
Expand Up @@ -29,8 +29,8 @@
runBenchmarkTestScript.readFile({file=/tmp/workspace/benchmark.ini})
runBenchmarkTestScript.writeFile({file=/tmp/workspace/benchmark.ini, text=})
runBenchmarkTestScript.sh(set +x && ./test.sh benchmark-test --cluster-endpoint opensearch-ABCxdfdfhyfk.com --workload nyc-taxis --benchmark-config /tmp/workspace/benchmark.ini --user-tag run-type:test,security-enabled:true --suffix 307 --test-procedure append-no-conflicts --telemetry-params '{"telemetry_setting":"value"}')
benchmark-test-endpoint.stash({includes=test_execution.*, name=benchmark})
benchmark-test-endpoint.stash({includes=test_execution*.csv, name=benchmark})
benchmark-test-endpoint.unstash(benchmark)
benchmark-test-endpoint.archiveArtifacts({artifacts=test_execution.*})
benchmark-test-endpoint.archiveArtifacts({artifacts=test_execution*.csv})
benchmark-test-endpoint.postCleanup()
postCleanup.cleanWs({disableDeferredWipeout=true, deleteDirs=true})

0 comments on commit a6cd3cf

Please sign in to comment.