Skip to main content

Class: PollerScalingDecision

taskqueue.v1.PollerScalingDecision

Attached to task responses to give hints to the SDK about how it may adjust its number of pollers.

Properties​

pollRequestDeltaSuggestion​

• pollRequestDeltaSuggestion: number

How many poll requests to suggest should be added or removed, if any. As of now, server only scales up or down by 1. However, SDKs should allow for other values (while staying within defined min/max).

The SDK is free to ignore this suggestion, EX: making more polls would not make sense because all slots are already occupied.

Methods​

toJSON​

▸ toJSON(): Object

Converts this PollerScalingDecision to JSON.

Returns​

Object

JSON object


create​

▸ create(properties?): PollerScalingDecision & $Properties

Creates a new PollerScalingDecision instance using the specified properties.

Parameters​

NameTypeDescription
properties?$PropertiesProperties to set

Returns​

PollerScalingDecision & $Properties

PollerScalingDecision instance

▸ create(properties?): PollerScalingDecision

Parameters​

NameType
properties?$Properties

Returns​

PollerScalingDecision


decode​

▸ decode(reader, length?): PollerScalingDecision & $Properties

Decodes a PollerScalingDecision message from the specified reader or buffer.

Parameters​

NameTypeDescription
readerUint8Array | ReaderReader or buffer to decode from
length?numberMessage length if known beforehand

Returns​

PollerScalingDecision & $Properties

PollerScalingDecision

Throws

If the payload is not a reader or valid buffer

Throws

If required fields are missing


decodeDelimited​

▸ decodeDelimited(reader): PollerScalingDecision & $Properties

Decodes a PollerScalingDecision message from the specified reader or buffer, length delimited.

Parameters​

NameTypeDescription
readerUint8Array | ReaderReader or buffer to decode from

Returns​

PollerScalingDecision & $Properties

PollerScalingDecision

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 PollerScalingDecision message. Does not implicitly temporal.api.taskqueue.v1.PollerScalingDecision.verify|verify messages.

Parameters​

NameTypeDescription
message$PropertiesPollerScalingDecision message or plain object to encode
writer?WriterWriter to encode to

Returns​

Writer

Writer


encodeDelimited​

▸ encodeDelimited(message, writer?): Writer

Encodes the specified PollerScalingDecision message, length delimited. Does not implicitly temporal.api.taskqueue.v1.PollerScalingDecision.verify|verify messages.

Parameters​

NameTypeDescription
message$PropertiesPollerScalingDecision message or plain object to encode
writer?WriterWriter to encode to

Returns​

Writer

Writer


fromObject​

▸ fromObject(object): PollerScalingDecision

Creates a PollerScalingDecision message from a plain object. Also converts values to their respective internal types.

Parameters​

NameTypeDescription
objectObjectPlain object

Returns​

PollerScalingDecision

PollerScalingDecision


toObject​

▸ toObject(message, options?): Object

Creates a plain object from a PollerScalingDecision message. Also converts values to other types if specified.

Parameters​

NameTypeDescription
messagePollerScalingDecisionPollerScalingDecision
options?IConversionOptionsConversion options

Returns​

Object

Plain object