OpenFunction / functions-framework-go

Go functions framework for OpenFunction
18 stars 20 forks source link

[bug] custom plugins registration failed #47

Closed wentevill closed 2 years ago

wentevill commented 2 years ago

In what area(s)?

/area custom plugins

Expected Behavior

Register a custom plugin, the plugin can be executed successfully when used.

Actual Behavior

Custom plugins are ignored.

https://github.com/OpenFunction/functions-framework-go/blob/main/framework/framework.go#L101-L110 Custom plugins are injected into pluginMap, only TracingProviderSkywalking, TracingProviderOpentelemetry will be injected into PrePlugins and PostPlugins. https://github.com/OpenFunction/functions-framework-go/blob/main/context/context.go#L770-L789

resulting in custom plugins cannot be successfully obtained in the context. https://github.com/OpenFunction/functions-framework-go/blob/main/framework/framework.go#L112-126

tpiperatgod commented 2 years ago

Can you paste the configuration of the Function? also you may refer to this sample: https://github.com/OpenFunction/samples/blob/main/functions/async/bindings/cron-input-kafka-output/cron-input-kafka-output.yaml