eventstream

package
v1.28.10 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Nov 24, 2026 License: Apache-2.0 Imports: 5 Imported by: 0 modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Codec

type Codec struct {
	Serializer   func() smithy.ShapeSerializer
	Deserializer func([]byte) smithy.ShapeDeserializer
	ContentType  string

	// Protocol-specific hook to retrieve error information from some payload.
	ErrorInfo func(payload []byte) (code, message string, err error)
	// contains filtered or unexported fields
}

Codec orchestrates event stream message serde for protocols that use the standard event stream binary framing.

func (*Codec) DeserializeEventMessage

func (c *Codec) DeserializeEventMessage(schema *smithy.Schema, types *smithy.TypeRegistry, r io.Reader) (smithy.Deserializable, error)

DeserializeEventMessage reads an event from the output stream.

func (*Codec) DeserializeInitialResponse

func (c *Codec) DeserializeInitialResponse(schema *smithy.Schema, r io.Reader, out smithy.Deserializable) error

DeserializeInitialResponse reads the first event stream message and deserializes it as the operation output.

func (*Codec) RequireBidiHTTP2

func (c *Codec) RequireBidiHTTP2(proto string, protoMajor int) error

RequireBidiHTTP2 returns an error if the response protocol is not at least HTTP/2, which is required for bidirectional event streams.

func (*Codec) SerializeEventMessage

func (c *Codec) SerializeEventMessage(schema, variant *smithy.Schema, v smithy.Serializable, w io.Writer) error

SerializeEventMessage serializes an event to the input stream.

func (*Codec) SerializeInitialRequest

func (c *Codec) SerializeInitialRequest(schema *smithy.Schema, v smithy.Serializable, w io.Writer) error

SerializeInitialRequest serializes the operation input as the first event stream message with :event-type "initial-request".

type NoEventStream

type NoEventStream struct{}

NoEventStream implements the event stream methods of github.com/aws/smithy-go/transport/http.ClientProtocol for protocols that do not support event streams.

func (NoEventStream) DeserializeEventMessage

func (NoEventStream) DeserializeEventMessage(_ *smithy.Schema, _ *smithy.TypeRegistry, _ io.Reader) (smithy.Deserializable, error)

DeserializeEventMessage returns an error.

func (NoEventStream) DeserializeInitialResponse

func (NoEventStream) DeserializeInitialResponse(_ *smithy.Schema, _ io.Reader, _ smithy.Deserializable) error

DeserializeInitialResponse returns an error.

func (NoEventStream) HasInitialEventMessage

func (NoEventStream) HasInitialEventMessage() bool

HasInitialEventMessage returns false.

func (NoEventStream) SerializeEventMessage

func (NoEventStream) SerializeEventMessage(_, _ *smithy.Schema, _ smithy.Serializable, _ io.Writer) error

SerializeEventMessage returns an error.

func (NoEventStream) SerializeInitialRequest

func (NoEventStream) SerializeInitialRequest(_ *smithy.Schema, _ smithy.Serializable, _ io.Writer) error

SerializeInitialRequest returns an error.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL