Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func SourceEvents ¶
func SourceEvents(source EventSource) interface{}
SourceEvents is the entry point for intializing client and generating events
Types ¶
type EventSource ¶
type EventSource interface { SetCtx() ConstructCloudEventsClient() GenerateEvents() interface{} }
EventSource is a Interface for knative sink binding sources
type ObjectStoreConfig ¶
type ObjectStoreConfig struct { Bucket string `envconfig:"S3_BUCKET"` Key string `envconfig:"S3_FILE_NAME"` Region string `envconfig:"S3_REGION"` Access string `envconfig:"S3_ACCESS_KEY"` Secret string `envconfig:"S3_SECRET_KEY"` Endpoint string `envconfig:"S3_URL"` ChunkSize string `envconfig:"DOWNLOAD_CHUNK_SIZE" default:"500000000"` }
ObjectStoreConfig houses object store connection state
type S3Source ¶
type S3Source struct { Sink SinkConfig Connection ObjectStoreConfig // contains filtered or unexported fields }
S3Source houses all the state related to the event
func (*S3Source) ConstructCloudEventsClient ¶
func (source *S3Source) ConstructCloudEventsClient()
ConstructCloudEventsClient establishes HTTP client
func (*S3Source) GenerateEvents ¶
func (source *S3Source) GenerateEvents() interface{}
GenerateEvents does the heavy lifting in the whole process
type S3SourceData ¶
type S3SourceData struct {
Data string
}
S3SourceData specifies the shape of the data transmitted
type SinkConfig ¶
type SinkConfig struct { URL string `envconfig:"K_SINK"` CEOverrides string `envconfig:"K_CE_OVERRIDES"` DumpCount string `envconfig:"SINK_DUMP_COUNT" default:"100"` Retries string `envconfig:"SINK_RETRY_COUNT" default:"3"` RetryInterval string `envconfig:"SINK_RETRY_INTERVAL" default:"1"` }
SinkConfig houses the state of binding
Click to show internal directories.
Click to hide internal directories.