@@ -124,6 +124,9 @@ functions:
124124 export ATLAS_SERVERLESS_LB_URI="${atlas_serverless_lb_uri}"
125125 export RVM_RUBY="${RVM_RUBY}"
126126
127+ export SERVERLESS_DRIVERS_GROUP="${SERVERLESS_DRIVERS_GROUP}"
128+ export SERVERLESS_API_PUBLIC_KEY="${SERVERLESS_API_PUBLIC_KEY}"
129+ export SERVERLESS_API_PRIVATE_KEY="${SERVERLESS_API_PRIVATE_KEY}"
127130 export SERVERLESS_ATLAS_USER="${SERVERLESS_ATLAS_USER}"
128131 export SERVERLESS_ATLAS_PASSWORD="${SERVERLESS_ATLAS_PASSWORD}"
129132 EOT
@@ -377,38 +380,9 @@ functions:
377380 script : |
378381 ${PREPARE_SHELL}
379382 TEST_CMD="bundle exec rake driver_bench" PERFORMANCE_RESULTS_FILE="$PROJECT_DIRECTORY/perf.json" .evergreen/run-tests.sh
380- - command : shell.exec
383+ - command : perf.send
381384 params :
382- script : |
383- # We use the requester expansion to determine whether the data is from a mainline evergreen run or not
384- if [ "${requester}" == "commit" ]; then
385- is_mainline=true
386- else
387- is_mainline=false
388- fi
389-
390- # We parse the username out of the order_id as patches append that in and SPS does not need that information
391- parsed_order_id=$(echo "${revision_order_id}" | awk -F'_' '{print $NF}')
392-
393- # Submit the performance data to the SPS endpoint
394- response=$(curl -s -w "\nHTTP_STATUS:%{http_code}" -X 'POST' \
395- "https://performance-monitoring-api.corp.mongodb.com/raw_perf_results/cedar_report?project=${project_id}&version=${version_id}&variant=${build_variant}&order=$parsed_order_id&task_name=${task_name}&task_id=${task_id}&execution=${execution}&mainline=$is_mainline" \
396- -H 'accept: application/json' \
397- -H 'Content-Type: application/json' \
398- -d @${PROJECT_DIRECTORY}/perf.json)
399-
400- http_status=$(echo "$response" | grep "HTTP_STATUS" | awk -F':' '{print $2}')
401- response_body=$(echo "$response" | sed '/HTTP_STATUS/d')
402-
403- # We want to throw an error if the data was not successfully submitted
404- if [ "$http_status" -ne 200 ]; then
405- echo "Error: Received HTTP status $http_status"
406- echo "Response Body: $response_body"
407- exit 1
408- fi
409-
410- echo "Response Body: $response_body"
411- echo "HTTP Status: $http_status"
385+ file : " ${PROJECT_DIRECTORY}/perf.json"
412386
413387 " run tests " :
414388 - command : shell.exec
0 commit comments