exceptionfactory commented on code in PR #9812: URL: https://github.com/apache/nifi/pull/9812#discussion_r2003516025
########## nifi-extension-bundles/nifi-aws-bundle/nifi-aws-processors/src/main/java/org/apache/nifi/processors/aws/kinesis/stream/pause/PauseImpl.java: ########## @@ -0,0 +1,88 @@ +/* + * 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.processors.aws.kinesis.stream.pause; + +import org.apache.nifi.processor.ProcessContext; +import org.jetbrains.annotations.VisibleForTesting; + +import java.util.concurrent.CountDownLatch; + +import static org.apache.nifi.processors.aws.v2.AbstractAwsProcessor.REL_SUCCESS; + +public class PauseImpl implements PauseConsumer { Review Comment: The naming convention of `Impl` should be avoided. In general, implementation classes use a prefixed word, such as `Standard` or something more specific. ########## nifi-extension-bundles/nifi-aws-bundle/nifi-aws-processors/src/main/java/org/apache/nifi/processors/aws/kinesis/stream/record/KinesisRecordProcessorRaw.java: ########## @@ -33,9 +34,9 @@ public class KinesisRecordProcessorRaw extends AbstractKinesisRecordProcessor { public KinesisRecordProcessorRaw(final ProcessSessionFactory sessionFactory, final ComponentLog log, final String streamName, final String endpointPrefix, final String kinesisEndpoint, final long checkpointIntervalMillis, final long retryWaitMillis, - final int numRetries, final DateTimeFormatter dateTimeFormatter) { + final int numRetries, final DateTimeFormatter dateTimeFormatter, PauseImpl consumeHalter) { Review Comment: This naming of `consumeHalter` is not very clear, nor does it align with the interface name. It also references the implementation versus the interface, so that should be changed. ########## nifi-extension-bundles/nifi-aws-bundle/nifi-aws-processors/src/main/java/org/apache/nifi/processors/aws/kinesis/stream/pause/PauseConsumer.java: ########## @@ -0,0 +1,21 @@ +/* + * 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.processors.aws.kinesis.stream.pause; + +public interface PauseConsumer { Review Comment: I don't think this name is sufficiently clear to communicate the intent of the interface and associated implementations. ########## nifi-extension-bundles/nifi-aws-bundle/nifi-aws-processors/src/main/java/org/apache/nifi/processors/aws/kinesis/stream/pause/PauseImpl.java: ########## @@ -0,0 +1,88 @@ +/* + * 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.processors.aws.kinesis.stream.pause; + +import org.apache.nifi.processor.ProcessContext; +import org.jetbrains.annotations.VisibleForTesting; Review Comment: Although helpful for information, this places an unintentional dependency on the JetBrains annotation and should be removed. -- 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]
