-
Notifications
You must be signed in to change notification settings - Fork 6
/
pom.xml
2020 lines (1681 loc) · 76.4 KB
/
pom.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
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
<?xml version="1.0" encoding="UTF-8"?>
<!--
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.
-->
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
<modelVersion>4.0.0</modelVersion>
<groupId>io.uhndata.cards</groupId>
<artifactId>cards-parent</artifactId>
<version>0.9.26-SNAPSHOT</version>
<packaging>pom</packaging>
<name>CARDS - Parent POM</name>
<description>CARDS is a software tool providing an easy-to-use Web interface and standardized database back-end for collecting medical data.</description>
<url>https://cards.uhndata.io/</url>
<inceptionYear>2019</inceptionYear>
<licenses>
<license>
<name>Apache License, Version 2.0</name>
<url>https://www.apache.org/licenses/LICENSE-2.0.txt</url>
<distribution>repo</distribution>
</license>
</licenses>
<scm>
<connection>scm:git:git://github.com/data-team-uhn/cards.git</connection>
<developerConnection>scm:git:[email protected]:data-team-uhn/cards.git</developerConnection>
<url>https://github.com/data-team-uhn/cards/tree/master/</url>
<tag>HEAD</tag>
</scm>
<organization>
<name>DATA Team at UHN</name>
<url>https://uhndata.io/</url>
</organization>
<developers>
<developer>
<id>uhn</id>
<name>DATA Team at UHN</name>
<url>https://uhndata.io/</url>
</developer>
</developers>
<distributionManagement>
<snapshotRepository>
<id>ossrh</id>
<url>https://s01.oss.sonatype.org/content/repositories/snapshots</url>
</snapshotRepository>
</distributionManagement>
<properties>
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
<cards.version>${project.version}</cards.version>
<app.name>Clinical ARchive for Data Science</app.name>
<platform.name>CARDS</platform.name>
<slf4j.version>1.7.36</slf4j.version>
<jackrabbit.version>2.21.20</jackrabbit.version>
<oak.version>1.44.0</oak.version>
<sling.saml.version>0.2.6.cards.2</sling.saml.version>
<!-- Versions to be replaced in the feature files -->
<asm.version>9.3</asm.version>
<composum.nodes.version>4.1.1</composum.nodes.version>
<jackson.version>2.13.5</jackson.version>
<groovy.version>3.0.10</groovy.version>
<enforcer.skip>false</enforcer.skip>
<checkstyle.skip>false</checkstyle.skip>
<dependencyCheck.skip>false</dependencyCheck.skip>
<coverage.instructionRatio>1.00</coverage.instructionRatio>
<webpackArguments>--mode=development</webpackArguments>
</properties>
<dependencyManagement>
<dependencies>
<!-- Common dependencies -->
<dependency>
<groupId>javax.json</groupId>
<artifactId>javax.json-api</artifactId>
<version>1.1.4</version>
</dependency>
<!-- Apache Commons -->
<dependency>
<groupId>org.apache.commons</groupId>
<artifactId>commons-lang3</artifactId>
<version>3.12.0</version>
</dependency>
<dependency>
<groupId>commons-io</groupId>
<artifactId>commons-io</artifactId>
<version>2.14.0</version>
</dependency>
<dependency>
<groupId>org.apache.commons</groupId>
<artifactId>commons-text</artifactId>
<version>1.10.0</version>
</dependency>
<dependency>
<groupId>org.apache.commons</groupId>
<artifactId>commons-collections4</artifactId>
<version>4.4</version>
</dependency>
<dependency>
<groupId>commons-collections</groupId>
<artifactId>commons-collections</artifactId>
<version>3.2.2</version>
</dependency>
<dependency>
<groupId>org.apache.commons</groupId>
<artifactId>commons-csv</artifactId>
<version>1.9.0</version>
</dependency>
<!-- Everybody logs -->
<dependency>
<groupId>org.slf4j</groupId>
<artifactId>slf4j-api</artifactId>
<version>${slf4j.version}</version>
</dependency>
<dependency>
<groupId>org.slf4j</groupId>
<artifactId>jcl-over-slf4j</artifactId>
<version>${slf4j.version}</version>
</dependency>
<dependency>
<groupId>org.slf4j</groupId>
<artifactId>log4j-over-slf4j</artifactId>
<version>${slf4j.version}</version>
</dependency>
<!-- OSGI -->
<dependency>
<groupId>org.osgi</groupId>
<artifactId>osgi.core</artifactId>
<version>8.0.0</version>
</dependency>
<dependency>
<groupId>org.osgi</groupId>
<artifactId>org.osgi.service.component</artifactId>
<version>1.4.0</version>
</dependency>
<dependency>
<groupId>org.osgi</groupId>
<artifactId>org.osgi.service.component.annotations</artifactId>
<version>1.4.0</version>
</dependency>
<dependency>
<groupId>org.osgi</groupId>
<artifactId>org.osgi.service.event</artifactId>
<version>1.4.1</version>
</dependency>
<dependency>
<groupId>org.osgi</groupId>
<artifactId>org.osgi.service.metatype.annotations</artifactId>
<version>1.4.1</version>
</dependency>
<dependency>
<groupId>org.osgi</groupId>
<artifactId>org.osgi.annotation.versioning</artifactId>
<version>1.1.2</version>
</dependency>
<dependency>
<groupId>org.osgi</groupId>
<artifactId>osgi.cmpn</artifactId>
<version>6.0.0</version>
<scope>provided</scope>
</dependency>
<!-- Platform dependencies -->
<!-- Servlet engine -->
<dependency>
<groupId>javax.servlet</groupId>
<artifactId>javax.servlet-api</artifactId>
<version>3.1.0</version>
<scope>provided</scope>
</dependency>
<!-- JCR -->
<dependency>
<groupId>javax.jcr</groupId>
<artifactId>jcr</artifactId>
<version>2.0</version>
</dependency>
<dependency>
<groupId>org.apache.jackrabbit</groupId>
<artifactId>jackrabbit-jcr-commons</artifactId>
<version>${jackrabbit.version}</version>
</dependency>
<dependency>
<groupId>org.apache.jackrabbit</groupId>
<artifactId>jackrabbit-spi-commons</artifactId>
<version>${jackrabbit.version}</version>
</dependency>
<!-- Oak -->
<dependency>
<groupId>org.apache.jackrabbit</groupId>
<artifactId>oak-jackrabbit-api</artifactId>
<version>${oak.version}</version>
<scope>provided</scope>
</dependency>
<dependency>
<groupId>org.apache.jackrabbit</groupId>
<artifactId>oak-api</artifactId>
<version>${oak.version}</version>
</dependency>
<dependency>
<groupId>org.apache.jackrabbit</groupId>
<artifactId>oak-core</artifactId>
<version>${oak.version}</version>
</dependency>
<dependency>
<groupId>org.apache.jackrabbit</groupId>
<artifactId>oak-core-spi</artifactId>
<version>${oak.version}</version>
</dependency>
<dependency>
<groupId>org.apache.jackrabbit</groupId>
<artifactId>oak-store-spi</artifactId>
<version>${oak.version}</version>
</dependency>
<dependency>
<groupId>org.apache.jackrabbit</groupId>
<artifactId>oak-security-spi</artifactId>
<version>${oak.version}</version>
</dependency>
<!-- Sling -->
<dependency>
<groupId>org.apache.sling</groupId>
<artifactId>org.apache.sling.api</artifactId>
<version>2.27.0</version>
</dependency>
<dependency>
<groupId>org.apache.sling</groupId>
<artifactId>org.apache.sling.servlets.annotations</artifactId>
<version>1.2.6</version>
</dependency>
<dependency>
<groupId>org.apache.sling</groupId>
<artifactId>org.apache.sling.servlets.post</artifactId>
<version>2.5.0</version>
</dependency>
<dependency>
<groupId>org.apache.sling</groupId>
<artifactId>org.apache.sling.scripting.sightly.runtime</artifactId>
<version>1.2.6-1.4.0</version>
</dependency>
<dependency>
<groupId>org.apache.sling</groupId>
<artifactId>org.apache.sling.commons.scheduler</artifactId>
<version>2.7.12</version>
</dependency>
<dependency>
<groupId>org.osgi</groupId>
<artifactId>org.osgi.framework</artifactId>
<version>1.9.0</version>
</dependency>
<!-- TEST -->
<dependency>
<groupId>junit</groupId>
<artifactId>junit</artifactId>
<version>4.13.2</version>
<scope>test</scope>
</dependency>
<dependency>
<groupId>org.mockito</groupId>
<artifactId>mockito-core</artifactId>
<version>1.10.19</version>
<scope>test</scope>
</dependency>
<dependency>
<groupId>com.google.guava</groupId>
<artifactId>guava</artifactId>
<version>32.0.1-jre</version>
</dependency>
<dependency>
<groupId>com.google.code.findbugs</groupId>
<artifactId>jsr305</artifactId>
<version>3.0.2</version>
</dependency>
<dependency>
<groupId>net.jcip</groupId>
<artifactId>jcip-annotations</artifactId>
<version>1.0</version>
</dependency>
</dependencies>
</dependencyManagement>
<build>
<defaultGoal>install</defaultGoal>
<extensions>
<extension>
<groupId>org.apache.maven.wagon</groupId>
<artifactId>wagon-webdav-jackrabbit</artifactId>
<version>3.5.1</version>
</extension>
</extensions>
<plugins>
<!-- Show compiler warnings -->
<plugin>
<artifactId>maven-compiler-plugin</artifactId>
<configuration>
<compilerArgument>-Xlint:all</compilerArgument>
<showWarnings>true</showWarnings>
<showDeprecation>true</showDeprecation>
<failOnWarning>true</failOnWarning>
</configuration>
</plugin>
<!-- Run Checkstyle on Java code-->
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-checkstyle-plugin</artifactId>
</plugin>
<!-- Validate HTL files -->
<plugin>
<groupId>org.apache.sling</groupId>
<artifactId>htl-maven-plugin</artifactId>
</plugin>
<!-- Check that declared dependencies match what's actually used -->
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-dependency-plugin</artifactId>
<executions>
<execution>
<id>check-dependencies</id>
<goals>
<goal>analyze-only</goal>
</goals>
<configuration>
<failOnWarning>true</failOnWarning>
<ignoreNonCompile>true</ignoreNonCompile>
<skip>${dependencyCheck.skip}</skip>
</configuration>
</execution>
</executions>
</plugin>
<!-- Package LICENSE and NOTICE files in the built artifacts -->
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-remote-resources-plugin</artifactId>
<dependencies>
<dependency>
<groupId>io.uhndata.cards</groupId>
<artifactId>cards-license-resources</artifactId>
<version>1</version>
</dependency>
</dependencies>
<executions>
<execution>
<id>generate-license-resources</id>
<goals>
<goal>process</goal>
</goals>
<configuration>
<resourceBundles>
<resourceBundle>io.uhndata.cards:cards-license-resources:1</resourceBundle>
</resourceBundles>
</configuration>
</execution>
</executions>
</plugin>
<!-- Fail the build if the test coverage is below a given value. -->
<plugin>
<groupId>org.jacoco</groupId>
<artifactId>jacoco-maven-plugin</artifactId>
<version>0.8.7</version>
<executions>
<execution>
<id>jacoco-prepare</id>
<goals>
<goal>prepare-agent</goal>
</goals>
</execution>
<execution>
<id>jacoco-check</id>
<goals>
<goal>check</goal>
</goals>
</execution>
</executions>
<configuration>
<rules>
<rule>
<limits>
<limit>
<counter>INSTRUCTION</counter>
<minimum>${coverage.instructionRatio}</minimum>
</limit>
</limits>
</rule>
</rules>
</configuration>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-enforcer-plugin</artifactId>
<executions>
<!-- Check that all Maven plugins have versions defined -->
<execution>
<id>enforce-plugins</id>
<goals>
<goal>enforce</goal>
</goals>
<configuration>
<rules>
<requirePluginVersions>
<message>Best Practice is to always define plugin versions!</message>
<banLatest>false</banLatest>
<banRelease>false</banRelease>
<banSnapshots>false</banSnapshots>
</requirePluginVersions>
</rules>
</configuration>
</execution>
</executions>
<configuration>
<skip>${enforcer.skip}</skip>
</configuration>
</plugin>
<!-- Check that each source file has the right license header. -->
<plugin>
<groupId>org.apache.rat</groupId>
<artifactId>apache-rat-plugin</artifactId>
<version>0.13</version>
<configuration>
<excludes combine.children="append">
<!-- Used by maven-remote-resources-plugin -->
<exclude>src/main/appended-resources/META-INF/*</exclude>
<!-- Don't check anything in target -->
<exclude>**/target/**</exclude>
<!-- Exclude frontend generated code -->
<exclude>**/frontend/node/**</exclude>
<exclude>**/node_modules/**</exclude>
<exclude>**/frontend/dist/**</exclude>
<exclude>**/webpack.config.js</exclude>
<exclude>**/yarn.lock</exclude>
<!-- Exclude JSON files since comments are not supported -->
<exclude>**/*.json</exclude>
<!-- Exclude CSV files since comments are not supported -->
<exclude>**/*.csv</exclude>
<!-- Exclude .token files since comments are not supported -->
<exclude>**/*.token</exclude>
<!-- Documentation files in markdown format -->
<exclude>**/*.md</exclude>
<!-- File hashes -->
<exclude>**/*.sha256sum</exclude>
<!-- Ignore "hidden" files and folders -->
<exclude>**/.*</exclude>
<exclude>**/.*/**</exclude>
<!-- bnd -->
<exclude>bnd.bnd</exclude>
<!-- Ignore file with data for testing -->
<exclude>**/hpo-test.obo</exclude>
<exclude>**/chebi-test.obo</exclude>
<!-- Ignore generated files that are not checked into git anyways -->
<exclude>compose-cluster/docker-compose.yml</exclude>
<exclude>compose-cluster/initializer/initialize_all.sh</exclude>
<exclude>compose-cluster/mongos/mongo-router.conf</exclude>
<exclude>compose-cluster/shard*/**</exclude>
<exclude>compose-cluster/secrets/**</exclude>
<exclude>compose-cluster/SSL_CONFIG/**</exclude>
<exclude>compose-cluster/SLING/**</exclude>
<exclude>compose-cluster/CARDS_LOGS/**</exclude>
<!-- Ignore data/template files used for generating UI Extensions / ExtensionPoints -->
<exclude>**/Development/ExtensionPointResources/**</exclude>
<!-- Ignore email template files since we do not send a license in notification emails -->
<exclude>**/mailTemplates/**</exclude>
<!-- No license in mailcap file -->
<exclude>mailcap</exclude>
<!-- No license in the project-specific identifiers -->
<exclude>project_code.txt</exclude>
<exclude>project_name.txt</exclude>
<!-- Content with non-Apache Licenses -->
<exclude>**/fullBody.svg</exclude>
</excludes>
</configuration>
<executions>
<execution>
<id>rat-check</id>
<phase>verify</phase>
<goals>
<goal>check</goal>
</goals>
</execution>
</executions>
</plugin>
<plugin>
<groupId>org.apache.sling</groupId>
<artifactId>slingfeature-maven-plugin</artifactId>
<extensions>true</extensions>
</plugin>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-deploy-plugin</artifactId>
<!-- Deploy a copy locally, to avoid coflicts with other builds -->
<executions>
<execution>
<id>default-deploy</id>
<configuration>
<skip>true</skip>
</configuration>
</execution>
<execution>
<id>local-deploy</id>
<phase>verify</phase>
<goals>
<goal>deploy</goal>
</goals>
<configuration>
<altDeploymentRepository>localBuild::default::file://.mvnrepo</altDeploymentRepository>
</configuration>
</execution>
</executions>
</plugin>
</plugins>
<pluginManagement>
<plugins>
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-enforcer-plugin</artifactId>
<!-- Lock down plugin version for build reproducibility -->
<version>3.0.0</version>
</plugin>
<!-- Apply checkstyle rules and fail the build in case of errors. The checkstyle config
files are taken from the build-tools JAR module.-->
<plugin>
<groupId>org.apache.maven.plugins</groupId>
<artifactId>maven-checkstyle-plugin</artifactId>
<!-- Lock down plugin version for build reproducibility -->
<version>3.2.1</version>
<dependencies>
<dependency>
<groupId>com.puppycrawl.tools</groupId>
<artifactId>checkstyle</artifactId>
<version>10.7.0</version>
</dependency>
</dependencies>
<configuration>
<consoleOutput>true</consoleOutput>
<skip>${checkstyle.skip}</skip>
</configuration>
<executions>
<execution>
<id>source-checkstyle</id>
<goals>
<goal>check</goal>
</goals>
<configuration>
<checkstyleRules>
<module name="Checker">
<!--
======================================================================================
Checks that do not require a TreeWalker (sorted alphabetically)
======================================================================================
-->
<module name="FileLength" />
<module name="FileTabCharacter" />
<!-- We don't use Checkstyle's facility to check license headers since it's too limited for our needs.
Instead we use http://code.google.com/p/maven-license-plugin/
<module name="Header">
<property name="headerFile" value="${checkstyle.header.file}" />
<property name="ignoreLines" value="4,5,6,7" />
</module>
-->
<module name="LineLength">
<!-- @(\w+\.)+\w+::\w+\( stands for JSNI method calls: @my.package.MyClass::myMethod() -->
<property name="ignorePattern" value="(@version|@see|@link|^import|@(\w+\.)+\w+::\w+\()" />
<property name="max" value="120" />
</module>
<module name="NewlineAtEndOfFile">
<property name="fileExtensions" value="java, xml, js, css, vm" />
</module>
<module name="NewlineAtEndOfFile">
<property name="lineSeparator" value="crlf" />
<property name="fileExtensions" value="bat" />
</module>
<module name="NewlineAtEndOfFile">
<property name="lineSeparator" value="lf" />
<property name="fileExtensions" value="sh" />
</module>
<!-- We'd like to use this one but there's no option to exclude our internal packages
<module name="PackageHtml" />
-->
<!-- No @author tags -->
<module name="RegexpSingleline">
<property name="format" value="@author" />
<property name="message" value="No @author tag allowed" />
</module>
<module name="RegexpSingleline">
<property name="format" value="\s+$" />
</module>
<module name="SuppressWarningsFilter" />
<!-- We cannot use this rule as it fails on our license headers, considering them as copy-pastes!
<module name="StrictDuplicateCode" />
-->
<!-- We actually have a lot of incomplete translations so we can't really afford this rule
<module name="Translation" />
-->
<module name="UniqueProperties" />
<!--
======================================================================================
Checks that require a TreeWalker (sorted alphabetically)
======================================================================================
-->
<module name="TreeWalker">
<!-- Note: for some checks we have defined a warning severity instead of the default error
severity. This is because we'd like to make the build fail on error for those checks
but there are errors to fix first -->
<!-- Not used because we want to use abstract classes as SPI declarations, without requiring an ugly Abstract* prefix -->
<!--module name="AbstractClassName"/-->
<module name="AnnotationLocation">
<property name="allowSamelineSingleParameterlessAnnotation" value="false" />
</module>
<!-- Not used because we prefer annotations on separate lines, as enforced by AnnotationLocation -->
<!--module name="AnnotationOnSameLine"/-->
<module name="AnonInnerLength" />
<!--module name="ArrayTrailingComma"/-->
<module name="ArrayTypeStyle" />
<module name="AtclauseOrder">
<property name="tagOrder" value="@param, @return, @throws, @exception, @see, @version, @since, @deprecated" />
</module>
<!-- We allow escapes so that the source code can be checked out on non-UTF systems -->
<!--module name="AvoidEscapedUnicodeCharacters"/-->
<!--module name="AvoidInlineConditionals"/-->
<module name="AvoidNestedBlocks" />
<module name="AvoidStarImport" />
<module name="AvoidStaticImport" />
<module name="BooleanExpressionComplexity" />
<module name="ClassDataAbstractionCoupling" />
<module name="ClassFanOutComplexity">
<property name="excludedPackages" value="java.io, java.math, java.text, java.util, java.util.concurrent, java.util.concurrent.atomic, java.util.function, java.util.stream, javax.annotation, javax.inject, javax.servlet, org.apache.commons.collections4, org.apache.commons.lang3, org.json, org.slf4j, org.xwiki.component.annotation, org.apache.sling.servlets.annotations, org.osgi.service.component.annotations" />
</module>
<!-- We use the opposite, RedundantModifier -->
<!--module name="ClassMemberImpliedModifier"/-->
<module name="ClassTypeParameterName" />
<module name="CommentsIndentation" />
<module name="ConstantName" />
<module name="CovariantEquals" />
<module name="CyclomaticComplexity" />
<module name="DeclarationOrder" />
<module name="DefaultComesLast" />
<!-- The default values for this one allow everything to pass. Unneeded.
<module name="DescendantToken" />
-->
<!--module name="DesignForExtension"/-->
<module name="EmptyBlock">
<property name="option" value="text" />
</module>
<module name="EmptyCatchBlock" />
<module name="EmptyForInitializerPad" />
<module name="EmptyForIteratorPad" />
<!-- TODO: Enable this after fixing violations
<module name="EmptyLineSeparator">
<property name="allowMultipleEmptyLines" value="false" />
<property name="allowMultipleEmptyLinesInsideClassMembers" value="false" />
</module>
-->
<module name="EmptyStatement" />
<module name="EqualsAvoidNull" />
<module name="EqualsHashCode" />
<module name="ExecutableStatementCount" />
<module name="ExplicitInitialization" />
<module name="FallThrough" />
<module name="FinalClass" />
<!--module name="FinalLocalVariable"/-->
<!-- TODO: Enable this after fixing violations
<module name="FinalParameters" />
-->
<module name="GenericWhitespace" />
<module name="HiddenField">
<property name="tokens" value="VARIABLE_DEF,LAMBDA" />
</module>
<module name="HideUtilityClassConstructor" />
<!--module name="IllegalCatch"/-->
<module name="IllegalImport">
<property name="illegalPkgs" value="sun,groovy,org.apache.commons.lang,org.apache.commons.codec.binary,antlr" />
</module>
<module name="IllegalInstantiation">
<property name="classes" value="java.lang.Boolean, java.lang.String" />
</module>
<module name="IllegalThrows" />
<module name="IllegalToken">
<property name="tokens" value="LITERAL_NATIVE,LABELED_STAT" />
</module>
<!--module name="IllegalTokenText"/-->
<module name="IllegalType" />
<!--module name="ImportControl"/-->
<module name="ImportOrder">
<property name="groups" value="org.phenotips,org.xwiki,java,javax,org" />
<property name="ordered" value="true" />
<property name="separated" value="true" />
<!-- Static imports -->
<property name="option" value="bottom" />
</module>
<module name="Indentation" />
<module name="InnerAssignment" />
<module name="InterfaceIsType" />
<module name="InterfaceTypeParameterName">
<property name="format" value="^[A-Z]{1,2}$" />
</module>
<module name="JavadocMethod">
<property name="accessModifiers" value="public" />
</module>
<!-- Too strict at the moment -->
<!--module name="JavadocParagraph"/-->
<module name="JavadocStyle" />
<module name="JavadocTagContinuationIndentation" />
<module name="JavadocType">
<property name="scope" value="public" />
<property name="versionFormat" value="\$Id.*\$" />
</module>
<module name="JavadocVariable">
<property name="scope" value="public" />
</module>
<module name="JavaNCSS" />
<module name="LambdaParameterName" />
<module name="LeftCurly">
<property name="option" value="nl" />
<property name="tokens" value="CLASS_DEF,INTERFACE_DEF,ANNOTATION_DEF,ENUM_DEF,CTOR_DEF,METHOD_DEF,OBJBLOCK" />
</module>
<module name="LocalFinalVariableName" />
<module name="LocalVariableName" />
<!--module name="MagicNumber"/-->
<module name="MemberName" />
<module name="MethodCount" />
<module name="MethodLength" />
<!-- Allow for UI methods generated by idea -->
<module name="MethodName">
<property name="format" value="^[a-z][a-zA-Z0-9]*$|^\$\$\$setupUI\$\$\$$" />
</module>
<module name="MethodParamPad" />
<module name="MethodTypeParameterName" />
<!--module name="MissingCtor"/-->
<module name="MissingDeprecated" />
<module name="MissingOverride" />
<module name="MissingSwitchDefault" />
<module name="ModifiedControlVariable" />
<module name="ModifierOrder" />
<module name="MultipleStringLiterals">
<property name="ignoreStringsRegexp" value="^(&#34;&#34;)|(&#34;[0-9]&#34;)|(&#34; &#34;)|(&#34;\]&#34;)|(&#34;\[&#34;)|(&#34;,&#34;)|(&#34;, &#34;)|(&#34;/&#34;)$" />
<property name="allowedDuplicates" value="4" />
</module>
<module name="MultipleStringLiterals">
<property name="ignoreStringsRegexp" value="^(&#34;&#34;)|(&#34;[0-9]&#34;)|(&#34; &#34;)|(&#34;\]&#34;)|(&#34;\[&#34;)|(&#34;,&#34;)|(&#34;, &#34;)|(&#34;/&#34;)$" />
<property name="severity" value="warning" />
</module>
<module name="MultipleVariableDeclarations" />
<module name="MutableException" />
<module name="NeedBraces" />
<module name="NestedForDepth">
<property name="max" value="2" />
</module>
<module name="NestedIfDepth">
<property name="max" value="2" />
</module>
<module name="NestedTryDepth" />
<!--module name="NoClone"/-->
<module name="NoFinalizer" />
<module name="NoLineWrap" />
<module name="NonEmptyAtclauseDescription" />
<module name="NoWhitespaceAfter">
<property name="tokens" value="BNOT, DEC, DOT, INC, LNOT, UNARY_MINUS, UNARY_PLUS" />
</module>
<module name="NoWhitespaceBefore" />
<module name="NPathComplexity" />
<module name="OneStatementPerLine" />
<module name="OneTopLevelClass" />
<module name="OperatorWrap" />
<module name="OuterTypeFilename" />
<module name="OuterTypeNumber" />
<!-- This can clash with DeclarationOrder, since it forces methods with different modifiers close together. -->
<!--module name="OverloadMethodsDeclarationOrder"/-->
<module name="PackageAnnotation" />
<module name="PackageDeclaration" />
<module name="PackageName" />
<module name="ParameterAssignment" />
<module name="ParameterName" />
<module name="ParameterNumber" />
<module name="ParenPad" />
<module name="RedundantImport" />
<module name="RedundantModifier" />
<!-- No direct printing to System.out or System.err -->
<module name="RegexpSinglelineJava">
<!-- . matches any character, so we need to
escape it and use \. to match dots. -->
<property name="format" value="System\.(out|err)\." />
<property name="ignoreComments" value="true" />
</module>
<!--module name="Regexp"/-->
<!--module name="RegexpHeader"/-->
<module name="RequireThis">
<property name="checkMethods" value="false" />
<property name="validateOnlyOverlapping" value="false" />
</module>
<!--module name="RequiredRegexp"/-->
<!-- Increasing the maximum number of allowed return statements, as otherwise
the code will simply use workarounds to hide the same amount of exit points. -->
<module name="ReturnCount">
<property name="max" value="5" />
<property name="maxForVoid" value="5" />
</module>
<module name="RightCurly" />
<module name="SeparatorWrap">
<property name="tokens" value="COMMA" />
<property name="option" value="eol" />
</module>
<module name="SeparatorWrap">
<property name="tokens" value="DOT" />
<property name="option" value="nl" />
</module>
<module name="SimplifyBooleanExpression" />
<module name="SimplifyBooleanReturn" />
<module name="SingleSpaceSeparator" />
<module name="StaticVariableName" />
<module name="StringLiteralEquality" />
<module name="SuperClone" />
<module name="SuperFinalize" />
<module name="SuppressWarningsHolder" />
<!--module name="ThrowsCount"-->
<module name="TodoComment">
<property name="severity" value="warning" />
<property name="format" value="TODO" />
</module>
<module name="TodoComment">
<property name="severity" value="warning" />
<property name="format" value="FIXME" />
</module>
<module name="TodoComment">
<property name="severity" value="warning" />
<property name="format" value="@todo" />
</module>
<module name="TrailingComment" />
<module name="TypeName" />
<module name="TypecastParenPad" />