committed by
Oleg Zhurakousky
parent
45829f7fb5
commit
a8f25efceb
@@ -240,7 +240,7 @@ public class BeanFactoryAwareFunctionRegistry extends SimpleFunctionRegistry imp
|
||||
|
||||
@Override
|
||||
protected boolean containsFunction(String functionName) {
|
||||
return super.containsFunction(functionName) ? true : this.applicationContext.containsBean(functionName);
|
||||
return super.containsFunction(functionName) || this.applicationContext.containsBean(functionName);
|
||||
}
|
||||
|
||||
private boolean isFunctionPojo(Object functionCandidate, String functionName) {
|
||||
|
||||
@@ -41,8 +41,8 @@ public abstract class FunctionAroundWrapper {
|
||||
|
||||
public final Object apply(Object input, FunctionInvocationWrapper targetFunction) {
|
||||
String functionalTracingEnabledStr = System.getProperty("spring.cloud.function.observability.enabled");
|
||||
boolean functionalTracingEnabled = StringUtils.hasText(functionalTracingEnabledStr)
|
||||
? Boolean.parseBoolean(functionalTracingEnabledStr) : true;
|
||||
boolean functionalTracingEnabled = !StringUtils.hasText(functionalTracingEnabledStr)
|
||||
|| Boolean.parseBoolean(functionalTracingEnabledStr);
|
||||
if (functionalTracingEnabled && !(input instanceof Publisher) && input instanceof Message && !FunctionTypeUtils.isCollectionOfMessage(targetFunction.getOutputType())) {
|
||||
return this.doApply(input, targetFunction);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user