forked from NationalSecurityAgency/datawave
-
Notifications
You must be signed in to change notification settings - Fork 0
/
spotbugs-exclude.xml
181 lines (150 loc) · 5.72 KB
/
spotbugs-exclude.xml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
<?xml version="1.0" encoding="UTF-8"?>
<FindBugsFilter>
<!--
This should be opened up for debate, but for now all DM_DEFAULT_ENCODING
occurrences are being excluded due to the large number of hits.
The debate includes, but is not limited to, A) modifying code to use a specific
charset, e.g.,'StandardCharsets.UTF_8', for *every* flagged method/constructor
invocation, or B) overriding the local default encoding via JVM system property
instead, which requires zero code, e.g.,
java -Dfile.encoding="UTF-8" ...
However, there are caveats with overriding in this manner. See the following
for background...
https://bugs.openjdk.java.net/browse/JDK-8187041
https://www.baeldung.com/java-char-encoding
-->
<Match>
<Bug pattern="DM_DEFAULT_ENCODING" />
</Match>
<!--
Auto-generated protobuf classes
-->
<Match>
<Class name="~datawave\.edge\.protobuf\.EdgeData.*" />
</Match>
<Match>
<Class name="~datawave\.ingest\.protobuf\.TermWeight.*" />
</Match>
<Match>
<Class name="~datawave\.ingest\.protobuf\.Uid.*" />
</Match>
<Match>
<Class name="~datawave\.user\.UserMessages.*" />
</Match>
<Match>
<Class name="~datawave\.webservice\.query\.QueryMessages.*" />
</Match>
<Match>
<Class name="~datawave\.webservice\.query\.exception\.ExceptionMessages.*" />
</Match>
<Match>
<Class name="~datawave\.webservice\.query\.metric\.MetricsMessages.*" />
</Match>
<Match>
<Class name="~datawave\.webservice\.result\.ResponseMessages.*" />
</Match>
<Match>
<Class name="~datawave\.webservice\.results\.cached.result\.CachedresultMessages.*" />
</Match>
<Match>
<Class name="~datawave\.ingest\.protobuf\.RawRecordContainer.*" />
</Match>
<!--
The offending MarkingFunctionsFactory instance is a container-managed singleton,
so not really a concern. Having 'postConstruct' (instance method) delegate this
write to a new static method would silence this bug, but that seems unnecessary
-->
<Match>
<Class name="datawave.marking.MarkingFunctionsFactory" />
<Field name="markingFunctions" />
<Bug pattern="ST_WRITE_TO_STATIC_FROM_INSTANCE_METHOD" />
</Match>
<!--
Are we sure that System.gc() call is providing the expected benefit?
-->
<Match>
<Class name="datawave.ingest.mapreduce.job.BulkIngestMapFileLoader" />
<Method name="sleep" />
<Bug pattern="DM_GC" />
</Match>
<!--
The exception is ignored in this case b/c the preferred default value is defined just prior
to the potential NumberFormatException, and error handling is deferred to just outside the
try/catch scope
-->
<Match>
<Class name="datawave.query.language.parser.lucene.AccumuloSyntaxParser" />
<Method name="Term" />
<Bug pattern="DE_MIGHT_IGNORE" />
</Match>
<!--
The transient currentRow field will take its default value upon deserialization, and that is
exactly what is desired here. Implementing custom serialization (readObject/writeObject) to
silence this finding isn't needed/justified
-->
<Match>
<Class name="datawave.webservice.results.cached.CachedRunningQuery" />
<Field name="currentRow" />
<Bug pattern="SE_TRANSIENT_FIELD_NOT_RESTORED" />
</Match>
<!--
Equals method is only implemented in order to throw UnsupportedOperationException.
So, there's no reason to override Object.hashCode
-->
<Match>
<Class name="datawave.query.iterator.ParentQueryIterator$KeepAllFlagSetter" />
<Bug pattern="HE_EQUALS_USE_HASHCODE" />
</Match>
<!--
Needs further review. See inline code comments
-->
<Match>
<Class name="datawave.query.language.functions.jexl.Chain" />
<Bug pattern="RE_POSSIBLE_UNINTENDED_PATTERN" />
</Match>
<!--
For the CN_IDIOM_NO_SUPER_CALL instances excluded below, the super.clone() call is sometimes not
possible, i.e., because clone() is abstract in the superclass. In all cases, it is not actually
warranted b/c we are simply using clone() to delegate instantiation to a copy constructor, which
inevitably invokes the superclass constructor as appropriate
We should probably re-evaluate the utility of implementing clone/Cloneable at all...
https://www.artima.com/intv/bloch13.html
-->
<Match>
<Class name="~datawave\.query\..*" />
<Method name="clone" />
<Bug pattern="CN_IDIOM_NO_SUPER_CALL" />
</Match>
<!-- False-positive: byteSeq local var is clearly being used in multiple places (??) -->
<Match>
<Class name="datawave.query.transformer.UniqueTransform" />
<Method name="isDuplicate" />
<Bug pattern="DLS_DEAD_LOCAL_STORE" />
</Match>
<!-- False-positive?? -->
<Match>
<Class name="~datawave\.query\.util\.cache.*Loader" />
<Method name="load" />
<Bug pattern="NP_NONNULL_PARAM_VIOLATION" />
</Match>
<Match>
<Class name="datawave.query.index.lookup.TupleToRange" />
<Method name="createDayRange" />
<Bug pattern="NP_NULL_PARAM_DEREF" />
</Match>
<Match>
<Class name="~datawave\.query.*Configuration" />
<Field type="java.util.Map" />
<Bug pattern="SE_BAD_FIELD" />
</Match>
<Match>
<Class name="~datawave\.query.*Configuration" />
<Field type="java.util.Set" />
<Bug pattern="SE_BAD_FIELD" />
</Match>
<Match>
<Class name="~datawave\.query.*Configuration" />
<Field type="java.util.List" />
<Bug pattern="SE_BAD_FIELD" />
</Match>
</FindBugsFilter>