NIFI-8624 Updated Maven archetypes to conform to SonarQube standards

This closes #5092

Signed-off-by: David Handermann <exceptionfactory@apache.org>
This commit is contained in:
Lockie Richter 2021-05-21 15:16:18 +09:30 committed by exceptionfactory
parent 1033e77e7f
commit 70d8fe8e00
No known key found for this signature in database
GPG Key ID: 29B6A52D2AAE8DBA
3 changed files with 7 additions and 7 deletions

View File

@ -66,13 +66,13 @@ public class MyProcessor extends AbstractProcessor {
@Override
protected void init(final ProcessorInitializationContext context) {
final List<PropertyDescriptor> descriptors = new ArrayList<>();
descriptors = new ArrayList<>();
descriptors.add(MY_PROPERTY);
this.descriptors = Collections.unmodifiableList(descriptors);
descriptors = Collections.unmodifiableList(descriptors);
final Set<Relationship> relationships = new HashSet<>();
relationships = new HashSet<>();
relationships.add(MY_RELATIONSHIP);
this.relationships = Collections.unmodifiableSet(relationships);
relationships = Collections.unmodifiableSet(relationships);
}
@Override
@ -91,7 +91,7 @@ public class MyProcessor extends AbstractProcessor {
}
@Override
public void onTrigger(final ProcessContext context, final ProcessSession session) throws ProcessException {
public void onTrigger(final ProcessContext context, final ProcessSession session) {
FlowFile flowFile = session.get();
if ( flowFile == null ) {
return;

View File

@ -25,6 +25,6 @@ import org.apache.nifi.processor.exception.ProcessException;
@CapabilityDescription("Example Service API.")
public interface MyService extends ControllerService {
public void execute() throws ProcessException;
public void execute();
}

View File

@ -73,7 +73,7 @@ public class StandardMyService extends AbstractControllerService implements MySe
}
@Override
public void execute() throws ProcessException {
public void execute() {
}