TCP info classes

_rrClientType Class

class libpyRR39._rrClientType

0

default

1

workstation

2

renderfarm

3

cloud

_speedPerUser Class

class libpyRR39._speedPerUser

class _speedPerUser properties:

Type

Name

Description

int

clients

number used clients

float

clientsPercentage

percentage of used clients

int

jobs

number of jobs belonging to user

str

name

user name, always lowercase

float

ps

used processor speed

float

psPercentage

percentage of used processor speed

_speedPerUserList Class

class libpyRR39._speedPerUserList

class _speedPerUserList properties:

Type

Name

Description

int

count

Number of users

class _speedPerUserList functions:

Return Type

Name

Description

_speedPerUser

at(int index)

_speedPerUser at given index

_licenseItem Class

class libpyRR39._licenseItem

Information about a render license. Optionally, a different number of license can be set for workstation, renderfarm, and cloud clients. the enum libpyRR39._rrClientType can be used to get and set the available licenses of each type.This is the same information displayed in the Global Info panel in rrControl. Licenses can be reserved for artists using _rrTCP.infoFreeLicense() and returned to the farm using _rrTCP.infoReturnLicense().

Example, list all default license limits and add a limit the usage of Arnold licenses to 10 on cloud clients

from rr_python_utils.load_rrlib import rrLib
import rr_python_utils.connection as rr_connect

# Get the render farm information
tcp = rr_connect.server_connect()
tcp.infoGetGlobalInfo()

for i in range(tcp.info.licenses.count()):
    license = tcp.info.licenses.at(i)
    print(f"{license.softwareName}, {license.pluginName}:")

    if license.isEnabled(rrLib._rrClientType.default) :
        print(f"    Using{ license.inUse(rrLib._rrClientType.default) } of{ license.count(rrLib._rrClientType.default) } Default licenses")

    # limit cloud clients to ten Arnold licenses
    if license.softwareName.lower() == 'arnold' or license.pluginName.lower() == 'arnold':
        license.setCount(rrLib._rrClientType.cloud, 10)

# Save Changes
if not tcp.infoSaveLicense():
    print("ERROR: License changes were not saved")

class _licenseItem properties:

Type

Name

Description

str

pluginName

Name of the render application (Maya, Nuke)

str

softwareName

Name of the render application (Maya, Nuke)

str

version

Version of the render application

class _licenseItem functions:

Return Type

Name

Description

int

blocked(_rrClientType client_type)

Licenses left available for users

float

cost(_rrClientType client_type)

Return cost set for given libpyRR39._rrClientType

int

count(_rrClientType client_type)

Number of render licenses for given libpyRR39._rrClientType

int

inUse(_rrClientType client_type)

Licenses used by render jobs when libpyRR39._rrTCP.infoGetGlobalInfo() was called

bool

isEnabled(_rrClientType client_type)

Return True if license count is enabled for given libpyRR39._rrClientType

bool

isUnlimited(int client_type)

Return True if there is no license limit for given libpyRR39._rrClientType

setCost(_rrClientType client_type, float cost)

Set render cost for given libpyRR39._rrClientType

setCount(_rrClientType client_type, int cost)

Set number of render licenses for given libpyRR39._rrClientType

setEnabled(_rrClientType client_type, bool isEnabled)

Enable license count for given libpyRR39._rrClientType

setUnlimited(int client_type, bool isUnlimited)

Enale unlimited licenses for given libpyRR39._rrClientType

_infoLicense Class

class libpyRR39._infoLicense

Contains _licenseItem information of render apps with limited licenses. Requires to call _rrTCP.infoGetGlobalInfo() first.

class _infoLicense functions:

Return Type

Name

Description

_licenseItem

at(int index)

Render App license settings at given index

int

count()

Number of Render Apps license settings

_infoGlobal Class

class libpyRR39._infoGlobal

Overal information about the render farm, requires to call : func:_rrTCP.infoGetGlobalInfo first.

class _infoGlobal properties:

Type

Name

Description

int

ableToWOL

how many machines available for Wake On Lan

datetime.datetime

lastWOL

when was the last WOL command

_infoLicense

licenses

list of RenderApp licenses

int

segmentsDone

how many job segments have been send to clients in the last hour, reset to 0 every half hour

int

segmentsTime

average render time per job segment (in seconds)

struct _rrsSpeedPerUser

speedPerExclusiveList

_speedPerUserList

struct _rrsSpeedPerUser

speedPerProjectList

_speedPerUserList

struct _rrsSpeedPerUser

speedPerRendererList

_speedPerUserList

struct _rrsSpeedPerUser

speedPerUserList

_speedPerUserList

int

totalClientNeed

how many machines do we need to render all frames NOW

class _infoGlobal functions:

Return Type

Name

Description

str

asString()

Overal information as String