Package org.apache.nifi.cluster.manager
Class ProcessorEntityMerger
java.lang.Object
org.apache.nifi.cluster.manager.ProcessorEntityMerger
- All Implemented Interfaces:
ComponentEntityMerger<ProcessorEntity>
,ComponentEntityStatusMerger<ProcessorStatusDTO>
public class ProcessorEntityMerger
extends Object
implements ComponentEntityMerger<ProcessorEntity>, ComponentEntityStatusMerger<ProcessorStatusDTO>
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoid
merge
(ProcessorEntity clientEntity, Map<NodeIdentifier, ProcessorEntity> entityMap) Merges the ComponentEntity responses according to theirPermissionsDTO
s.void
mergeComponents
(ProcessorEntity clientEntity, Map<NodeIdentifier, ProcessorEntity> entityMap) Merges the ProcessorEntity responses.private static void
mergeDtos
(ProcessorDTO clientDto, Map<NodeIdentifier, ProcessorDTO> dtoMap) void
mergeStatus
(ProcessorStatusDTO clientStatus, boolean clientStatusReadablePermission, ProcessorStatusDTO status, boolean statusReadablePermission, NodeIdentifier statusNodeIdentifier) Merges status into clientStatus based on the given permissions.
-
Constructor Details
-
ProcessorEntityMerger
public ProcessorEntityMerger()
-
-
Method Details
-
merge
Description copied from interface:ComponentEntityMerger
Merges the ComponentEntity responses according to theirPermissionsDTO
s. Responsible for invokinginvalid reference
ComponentEntityMerger#mergeComponents(EntityType, Map)
- Specified by:
merge
in interfaceComponentEntityMerger<ProcessorEntity>
- Parameters:
clientEntity
- the entity being returned to the cliententityMap
- all node responses
-
mergeComponents
public void mergeComponents(ProcessorEntity clientEntity, Map<NodeIdentifier, ProcessorEntity> entityMap) Merges the ProcessorEntity responses.- Specified by:
mergeComponents
in interfaceComponentEntityMerger<ProcessorEntity>
- Parameters:
clientEntity
- the entity being returned to the cliententityMap
- all node responses
-
mergeStatus
public void mergeStatus(ProcessorStatusDTO clientStatus, boolean clientStatusReadablePermission, ProcessorStatusDTO status, boolean statusReadablePermission, NodeIdentifier statusNodeIdentifier) Description copied from interface:ComponentEntityStatusMerger
Merges status into clientStatus based on the given permissions.- Specified by:
mergeStatus
in interfaceComponentEntityStatusMerger<ProcessorStatusDTO>
- Parameters:
clientStatus
- The status that will be returned to the client after mergingclientStatusReadablePermission
- The read permission of the status that will be returned to the client after mergingstatus
- The status to be merged into the client statusstatusReadablePermission
- The read permission of the status to be merged into the client statusstatusNodeIdentifier
- TheNodeIdentifier
of the node from which status was received
-
mergeDtos
-