NIFI-5034:

- Ensuring descriptors and properties of referencing components are populated like Processors, Reporting Tasks, etc.
This commit is contained in:
Matt Gilman 2018-04-02 16:47:28 -04:00 committed by Mark Payne
parent 2279fad673
commit 924c935a38
1 changed files with 2 additions and 2 deletions

View File

@ -1502,6 +1502,8 @@ public final class DtoFactory {
processGroupId = null;
}
dto.setDescriptors(new LinkedHashMap<String, PropertyDescriptorDTO>());
dto.setProperties(new LinkedHashMap<String, String>());
if (propertyDescriptors != null && !propertyDescriptors.isEmpty()) {
final Map<PropertyDescriptor, String> sortedProperties = new TreeMap<>(new Comparator<PropertyDescriptor>() {
@Override
@ -1518,8 +1520,6 @@ public final class DtoFactory {
orderedProperties.putAll(sortedProperties);
// build the descriptor and property dtos
dto.setDescriptors(new LinkedHashMap<String, PropertyDescriptorDTO>());
dto.setProperties(new LinkedHashMap<String, String>());
for (final Map.Entry<PropertyDescriptor, String> entry : orderedProperties.entrySet()) {
final PropertyDescriptor descriptor = entry.getKey();