Documentation ¶
Index ¶
- type Configuration
- type Connector
- type EventConfiguration
- type EventType
- type Factory
- type Planner
- func (p *Planner[T]) ConfigureFetch() resolve.FetchConfiguration
- func (p *Planner[T]) ConfigureSubscription() plan.SubscriptionConfiguration
- func (p *Planner[T]) DataSourcePlanningBehavior() plan.DataSourcePlanningBehavior
- func (p *Planner[T]) DownstreamResponseFieldAlias(downstreamFieldRef int) (alias string, exists bool)
- func (p *Planner[T]) EnterDocument(operation, definition *ast.Document)
- func (p *Planner[T]) EnterField(ref int)
- func (p *Planner[T]) Register(visitor *plan.Visitor, configuration plan.DataSourceConfiguration[T], ...) error
- func (p *Planner[T]) UpstreamSchema(dataSourceConfig plan.DataSourceConfiguration[T]) (*ast.Document, bool)
- type PubSub
- type PublishDataSource
- type RequestDataSource
- type SubscriptionSource
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Configuration ¶
type Configuration struct {
Events []EventConfiguration `json:"events"`
}
type EventConfiguration ¶
type Factory ¶
type Factory[T Configuration] struct { PubSubBySourceName map[string]PubSub // contains filtered or unexported fields }
func NewFactory ¶
func (*Factory[T]) Planner ¶
func (f *Factory[T]) Planner(logger abstractlogger.Logger) plan.DataSourcePlanner[T]
type Planner ¶
type Planner[T Configuration] struct { // contains filtered or unexported fields }
func (*Planner[T]) ConfigureFetch ¶
func (p *Planner[T]) ConfigureFetch() resolve.FetchConfiguration
func (*Planner[T]) ConfigureSubscription ¶
func (p *Planner[T]) ConfigureSubscription() plan.SubscriptionConfiguration
func (*Planner[T]) DataSourcePlanningBehavior ¶
func (p *Planner[T]) DataSourcePlanningBehavior() plan.DataSourcePlanningBehavior
func (*Planner[T]) DownstreamResponseFieldAlias ¶
func (*Planner[T]) EnterDocument ¶
func (*Planner[T]) EnterField ¶
func (*Planner[T]) Register ¶
func (p *Planner[T]) Register(visitor *plan.Visitor, configuration plan.DataSourceConfiguration[T], dataSourcePlannerConfiguration plan.DataSourcePlannerConfiguration) error
func (*Planner[T]) UpstreamSchema ¶
type PubSub ¶
type PubSub interface { // ID is the unique identifier of the pubsub implementation (e.g. NATS) // This is used to uniquely identify a subscription ID() string // Subscribe starts listening on the given topic and sends the received messages to the given next channel Subscribe(ctx context.Context, topic string, updater resolve.SubscriptionUpdater) error // Publish sends the given data to the given topic Publish(ctx context.Context, topic string, data []byte) error // Request sends a request on the given topic and writes the response to the given writer Request(ctx context.Context, topic string, data []byte, w io.Writer) error }
PubSub describe the interface that implements the primitive operations for pubsub
type PublishDataSource ¶
type PublishDataSource struct {
// contains filtered or unexported fields
}
type RequestDataSource ¶
type RequestDataSource struct {
// contains filtered or unexported fields
}
type SubscriptionSource ¶
type SubscriptionSource struct {
// contains filtered or unexported fields
}
func (*SubscriptionSource) Start ¶
func (s *SubscriptionSource) Start(ctx *resolve.Context, input []byte, updater resolve.SubscriptionUpdater) error
func (*SubscriptionSource) UniqueRequestID ¶
func (s *SubscriptionSource) UniqueRequestID(ctx *resolve.Context, input []byte, xxh *xxhash.Digest) error
Click to show internal directories.
Click to hide internal directories.