You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
NIFI-15511: Added endpoints for purging all FlowFiles for a given Connector; added method to ConnectorClient to call these endpoints; updated system tests to use these endpoints when tearing down flows; some bug fixes
Copy file name to clipboardExpand all lines: nifi-framework-bundle/nifi-framework/nifi-framework-components/src/main/java/org/apache/nifi/groups/StandardProcessGroup.java
+12Lines changed: 12 additions & 0 deletions
Original file line number
Diff line number
Diff line change
@@ -1591,17 +1591,29 @@ private DropFlowFileStatus handleDropAllFlowFiles(String dropRequestId, Function
Copy file name to clipboardExpand all lines: nifi-framework-bundle/nifi-framework/nifi-framework-core-api/src/main/java/org/apache/nifi/components/connector/ConnectorNode.java
+6Lines changed: 6 additions & 0 deletions
Original file line number
Diff line number
Diff line change
@@ -211,6 +211,12 @@ public interface ConnectorNode extends ComponentAuthorizable, VersionedComponent
Copy file name to clipboardExpand all lines: nifi-framework-bundle/nifi-framework/nifi-framework-core/src/main/java/org/apache/nifi/components/connector/StandardConnectorNode.java
+14-1Lines changed: 14 additions & 1 deletion
Original file line number
Diff line number
Diff line change
@@ -494,6 +494,19 @@ public void verifyCancelDrainFlowFiles() throws IllegalStateException {
thrownewIllegalStateException("Cannot purge FlowFiles for " + this + " because its desired state is currently " + desiredState + "; it must be STOPPED.");
thrownewIllegalStateException("Cannot " + action + " for " + this + " because its current state is currently " + currentState + "; it must be STOPPED.");
536
+
thrownewIllegalStateException("Cannot " + action + " for " + this + " because its current state is " + currentState + "; it must be STOPPED.");
Copy file name to clipboardExpand all lines: nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-api/src/main/java/org/apache/nifi/web/NiFiServiceFacade.java
Copy file name to clipboardExpand all lines: nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-api/src/main/java/org/apache/nifi/web/StandardNiFiServiceFacade.java
+10Lines changed: 10 additions & 0 deletions
Original file line number
Diff line number
Diff line change
@@ -3859,6 +3859,16 @@ public Optional<Asset> getConnectorAsset(final String assetId) {
Copy file name to clipboardExpand all lines: nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-api/src/main/java/org/apache/nifi/web/api/ConnectorResource.java
@ApiResponse(responseCode = "400", description = "NiFi was unable to complete the request because it was invalid. The request should not be retried without modification."),
813
+
@ApiResponse(responseCode = "401", description = "Client could not be authenticated."),
814
+
@ApiResponse(responseCode = "403", description = "Client is not authorized to make this request."),
815
+
@ApiResponse(responseCode = "404", description = "The specified resource could not be found."),
816
+
@ApiResponse(responseCode = "409", description = "The request was valid but NiFi was not in the appropriate state to process it.")
817
+
},
818
+
description = "This will create a request to purge all FlowFiles from the connector. The connector must be in a STOPPED state before purging can begin. "
819
+
+ "This is an asynchronous operation. The client should poll the returned URI to get the status of the purge request.",
@ApiResponse(responseCode = "400", description = "NiFi was unable to complete the request because it was invalid. The request should not be retried without modification."),
860
+
@ApiResponse(responseCode = "401", description = "Client could not be authenticated."),
861
+
@ApiResponse(responseCode = "403", description = "Client is not authorized to make this request."),
862
+
@ApiResponse(responseCode = "404", description = "The specified resource could not be found."),
863
+
@ApiResponse(responseCode = "409", description = "The request was valid but NiFi was not in the appropriate state to process it.")
864
+
},
865
+
security = {
866
+
@SecurityRequirement(name = "Only the user that submitted the request can get it")
@ApiResponse(responseCode = "400", description = "NiFi was unable to complete the request because it was invalid. The request should not be retried without modification."),
902
+
@ApiResponse(responseCode = "401", description = "Client could not be authenticated."),
903
+
@ApiResponse(responseCode = "403", description = "Client is not authorized to make this request."),
904
+
@ApiResponse(responseCode = "404", description = "The specified resource could not be found."),
905
+
@ApiResponse(responseCode = "409", description = "The request was valid but NiFi was not in the appropriate state to process it.")
906
+
},
907
+
security = {
908
+
@SecurityRequirement(name = "Only the user that submitted the request can remove it")
Copy file name to clipboardExpand all lines: nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-api/src/main/java/org/apache/nifi/web/dao/ConnectorDAO.java
+4Lines changed: 4 additions & 0 deletions
Original file line number
Diff line number
Diff line change
@@ -54,6 +54,10 @@ public interface ConnectorDAO {
Copy file name to clipboardExpand all lines: nifi-framework-bundle/nifi-framework/nifi-web/nifi-web-api/src/main/java/org/apache/nifi/web/dao/impl/StandardConnectorDAO.java
+20Lines changed: 20 additions & 0 deletions
Original file line number
Diff line number
Diff line change
@@ -53,6 +53,7 @@
53
53
importjava.util.Map;
54
54
importjava.util.Optional;
55
55
importjava.util.Set;
56
+
importjava.util.concurrent.ExecutionException;
56
57
importjava.util.stream.Collectors;
57
58
58
59
@Repository
@@ -150,6 +151,25 @@ public void verifyCancelDrainFlowFile(final String id) {
0 commit comments