Channel

Configuration Properties

Properties for the Channel are provided inside the configuration of a Topic.

Key Required Type Default Description
target Y String Name of the Target.
custom-fields Set<String> Set of names of the Custom Fields.
accumulate boolean false If enabled, the messages will accumulate all of their tuples (from all the message chunks) and only publish them to the transaction manager when the message is sent.

YAML Example

dlc:
  csv:
    topics:
      topic1:
        channels:
          - target: target1
            custom-fields:
              - calculator1
              - calculator2
              - calculator3
              - calculator4
              - calculator5

Java Configuration

ChannelDescription Java object can be used for configuration in Java. The Object is used in the configuration of a Topic.

You can use NamedEntityResolverService to get Target or Column Calculator by name.

Parameter Required Type Default Description
targetDescription Y ITargetDescription The Target associated with this channel.
customFields Set<ICustomFieldDescription> Set of Custom Fields which belong to the channel.
accumulate boolean false If enabled, the messages will accumulate all of their tuples (from all the message chunks) and only publish them to the transaction manager when the message is sent.

Java Example

@Bean
public CsvTopicDescription topic1(NamedEntityResolverService namedEntityResolver) {
    return CsvTopicDescription.builder("topic1", "glob:file*.csv")
            .channel(ChannelDescription.builder(namedEntityResolver.getDlcTargetDescription("target1"))
                    .customFields(
                            Set.of(
                                    new CustomFieldDescription(
                                            "Calculator1",
                                            scope -> new ConstantCalculator<>("field1", 1)
                                    ),
                                    new AnonymousCustomFieldDescription(
                                            scope -> new ConstantCalculator<>("field1", scope.get("constant"))
                                    )
                            )
                    )
                    .build())
            .build();
}