scdf 1.7.3 docker k8s function-runner not start

风格不统一 提交于 2019-12-13 03:41:32

问题


Trying to deploy into scdf k8s a function-runner into a stream

http --server.port=9001 | f-run: function-runner --function.className=com.example.functions.CharCounter --class-name=com.example.functions.CharCounter --location="maven://io.spring.sample:function-sample:jar:1.0.2" | log

I've create a docker image using function-runner-kafka 1.1.0.M1.

Always get :

***************************
APPLICATION FAILED TO START
***************************
Description:
Binding to target org.springframework.cloud.stream.app.function.app.FunctionProperties@264f218 failed:
    Property: function.className
    Value: null
    Reason: may not be empty
Action:
Update your application's configuration

Into stream definition, how can i set the maven uri to the function-jar?

I wanna run function-runner with jar code into a scdf k8s


回答1:


The function-runner model is deprecated in favor of native Spring Cloud Function integration available in Spring Cloud Stream.

You can simply build a Spring Cloud Stream application with just function @Bean's and have them part of the functional flow as a chain or resolved as an individual function at runtime.

See ref. guide for more details.

Once when you have an application with multiple function @Bean's, you also have the ability to compose them with other App Starters and use it in the SCDF DSL, too.

Refer to this blog on this subject for more background.



来源:https://stackoverflow.com/questions/55455066/scdf-1-7-3-docker-k8s-function-runner-not-start

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!