Skip to main content
Version: 2.29.0

AppPlaceholder

The AppPlaceholder represents the "Compute Placeholder" record and is an essential component designed to allow the user to control the cost-latency tradeoff when running applications. You can specify any number of virtual machines to be kept running in anticipation of use. Placeholders are tied to a compute profile. They ensure that if you launch an app with that compute profile, the placeholder will be used.

# Initialize placeholder
data = AppPlaceholder(
uid='049dbcfc-8ec6-11ee-8e98-1388c5d96f68',
name='medium',
profile_id='edge.medium',
quantity=1,
disable=False
)

# Create placeholder
edge.compute.create_placeholder(data)

Properties​

uid​

Property (str). Unique identifier.

name​

Property (str). Display name for the placeholder.

profile_id​

Property (str). Profile's identifying ID.

quantity​

Property (int). Replication quantity.

disable​

Property (bool). True if this placeholder is disabled.

Methods​

to_dict​

to_dict() -> dict

Translates the connection as a dictionary for serialization.

Returns:​

dict Connection contents as a dictionary.