mirror of
https://github.com/grpc/grpc-node.git
synced 2025-12-08 18:23:54 +00:00
Implement core_count RPC for Node.JS to track new master version of services.proto and control.proto
This commit is contained in:
parent
64f3da63ee
commit
45cb2d07d0
@ -33,6 +33,7 @@
|
||||
|
||||
'use strict';
|
||||
|
||||
var os = require('os');
|
||||
var BenchmarkClient = require('./benchmark_client');
|
||||
var BenchmarkServer = require('./benchmark_server');
|
||||
|
||||
@ -130,3 +131,7 @@ exports.runServer = function runServer(call) {
|
||||
});
|
||||
});
|
||||
};
|
||||
|
||||
exports.coreCount = function coreCount(call, callback) {
|
||||
callback(null, {cores: os.cpus().length});
|
||||
};
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user