Alright, thanks for help joostschouten and user2424794. I've got it working.
The mvn dependency:tree
revealed, that other web app's dependency: qpid-client
imported another slf4j-api
to the war.
So another exclusion was necessary:
<dependency>
<groupId>org.apache.qpid</groupId>
<artifactId>qpid-client</artifactId>
<version>0.22</version>
<exclusions>
<exclusion>
<groupId>org.slf4j</groupId>
<artifactId>slf4j-api</artifactId>
</exclusion>
</exclusions>
</dependency>
For the record, the tapestry-core dependency:
<dependency>
<groupId>org.apache.tapestry</groupId>
<artifactId>tapestry-core</artifactId>
<version>${tapestry-release-version}</version>
<exclusions>
<exclusion>
<groupId>org.slf4j</groupId>
<artifactId>slf4j-log4j12</artifactId>
</exclusion>
<exclusion>
<groupId>org.slf4j</groupId>
<artifactId>slf4j-api</artifactId>
</exclusion>
<exclusion>
<groupId>log4j</groupId>
<artifactId>log4j</artifactId>
</exclusion>
</exclusions>
</dependency>
The only problem left is that the war wouldn't compile without the slf4j-api, therefore I add it as war dependency for the compilation, not for the linking - maven's provided
scope:
<dependency>
<groupId>org.slf4j</groupId>
<artifactId>slf4j-api</artifactId>
<version>1.7.5</version>
<scope>provided</scope>
</dependency>
Of course, the slf4j-api
, slf4j-log4j12
and log4j
are added as dependencies for the server, which 'provides' it to the war application.
Now everything compiles, runs and logs just fine.