Skip to content

Commit

Permalink
benchmark: use cluster.isPrimary instead of cluster.isMaster
Browse files Browse the repository at this point in the history
`cluster.isMaster` was deprecated. So need to use `cluster.isPrimary`
for benchmark.

Refs: #47981
  • Loading branch information
deokjinkim committed May 14, 2023
1 parent abb1c45 commit fab804c
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion benchmark/cluster/echo.js
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
'use strict';

const cluster = require('cluster');
if (cluster.isMaster) {
if (cluster.isPrimary) {
const common = require('../common.js');
const bench = common.createBenchmark(main, {
workers: [1],
Expand Down
2 changes: 1 addition & 1 deletion benchmark/http/cluster.js
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ const PORT = common.PORT;

const cluster = require('cluster');
let bench;
if (cluster.isMaster) {
if (cluster.isPrimary) {
bench = common.createBenchmark(main, {
// Unicode confuses ab on os x.
type: ['bytes', 'buffer'],
Expand Down

0 comments on commit fab804c

Please sign in to comment.