david-streamlio commented on a change in pull request #9943:
URL: https://github.com/apache/pulsar/pull/9943#discussion_r597289828
##########
File path:
pulsar-functions/instance/src/main/java/org/apache/pulsar/functions/instance/JavaInstanceRunnable.java
##########
@@ -736,8 +737,14 @@ private void setupOutput(ContextImpl contextImpl) throws
Exception {
pulsarSinkConfig.setProcessingGuarantees(FunctionConfig.ProcessingGuarantees.valueOf(
this.instanceConfig.getFunctionDetails().getProcessingGuarantees().name()));
pulsarSinkConfig.setTopic(sinkSpec.getTopic());
- pulsarSinkConfig.setForwardSourceMessageProperty(
+
+ if
(this.instanceConfig.getFunctionDetails().getComponentType()==
ComponentType.SOURCE) {
+ // Forward record level properties for all sources by default
+ pulsarSinkConfig.setForwardSourceMessageProperty(true);
+ } else if
(this.instanceConfig.getFunctionDetails().getComponentType() ==
ComponentType.SINK) {
Review comment:
@eolivelli I have replaced the code with a different approach. If you
have time can you please review the updated code and mark this issue as
resolved or suggest what other changes are required to address you concerns?
Thanks in advance!
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
[email protected]