Refactor feedkit boundaries ahead of v1
Remove global Postgres schema registration in favor of explicit schema-aware sink factory wiring, and update weatherfeeder to register the Postgres sink explicitly. Add optional per-source HTTP timeout and response body limit overrides while keeping feedkit defaults. Remove remaining legacy source/config compatibility surfaces, including singular kind support and old source registry/type aliases, and migrate weatherfeeder sources to plural `Kinds()` metadata. Clean up related docs, tests, and sample config to match the new Postgres, HTTP, and NATS configuration model.
This commit is contained in:
14
sinks/doc.go
14
sinks/doc.go
@@ -4,16 +4,16 @@
|
||||
// External API surface:
|
||||
// - Sink: adapter interface that consumes event.Event values
|
||||
// - Registry / NewRegistry: named sink factory registry
|
||||
// - RegisterBuiltins: registers the built-in sink drivers in this binary
|
||||
// - RegisterBuiltins: registers the schema-free built-in sink drivers
|
||||
//
|
||||
// Built-in drivers:
|
||||
// Built-in sink implementations:
|
||||
// - stdout
|
||||
// - nats
|
||||
// - postgres
|
||||
//
|
||||
// Optional helpers from helpers.go:
|
||||
// - RegisterPostgresSchemaForConfiguredSinks: registers one Postgres schema
|
||||
// for each configured sink using driver=postgres
|
||||
// - PostgresFactory: returns a sink factory for the built-in Postgres sink
|
||||
// using a provided downstream schema
|
||||
//
|
||||
// # NATS built-in overview
|
||||
//
|
||||
@@ -59,7 +59,9 @@
|
||||
//
|
||||
// Example downstream wiring:
|
||||
//
|
||||
// sinks.MustRegisterPostgresSchema("pg_main", sinks.PostgresSchema{
|
||||
// sinkReg := sinks.NewRegistry()
|
||||
// sinks.RegisterBuiltins(sinkReg)
|
||||
// sinkReg.Register("postgres", sinks.PostgresFactory(sinks.PostgresSchema{
|
||||
// Tables: []sinks.PostgresTable{
|
||||
// {
|
||||
// Name: "events",
|
||||
@@ -88,7 +90,7 @@
|
||||
// },
|
||||
// }, nil
|
||||
// },
|
||||
// })
|
||||
// }))
|
||||
//
|
||||
// Manual pruning via type assertion (administrative helpers):
|
||||
//
|
||||
|
||||
Reference in New Issue
Block a user