exceptionfactory commented on code in PR #115:
URL: https://github.com/apache/nifi-api/pull/115#discussion_r4568520179


##########
src/main/java/org/apache/nifi/annotation/lifecycle/OnDrainInitiated.java:
##########
@@ -0,0 +1,58 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements.  See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.nifi.annotation.lifecycle;
+
+import org.apache.nifi.controller.ConfigurationContext;
+import org.apache.nifi.processor.ProcessContext;
+
+import java.lang.annotation.Documented;
+import java.lang.annotation.ElementType;
+import java.lang.annotation.Inherited;
+import java.lang.annotation.Retention;
+import java.lang.annotation.RetentionPolicy;
+import java.lang.annotation.Target;
+
+/**
+ * <p>
+ * Marker annotation a {@link org.apache.nifi.processor.Processor Processor} or
+ * {@link org.apache.nifi.controller.ControllerService ControllerService} 
implementation
+ * can use to indicate that a method should be called when a drain of its 
Process Group begins.
+ * While a drain is in progress, no new data is brought into the group, so the 
component should
+ * process the data that it already has rather than wait for more. For 
example, a Processor that
+ * groups FlowFiles into bins might send its bins on sooner.
+ * </p>
+ *
+ * <p>
+ * The component may be in any lifecycle state when this method is called, and 
the method may be

Review Comment:
   Good point, I should have read that statement more closely. I agree that is 
sufficient to leave it open



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to