Class: RoutingConfig
deployment.v1.RoutingConfig
Represents a RoutingConfig.
Implements
Constructors
constructor
• new RoutingConfig(properties?
): RoutingConfig
Constructs a new RoutingConfig.
Parameters
Name | Type | Description |
---|---|---|
properties? | IRoutingConfig | Properties to set |
Returns
Properties
currentDeploymentVersion
• Optional
currentDeploymentVersion: null
| IWorkerDeploymentVersion
Specifies which Deployment Version should receive new workflow executions and tasks of
existing unversioned or AutoUpgrade workflows.
Nil value means no Version in this Deployment (except Ramping Version, if present) receives traffic other than tasks of previously Pinned workflows. In absence of a Current Version, remaining traffic after any ramp (if set) goes to unversioned workers (those with UNVERSIONED
(or unspecified) WorkerVersioningMode
.).
Note: Current Version is overridden by the Ramping Version for a portion of traffic when ramp percentage
is non-zero (see ramping_deployment_version
and ramping_version_percentage
).
Implementation of
IRoutingConfig.currentDeploymentVersion
currentVersion
• currentVersion: string
Deprecated. Use current_deployment_version
.
Implementation of
currentVersionChangedTime
• Optional
currentVersionChangedTime: null
| ITimestamp
Last time current version was changed.
Implementation of
IRoutingConfig.currentVersionChangedTime
rampingDeploymentVersion
• Optional
rampingDeploymentVersion: null
| IWorkerDeploymentVersion
When ramp percentage is non-zero, that portion of traffic is shifted from the Current Version to the Ramping Version.
Must always be different from current_deployment_version
unless both are nil.
Nil value represents all the unversioned workers (those with UNVERSIONED
(or unspecified) WorkerVersioningMode
.)
Note that it is possible to ramp from one Version to another Version, or from unversioned
workers to a particular Version, or from a particular Version to unversioned workers.
Implementation of
IRoutingConfig.rampingDeploymentVersion
rampingVersion
• rampingVersion: string
Deprecated. Use ramping_deployment_version
.
Implementation of
rampingVersionChangedTime
• Optional
rampingVersionChangedTime: null
| ITimestamp
Last time ramping version was changed. Not updated if only the ramp percentage changes.
Implementation of
IRoutingConfig.rampingVersionChangedTime
rampingVersionPercentage
• rampingVersionPercentage: number
Percentage of tasks that are routed to the Ramping Version instead of the Current Version. Valid range: [0, 100]. A 100% value means the Ramping Version is receiving full traffic but not yet "promoted" to be the Current Version, likely due to pending validations. A 0% value means the Ramping Version is receiving no traffic.
Implementation of
IRoutingConfig.rampingVersionPercentage
rampingVersionPercentageChangedTime
• Optional
rampingVersionPercentageChangedTime: null
| ITimestamp
Last time ramping version percentage was changed. If ramping version is changed, this is also updated, even if the percentage stays the same.
Implementation of
IRoutingConfig.rampingVersionPercentageChangedTime
Methods
toJSON
▸ toJSON(): Object
Converts this RoutingConfig to JSON.
Returns
Object
JSON object
create
▸ create(properties?
): RoutingConfig
Creates a new RoutingConfig instance using the specified properties.
Parameters
Name | Type | Description |
---|---|---|
properties? | IRoutingConfig | Properties to set |
Returns
RoutingConfig instance
decode
▸ decode(reader
, length?
): RoutingConfig
Decodes a RoutingConfig message from the specified reader or buffer.
Parameters
Name | Type | Description |
---|---|---|
reader | Uint8Array | Reader | Reader or buffer to decode from |
length? | number | Message length if known beforehand |
Returns
RoutingConfig
Throws
If the payload is not a reader or valid buffer
Throws
If required fields are missing
decodeDelimited
▸ decodeDelimited(reader
): RoutingConfig
Decodes a RoutingConfig message from the specified reader or buffer, length delimited.
Parameters
Name | Type | Description |
---|---|---|
reader | Uint8Array | Reader | Reader or buffer to decode from |
Returns
RoutingConfig
Throws
If the payload is not a reader or valid buffer
Throws
If required fields are missing
encode
▸ encode(message
, writer?
): Writer
Encodes the specified RoutingConfig message. Does not implicitly temporal.api.deployment.v1.RoutingConfig.verify|verify messages.
Parameters
Name | Type | Description |
---|---|---|
message | IRoutingConfig | RoutingConfig message or plain object to encode |
writer? | Writer | Writer to encode to |
Returns
Writer
Writer
encodeDelimited
▸ encodeDelimited(message
, writer?
): Writer
Encodes the specified RoutingConfig message, length delimited. Does not implicitly temporal.api.deployment.v1.RoutingConfig.verify|verify messages.
Parameters
Name | Type | Description |
---|---|---|
message | IRoutingConfig | RoutingConfig message or plain object to encode |
writer? | Writer | Writer to encode to |
Returns
Writer
Writer
fromObject
▸ fromObject(object
): RoutingConfig
Creates a RoutingConfig message from a plain object. Also converts values to their respective internal types.
Parameters
Name | Type | Description |
---|---|---|
object | Object | Plain object |
Returns
RoutingConfig
getTypeUrl
▸ getTypeUrl(typeUrlPrefix?
): string
Gets the default type url for RoutingConfig
Parameters
Name | Type | Description |
---|---|---|
typeUrlPrefix? | string | your custom typeUrlPrefix(default "type.googleapis.com") |
Returns
string
The default type url
toObject
▸ toObject(message
, options?
): Object
Creates a plain object from a RoutingConfig message. Also converts values to other types if specified.
Parameters
Name | Type | Description |
---|---|---|
message | RoutingConfig | RoutingConfig |
options? | IConversionOptions | Conversion options |
Returns
Object
Plain object