ID 500191 - Full number of system threads are not utilized when importing UI4 in Batch or Script mode

Follow

Problem summary
Although not recommended, importing the UI4.App.Preferences module in Batch or Script mode causes Katana to only use the number of threads specified in the interactiveRenderThreads3D preference. If a Katana preferences file does not exist, the render will still use less than the full amount of threads available to the system.

Customer reported version
katana.n_a

Customer reported platform

Steps to reproduce
1) Open Katana in Interactive mode and edit the application.rendering.interactiveRenderThreadOverride preference to 1.

Note: Make sure the interactiveRenderThreadOverride preference is enabled.
2) Create a Python file in /tmp/mkr/Plugins/test.py with:
import UI4.App.Preferences
3) Add /tmp/mkr to the KATANA_RESOURCES environment variable
4) Batch render any RenderMan or Arnold Katana project.
Note: 3Delight ignores the interactiveRenderThreads3D preference by default.

Expected behavior
The batch render uses all available system threads.

Actual behavior
The batch render only uses the number of threads specified in the interactiveRenderThreads3D preference.

Workaround
Do not import the UI4 module in Batch or Script modes.

Reproduced by support
This bug has been reproduced in:
Katana 5.0v1 - CentOS 7
Katana 4.5v1 - CentOS 7
Katana 4.0v1 - CentOS 7
Katana 3.6v1 - CentOS 7
Katana 3.5v1 - CentOS 7
Katana 3.2v1 - CentOS 7
Katana 3.1v1 - CentOS 7
Katana 3.0v1 - CentOS 7
Katana 2.5v1 - CentOS 7
Katana 2.0v1 - CentOS 7

Earliest version tested
Katana 2.0v1 - This issue appears to be in all versions of the product

    We're sorry to hear that

    Please tell us why