class DataConverter(WithSerializationContext): (source)
Known subclasses: temporalio.worker._workflow._CommandAwareDataConverter
Data converter for converting and encoding payloads to/from Python values.
This combines PayloadConverter which converts values with
PayloadCodec which encodes bytes.
| Method | __post |
Undocumented |
| Async Method | decode |
Decode payloads into values. |
| Async Method | decode |
Decode and convert failure. |
| Async Method | decode |
decode for the temporalio.api.common.v1.Payloads wrapper. |
| Async Method | encode |
Encode values into payloads. |
| Async Method | encode |
Convert and encode failure. |
| Async Method | encode |
encode for the temporalio.api.common.v1.Payloads wrapper. |
| Method | with |
Return an instance with context set on the component converters. |
| Class Variable | default |
Singleton default data converter. |
| Class Variable | external |
Options for external storage. If None, external storage is disabled. |
| Class Variable | failure |
Failure converter created from the failure_converter_class. |
| Class Variable | payload |
Optional codec for encoding payload bytes. |
| Class Variable | payload |
Payload converter created from the payload_converter_class. |
| Class Variable | payload |
Settings for payload size limits. |
| Static Method | _validate |
Undocumented |
| Async Method | _decode |
Undocumented |
| Async Method | _decode |
Undocumented |
| Async Method | _decode |
Codec decode only. |
| Async Method | _encode |
Undocumented |
| Async Method | _encode |
Undocumented |
| Async Method | _encode |
Codec encode only. |
| Async Method | _external |
External storage retrieve only. |
| Async Method | _external |
External storage store, then validate payload limits. |
| Async Method | _transform |
Undocumented |
| Async Method | _transform |
Undocumented |
| Async Method | _transform |
Undocumented |
| Async Method | _transform |
Undocumented |
| Method | _validate |
Undocumented |
| Method | _with |
Undocumented |
| Class Variable | _payload |
Server-reported limits for payloads. |
| Property | _decode |
Undocumented |
Sequence[ temporalio.api.common.v1.Payload], type_hints: list[ type] | None = None) -> list[ Any]:
(source)
¶
Decode payloads into values.
First decodes payloads using codec then converts payloads to values.
| Parameters | |
payloads:Sequence[ | Payloads to be decoded and converted. |
typelist[ | Undocumented |
| Returns | |
list[ | Decoded and converted values. |
temporalio.api.failure.v1.Failure) -> BaseException:
(source)
¶
Decode and convert failure.
temporalio.api.common.v1.Payloads | None, type_hints: list[ type] | None = None) -> list[ Any]:
(source)
¶
decode for the
temporalio.api.common.v1.Payloads wrapper.
Encode values into payloads.
First converts values to payloads then encodes payloads using codec.
| Parameters | |
values:Sequence[ | Values to be converted and encoded. |
| Returns | |
list[ | Converted and encoded payloads. Note, this does not have to be the same number as values given, but must be at least one and cannot be more than was given. |
BaseException, failure: temporalio.api.failure.v1.Failure):
(source)
¶
Convert and encode failure.
Sequence[ Any]) -> temporalio.api.common.v1.Payloads:
(source)
¶
encode for the
temporalio.api.common.v1.Payloads wrapper.
Options for external storage. If None, external storage is disabled.
Warning
This API is experimental.
Sequence[ temporalio.api.common.v1.Payload], error_limit: int | None, error_message: str, warning_limit: int, warning_message: str):
(source)
¶
Undocumented
temporalio.api.common.v1.Memo) -> Mapping[ str, Any]:
(source)
¶
Undocumented
temporalio.api.common.v1.Memo, key: str, default: Any, type_hint: type | None) -> dict[ str, Any]:
(source)
¶
Undocumented
Sequence[ temporalio.api.common.v1.Payload]) -> list[ temporalio.api.common.v1.Payload]:
(source)
¶
temporalio.worker._workflow._CommandAwareDataConverterCodec decode only.
Mapping[ str, Any]) -> temporalio.api.common.v1.Memo:
(source)
¶
Undocumented
Mapping[ str, Any], memo: temporalio.api.common.v1.Memo):
(source)
¶
Undocumented
Sequence[ temporalio.api.common.v1.Payload]) -> list[ temporalio.api.common.v1.Payload]:
(source)
¶
temporalio.worker._workflow._CommandAwareDataConverterCodec encode only.
Sequence[ temporalio.api.common.v1.Payload]) -> list[ temporalio.api.common.v1.Payload]:
(source)
¶
temporalio.worker._workflow._CommandAwareDataConverterExternal storage retrieve only.
Sequence[ temporalio.api.common.v1.Payload]) -> list[ temporalio.api.common.v1.Payload]:
(source)
¶
temporalio.worker._workflow._CommandAwareDataConverterExternal storage store, then validate payload limits.
temporalio.api.common.v1.Payload) -> temporalio.api.common.v1.Payload:
(source)
¶
Undocumented
temporalio.api.common.v1.Payloads):
(source)
¶
Undocumented
temporalio.api.common.v1.Payload) -> temporalio.api.common.v1.Payload:
(source)
¶
Undocumented
temporalio.api.common.v1.Payloads):
(source)
¶
Undocumented
Sequence[ temporalio.api.common.v1.Payload]):
(source)
¶
temporalio.worker._workflow._CommandAwareDataConverterUndocumented
_ServerPayloadErrorLimits | None) -> DataConverter:
(source)
¶
Undocumented