Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func NewJSONCodec ¶
func NewJSONCodec(schemes ...*scheme.Scheme) converter.PayloadCodec
NewJSONCodec initializes a new Codec value from one or more Scheme values
func NewProtoJSONCodec ¶
func NewProtoJSONCodec(schemes ...*scheme.Scheme) converter.PayloadCodec
NewProtoJSONCodec initializes a new Codec value from one or more Scheme values
Types ¶
type JSONCodec ¶
type JSONCodec struct {
// contains filtered or unexported fields
}
JSONCodec implements a converter.PayloadCodec that provides conversion between binary/protobuf and json/plain encodings. It can be used in conjunction with converter.NewPayloadCodecHTTPHandler to implement a Remote Codec Server.
type ProtoJSONCodec ¶
type ProtoJSONCodec struct {
// contains filtered or unexported fields
}
ProtoJSONCodec implements a converter.PayloadCodec that provides conversion between binary/protobuf and json/protobuf encodings. It can be used in conjunction with converter.NewPayloadCodecHTTPHandler to implement a Remote Codec Server.
func (*ProtoJSONCodec) Decode ¶
func (c *ProtoJSONCodec) Decode(payloads []*common.Payload) ([]*common.Payload, error)
Decode converts all binary/protobuf encoded payloads with registered message types to json/protobuf encoding to support Temporal UI automatic decoding. Any payloads with other encoding, or unregistered types are left unmodified.
func (*ProtoJSONCodec) Encode ¶
func (c *ProtoJSONCodec) Encode(payloads []*common.Payload) ([]*common.Payload, error)
Encode converts all json/protobuf encoded payloads with registered message types to binary/protobuf encoding prior to being forwarded to Temporal.