runtime.processorCount

Note:

The content in this help topic pertains to SuiteScript 2.0.

Property Description

The number of processors available to the current account.

SuiteCloud Processors is the current system used to execute (process) scheduled scripts and map/reduce scripts. This property is helpful if you are a SuiteApp developer and your script needs to know the total number of processors available to a deployment.

For scheduled script deployments that continue to use queues, use runtime.queueCount. With the introduction of SuiteCloud Processors, map/reduce script deployments and new scheduled script deployments no longer use queues, but pre-existing scheduled script deployments continue to use queues until the queues are removed (see SuiteCloud Processors Supported Task Types).

Be aware that the number of processors available may not be the same as the number of queues available. For more information, see SuiteCloud Plus Settings.

Note:

The runtime.processorCount property reflects the number of processors available to an account. It is not impacted by changes to deployments. The value is the same regardless of whether deployments continue to use queues. For more information, see SuiteCloud Processors Supported Task Types.

For more information about scheduled scripts, see SuiteScript 2.x Scheduled Script Type. For more information about map/reduce scripts, see SuiteScript 2.x Map/Reduce Script Type.

Type

number (read-only)

Supported Script Types

Client and server scripts

For more information, see SuiteScript 2.x Script Types.

Module

N/runtime Module

Since

2018.1

Syntax
Important:

The following code sample shows the syntax for this member. It is not a functional example. For a complete script example, see N/runtime Module Script Samples.

          // Add additional code 
...
log.debug('Number of processors available: ' + runtime.processorCount);
...
// Add additional code 

        

Related Topics

N/runtime Module
SuiteScript 2.x Modules
SuiteScript 2.x

General Notices