1
Vote

Example Application - Processor Count, meant for remote node is running locally

description

The call to get Processor Count on the Worker node was incorrect.
 
MPAPI Examples
 
Namespace: DistributedPrimeCalculatorApp
File: MainWorker.cs
Line: 25
 
Code:
 
//Will not execute "Environment.ProcessorCount" on remote machine, will run locally.
 
"
int processorCount = Node.GetProcessorCount();
"
 
Fix:
 
//Pass the nodeId as parameter to call the correct Overload, resulting in remoted call.
 
"
int processorCount = Node.GetProcessorCount(nodeId);
"

comments