IntelliJ just started failing to compile because we have two copies of
ExtendsFunctionAdapter.java. Apparently, IJ was happy enough to ignore
these duplicates for a month or so, but it's now fed up and will no longer
tolerate the duplication so it's failing with:
Error:(21, 8) java: duplicate class:
org.apache.geode.management.internal.deployment.ExtendsFunctionAdapter
This file is in geode-core/src/distributedTest/resources and
geode-core/src/integrationTest/resources:
1)
./geode-core/src/distributedTest/resources/org/apache/geode/management/internal/deployment/ExtendsFunctionAdapter.java
2)
./geode-core/src/integrationTest/resources/org/apache/geode/management/internal/deployment/ExtendsFunctionAdapter.java
Apparently we have two tests that load these java files as resources:
1)
geode-core/src/distributedTest/java/org/apache/geode/management/internal/cli/commands/DeployCommandFunctionRegistrationDUnitTest.java:83:
"/org/apache/geode/management/internal/deployment/ExtendsFunctionAdapter.java");
2.a)
geode-core/src/integrationTest/java/org/apache/geode/management/internal/deployment/FunctionScannerTest.java:62:
File sourceFileOne = loadTestResource("ExtendsFunctionAdapter.java");
2.b)
geode-core/src/integrationTest/java/org/apache/geode/management/internal/deployment/FunctionScannerTest.java:73:
File sourceFileOne =
loadTestResource("AbstractExtendsFunctionAdapter.java");
2.c)
geode-core/src/integrationTest/java/org/apache/geode/management/internal/deployment/FunctionScannerTest.java:74:
File sourceFileTwo =
loadTestResource("ConcreteExtendsAbstractExtendsFunctionAdapter.java");
Do we really need to have two copies of this file in our codebase?
PS, here's the last commit to touch these two files:
commit 65c79841b65d7bd9ffa3c50fa73d4d3857dced58
Author: Jacob Barrett <[email protected]>
Date: Fri Aug 10 15:49:22 2018 -0700
GEODE-5530: Removes test dependency from other test source sets (#2294)
Moves common sources to geode-dunit or geode-junit.
Co-authored-by: Finn Sutherland <[email protected]>
Thanks,
Kirk