Updates to track upstream feedkit v0.8.2
All checks were successful
ci/woodpecker/push/build-image Pipeline was successful
All checks were successful
ci/woodpecker/push/build-image Pipeline was successful
This commit is contained in:
@@ -90,7 +90,7 @@ sinks:
|
||||
driver: nats
|
||||
params:
|
||||
url: nats://nats:4222
|
||||
exchange: weatherfeeder
|
||||
subject: weatherfeeder
|
||||
|
||||
# - name: pg_weatherfeeder
|
||||
# driver: postgres
|
||||
|
||||
@@ -37,9 +37,6 @@ func main() {
|
||||
if err != nil {
|
||||
log.Fatalf("config load failed: %v", err)
|
||||
}
|
||||
if err := fksinks.RegisterPostgresSchemaForConfiguredSinks(cfg, wfpgsink.PostgresSchema()); err != nil {
|
||||
log.Fatalf("postgres schema registration failed: %v", err)
|
||||
}
|
||||
|
||||
// --- Registries ---
|
||||
srcReg := fksources.NewRegistry()
|
||||
@@ -48,6 +45,7 @@ func main() {
|
||||
// Compile stdout, Postgres, and NATS sinks for weatherfeeder. The former is useful for debugging and the latter are the main intended outputs.
|
||||
sinkReg := fksinks.NewRegistry()
|
||||
fksinks.RegisterBuiltins(sinkReg)
|
||||
sinkReg.Register("postgres", fksinks.PostgresFactory(wfpgsink.PostgresSchema()))
|
||||
|
||||
// --- Build sources into scheduler jobs ---
|
||||
var jobs []fkscheduler.Job
|
||||
|
||||
@@ -24,13 +24,6 @@ type testInput struct {
|
||||
|
||||
func (s testInput) Name() string { return s.name }
|
||||
|
||||
type testKindSource struct {
|
||||
testInput
|
||||
kind fkevent.Kind
|
||||
}
|
||||
|
||||
func (s testKindSource) Kind() fkevent.Kind { return s.kind }
|
||||
|
||||
type testKindsSource struct {
|
||||
testInput
|
||||
kinds []fkevent.Kind
|
||||
@@ -38,18 +31,6 @@ type testKindsSource struct {
|
||||
|
||||
func (s testKindsSource) Kinds() []fkevent.Kind { return s.kinds }
|
||||
|
||||
func TestValidateSourceExpectedKindsLegacyKindFallback(t *testing.T) {
|
||||
sc := config.SourceConfig{Kind: "observation"}
|
||||
in := testKindSource{
|
||||
testInput: testInput{name: "test"},
|
||||
kind: fkevent.Kind("observation"),
|
||||
}
|
||||
|
||||
if err := fksources.ValidateExpectedKinds(sc, in); err != nil {
|
||||
t.Fatalf("ValidateExpectedKinds() unexpected error: %v", err)
|
||||
}
|
||||
}
|
||||
|
||||
func TestValidateSourceExpectedKindsSubsetAllowed(t *testing.T) {
|
||||
sc := config.SourceConfig{Kinds: []string{"observation"}}
|
||||
in := testKindsSource{
|
||||
|
||||
Reference in New Issue
Block a user