in src/main/java/org/apache/sling/event/impl/jobs/JobConsumerManager.java [409:439]
private void calculateTopics(final boolean enabled) {
if ( enabled ) {
// create a sorted list - this ensures that the property value
// is always the same for the same topics.
final List<String> topicList = new ArrayList<>();
for(final String topic : this.topicToConsumerMap.keySet() ) {
// check allow list
if ( this.match(topic, this.allowListMatchers) ) {
// and deny list
if ( this.denyListMatchers == null || !this.match(topic, this.denyListMatchers) ) {
topicList.add(topic);
}
}
}
Collections.sort(topicList);
final StringBuilder sb = new StringBuilder();
boolean first = true;
for(final String topic : topicList ) {
if ( first ) {
first = false;
} else {
sb.append(',');
}
sb.append(topic);
}
this.topics = sb.toString();
} else {
this.topics = null;
}
}