[
https://issues.apache.org/jira/browse/AXIOM-532?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=18135339#comment-18135339
]
ASF GitHub Bot commented on AXIOM-532:
--------------------------------------
veithen commented on PR #980:
URL: https://github.com/apache/ws-axiom/pull/980#issuecomment-6528960931
Thanks for tracking this down. Adding an SLF4J binding looks like the right
fix, but I'd suggest a different binding.
`slf4j-jdk14` in `eclipse-tests` and `osgi-tests` isn't really a
project-wide convention. Those modules run under Pax Exam, and `slf4j-jdk14` is
provisioned into the OSGi container as a bundle through the `alta-maven-plugin`
link files (see `BlueprintTest`, which loads `slf4j.api.link` and
`slf4j.jdk14.link`).
The non-OSGi test modules (`jaxws-tests`, `spring-ws-tests` and
`spring-ws-testsuite`) use Log4j 2 instead, with these test-scoped dependencies
(versions come from `log4j-bom` in the root POM):
```xml
<dependency>
<groupId>org.apache.logging.log4j</groupId>
<artifactId>log4j-jcl</artifactId>
<scope>test</scope>
</dependency>
<dependency>
<groupId>org.apache.logging.log4j</groupId>
<artifactId>log4j-slf4j2-impl</artifactId>
<scope>test</scope>
</dependency>
<dependency>
<groupId>org.apache.logging.log4j</groupId>
<artifactId>log4j-core</artifactId>
<scope>test</scope>
</dependency>
```
Each also has a `src/test/resources/log4j2-test.xml` with a console appender
and the root level at `warn`. Could you do the same in `wss4j-tests` and copy
that config file from `jaxws-tests`? That gives SLF4J a binding, which should
fix the `CryptoFactory` initialization on Semeru, and keeps logging consistent
with the other plain JUnit test modules.
A small note on the description: `org.slf4j.impl.StaticLoggerBinder` is how
SLF4J 1.x finds a binding, but we import `slf4j-bom` 2.0.20, and SLF4J 2.x
finds providers through `ServiceLoader`. It might be worth checking which
`slf4j-api` version actually ends up on the test classpath and updating the
explanation to match. This doesn't change the fix.
> Unable to build with Semeru Java
> --------------------------------
>
> Key: AXIOM-532
> URL: https://issues.apache.org/jira/browse/AXIOM-532
> Project: Axiom
> Issue Type: Bug
> Reporter: Andreas Martens
> Priority: Major
>
> There are two main problems in building Axiom with a non-hotspot JDK:
> # the pre-req `jrel` library assumes that identity hashes are non-negative.
> # we need a class for org.slf4j.impl.StaticLoggerBinder
> For the first one, I have a PR open against jrel and can update axiom when/if
> that gets accepted, for the latter we can pull in slf4j-jdk14 which I'll open
> a PR for
--
This message was sent by Atlassian Jira
(v10.3.26#10030026)
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]