This is an automated email from the ASF dual-hosted git repository.
markap14 pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/nifi.git
The following commit(s) were added to refs/heads/master by this push:
new a97766d NIFI-6302: - Ensuring Process Group contents are pruned when
appropriate.
a97766d is described below
commit a97766d62f067845869c44b39604851c7ca91d02
Author: Matt Gilman <[email protected]>
AuthorDate: Thu May 16 10:02:01 2019 -0400
NIFI-6302:
- Ensuring Process Group contents are pruned when appropriate.
This closes #3477.
Signed-off-by: Mark Payne <[email protected]>
---
.../java/org/apache/nifi/web/api/ProcessGroupResource.java | 10 ++++++++++
1 file changed, 10 insertions(+)
diff --git
a/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-api/src/main/java/org/apache/nifi/web/api/ProcessGroupResource.java
b/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-api/src/main/java/org/apache/nifi/web/api/ProcessGroupResource.java
index 4aa5961..f76f674 100644
---
a/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-api/src/main/java/org/apache/nifi/web/api/ProcessGroupResource.java
+++
b/nifi-nar-bundles/nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-api/src/main/java/org/apache/nifi/web/api/ProcessGroupResource.java
@@ -475,6 +475,11 @@ public class ProcessGroupResource extends
ApplicationResource {
final ProcessGroupEntity entity =
serviceFacade.updateProcessGroup(revision, processGroupEntity.getComponent());
populateRemainingProcessGroupEntityContent(entity);
+ // prune response as necessary
+ if (entity.getComponent() != null) {
+ entity.getComponent().setContents(null);
+ }
+
return generateOkResponse(entity).build();
}
);
@@ -1597,6 +1602,11 @@ public class ProcessGroupResource extends
ApplicationResource {
// delete the process group
final ProcessGroupEntity entity =
serviceFacade.deleteProcessGroup(revision, processGroupEntity.getId());
+ // prune response as necessary
+ if (entity.getComponent() != null) {
+ entity.getComponent().setContents(null);
+ }
+
// create the response
return generateOkResponse(entity).build();
}