Skip to content
This repository has been archived by the owner on Aug 2, 2022. It is now read-only.

Adding custom Suppress FindBugs class to make it JDK8 compatible #502

Merged
merged 3 commits into from
Nov 2, 2020
Merged
Show file tree
Hide file tree
Changes from 2 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@

import com.amazon.opendistro.elasticsearch.performanceanalyzer.AppContext;
import com.amazon.opendistro.elasticsearch.performanceanalyzer.rca.store.rca.cluster.NodeKey;
import com.amazon.opendistro.elasticsearch.performanceanalyzer.util.SuppressFBWarnings;
import com.google.gson.Gson;
import com.google.gson.GsonBuilder;
import com.google.gson.annotations.SerializedName;
Expand All @@ -27,7 +28,6 @@
import java.util.Map;
import java.util.concurrent.TimeUnit;
import java.util.stream.Collectors;
import org.graalvm.compiler.options.SuppressFBWarnings;

public class CacheClearAction extends SuppressibleAction {
public static final String NAME = "CacheClear";
Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,19 @@
package com.amazon.opendistro.elasticsearch.performanceanalyzer.util;

import java.lang.annotation.Retention;
import java.lang.annotation.RetentionPolicy;

@Retention(RetentionPolicy.CLASS)
public @interface SuppressFBWarnings {
/**
* The set of FindBugs warnings that are to be suppressed in
* annotated element. The value can be a bug category, kind or pattern.
*
*/
String[] value() default {};

/**
* Optional documentation of the reason why the warning is suppressed
*/
String justification() default "";
}