You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Description
I am creating a vanilla web based spring-cloud-function (3.0.9.RELEASE) application containing multiple functions. I used Spring's built-in router function. Below is my configuration
Now when I run the application and invoke the url for the first time, it is working as expected. But for second invocation (and consecutive) it is throwing exception like, java.lang.IllegalArgumentException: Routing input of type Publisher is not supported per individual values (e.g., message header or POJO). Instead you should use 'spring.cloud.function.definition' or spring.cloud.function.routing-expression' as application properties
After debugging I also found that, for second invocation, it is not able to lookup actual function object from registry (but, for first invocation, as it is creating the function object and populating the registry for first time, it can found), hence the consecutive problem comes.
I am able to replicate this in my testcase as well, but being a new comer in spring-cloud, I am not sure if this is a framework issue or some problem in my code.
I have also posted a question regarding this in stackoverflow
Description
I am creating a vanilla web based spring-cloud-function (3.0.9.RELEASE) application containing multiple functions. I used Spring's built-in router function. Below is my configuration
spring.cloud.function.scan.packages=abhishek.scattered.springcloudfunction
spring.cloud.stream.function.routing.enabled=true
Now when I run the application and invoke the url for the first time, it is working as expected. But for second invocation (and consecutive) it is throwing exception like,
java.lang.IllegalArgumentException: Routing input of type Publisher is not supported per individual values (e.g., message header or POJO). Instead you should use 'spring.cloud.function.definition' or spring.cloud.function.routing-expression' as application properties
After debugging I also found that, for second invocation, it is not able to lookup actual function object from registry (but, for first invocation, as it is creating the function object and populating the registry for first time, it can found), hence the consecutive problem comes.
I am able to replicate this in my testcase as well, but being a new comer in spring-cloud, I am not sure if this is a framework issue or some problem in my code.
I have also posted a question regarding this in stackoverflow
Sample
Please refer to sample project in github,
scattered-spring-cloud-function-router
The text was updated successfully, but these errors were encountered: