aboutsummaryrefslogtreecommitdiffhomepage
path: root/tools/run_tests/performance
diff options
context:
space:
mode:
authorGravatar murgatroid99 <mlumish@google.com>2018-04-26 14:23:49 -0700
committerGravatar murgatroid99 <mlumish@google.com>2018-04-26 14:23:49 -0700
commitfbf3bd460b12313802b2d4a752f544dbcf241c18 (patch)
treebbbc4eae178f531823a91c0eb51131de2c800db1 /tools/run_tests/performance
parent5f3aa5ca0b97d05cc0b81efb149af1f2a5b8d741 (diff)
Fix some issues with Node benchmark scripts
Diffstat (limited to 'tools/run_tests/performance')
-rwxr-xr-xtools/run_tests/performance/build_performance.sh5
-rwxr-xr-x[-rw-r--r--]tools/run_tests/performance/build_performance_node.sh2
-rwxr-xr-x[-rw-r--r--]tools/run_tests/performance/run_worker_node.sh4
-rw-r--r--tools/run_tests/performance/scenario_config.py15
4 files changed, 16 insertions, 10 deletions
diff --git a/tools/run_tests/performance/build_performance.sh b/tools/run_tests/performance/build_performance.sh
index 55762c6a23..35d9e90598 100755
--- a/tools/run_tests/performance/build_performance.sh
+++ b/tools/run_tests/performance/build_performance.sh
@@ -55,10 +55,11 @@ do
"csharp")
python tools/run_tests/run_tests.py -l "$language" -c "$CONFIG" --build_only -j 8 --compiler coreclr
;;
+ "node"|"node_purejs")
+ tools/run_tests/performance/build_performance_node.sh
+ ;;
*)
python tools/run_tests/run_tests.py -l "$language" -c "$CONFIG" --build_only -j 8
;;
- "node")
- tools/run_tests/performance/build_performance_node.sh
esac
done
diff --git a/tools/run_tests/performance/build_performance_node.sh b/tools/run_tests/performance/build_performance_node.sh
index 1e3f5df230..74adde91f3 100644..100755
--- a/tools/run_tests/performance/build_performance_node.sh
+++ b/tools/run_tests/performance/build_performance_node.sh
@@ -15,6 +15,8 @@
set +ex
+. "$HOME/.nvm/nvm.sh"
+
nvm install 9
set -ex
diff --git a/tools/run_tests/performance/run_worker_node.sh b/tools/run_tests/performance/run_worker_node.sh
index 2511522c71..a9bbdccbc1 100644..100755
--- a/tools/run_tests/performance/run_worker_node.sh
+++ b/tools/run_tests/performance/run_worker_node.sh
@@ -13,6 +13,8 @@
# See the License for the specific language governing permissions and
# limitations under the License.
+. "$HOME/.nvm/nvm.sh"
+
nvm use 9
set -ex
@@ -27,4 +29,4 @@ cd "$(dirname "$0")/../../.."
# Enter the grpc-node repo root (expected to be next to grpc repo root)
cd ../grpc-node
-node -r "test/fixtures/$fixture.js" tools/run_tests/performance/worker.js "$@"
+node -r "./test/fixtures/$fixture" test/performance/worker.js "$@"
diff --git a/tools/run_tests/performance/scenario_config.py b/tools/run_tests/performance/scenario_config.py
index dde299ae36..bd65b82945 100644
--- a/tools/run_tests/performance/scenario_config.py
+++ b/tools/run_tests/performance/scenario_config.py
@@ -1160,7 +1160,8 @@ class NodeLanguage:
def worker_cmdline(self):
fixture = 'native_js' if self.node_purejs else 'native_native'
- return ['tools/run_tests/performance/run_worker_node.sh', fixture]
+ return ['tools/run_tests/performance/run_worker_node.sh', fixture,
+ '--benchmark_impl=grpc']
def worker_port_offset(self):
if self.node_purejs:
@@ -1175,7 +1176,7 @@ class NodeLanguage:
yield _ping_pong_scenario(
'%s_to_node_generic_async_streaming_ping_pong_%s' %
- (secstr, node_implementation),
+ (node_implementation, secstr),
rpc_type='STREAMING',
client_type='ASYNC_CLIENT',
server_type='ASYNC_GENERIC_SERVER',
@@ -1187,7 +1188,7 @@ class NodeLanguage:
yield _ping_pong_scenario(
'%s_to_node_protobuf_async_streaming_ping_pong_%s' %
- (secstr, node_implementation),
+ (node_implementation, secstr),
rpc_type='STREAMING',
client_type='ASYNC_CLIENT',
server_type='ASYNC_SERVER',
@@ -1197,7 +1198,7 @@ class NodeLanguage:
yield _ping_pong_scenario(
'%s_to_node_protobuf_async_unary_ping_pong_%s' %
- (secstr, node_implementation),
+ (node_implementation, secstr),
rpc_type='UNARY',
client_type='ASYNC_CLIENT',
server_type='ASYNC_SERVER',
@@ -1208,7 +1209,7 @@ class NodeLanguage:
yield _ping_pong_scenario(
'%s_to_node_protobuf_async_unary_qps_unconstrained_%s' %
- (secstr, node_implementation),
+ (node_implementation, secstr),
rpc_type='UNARY',
client_type='ASYNC_CLIENT',
server_type='ASYNC_SERVER',
@@ -1219,7 +1220,7 @@ class NodeLanguage:
yield _ping_pong_scenario(
'%s_to_node_protobuf_async_streaming_qps_unconstrained_%s' %
- (secstr, node_implementation),
+ (node_implementation, secstr),
rpc_type='STREAMING',
client_type='ASYNC_CLIENT',
server_type='ASYNC_SERVER',
@@ -1230,7 +1231,7 @@ class NodeLanguage:
yield _ping_pong_scenario(
'%s_to_node_generic_async_streaming_qps_unconstrained_%s' %
- (secstr, node_implementation),
+ (node_implementation, secstr),
rpc_type='STREAMING',
client_type='ASYNC_CLIENT',
server_type='ASYNC_GENERIC_SERVER',