You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@accumulo.apache.org by GitBox <gi...@apache.org> on 2022/02/14 22:34:23 UTC
[GitHub] [accumulo] ctubbsii opened a new issue #2497: Test jar contains resources at its root
ctubbsii opened a new issue #2497:
URL: https://github.com/apache/accumulo/issues/2497
The test jar contains resource files that are at the root of the jar (not in a package). This can create ambiguity if these resources exist in multiple jars on the class path or elsewhere on the class path. Resources can, and should, also be scoped to a package, if they are included in a jar. This probably doesn't matter a lot right now, but it does affect the way we need to load them as class path resources, and may be antithetical to Java 9's new module system, if not actually preventing the test jar from working in a modular environment.
```
$ jar tf test/target/accumulo-test-2.1.0-SNAPSHOT.jar | grep -v ^org/ | grep -v ^META-INF/
FooConstraint.jar
FooConstraint_2_1.jar
FooFilter.jar
ShellServerIT-iterators.jar
TestCombinerX.jar
TestCombinerY.jar
TestCompactionStrat.jar
log4j2-test.properties
shellit.shellit
```
These test resources were included in the jar because they exist in `src/main/resources/`. They can probably be relocated to `src/main/resources/org/apache/accumulo/test/`, but the tests that use them (as well as log4j) would have to be updated to find them at their new location.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@accumulo.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [accumulo] milleruntime closed issue #2497: Test jar contains resources at its root
Posted by GitBox <gi...@apache.org>.
milleruntime closed issue #2497:
URL: https://github.com/apache/accumulo/issues/2497
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@accumulo.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [accumulo] milleruntime commented on issue #2497: Test jar contains resources at its root
Posted by GitBox <gi...@apache.org>.
milleruntime commented on issue #2497:
URL: https://github.com/apache/accumulo/issues/2497#issuecomment-1040701499
Are there issues with these files being in the jar?
<pre>
log4j2-test.properties
shellit.shellit
</pre>
I have no idea what that second file is so not sure what to do with it.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@accumulo.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [accumulo] ctubbsii commented on issue #2497: Test jar contains resources at its root
Posted by GitBox <gi...@apache.org>.
ctubbsii commented on issue #2497:
URL: https://github.com/apache/accumulo/issues/2497#issuecomment-1040775407
> Are there issues with these files being in the jar?
>
> log4j2-test.properties
This one might be tricky to move. I'm not sure. We're probably relying on it being in a default location, for log4j to pick it up automatically. However, that's probably also controllable with a system property we can set in the surefire/failsafe config.
> shellit.shellit
> I have no idea what that second file is so not sure what to do with it.
This can be moved. It actually looks like another one that doesn't actually need to be put into the jar. The ShellIT reads it directly from src/main/resources , and it looks like it does that in order to test executing a file with Accumulo shell commands.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: notifications-unsubscribe@accumulo.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org