Re: Dependency Bug in Soteria 1.0


Arjan Tijms
 

Payara 174 has Soteria as well. The war only has to depend on the API, not on Soteria itself. The 1.0 API is available from Maven central:

<dependency>
    <groupId>javax.security.enterprise</groupId>
    <artifactId>javax.security.enterprise-api</artifactId>
    <version>1.0</version>
    <scope>provided</scope>
</dependency>

Alternatively, I think it should work with any other server if you depend on Soteria indeed, but exclude the API from it. See:

https://maven.apache.org/guides/introduction/introduction-to-optional-and-excludes-dependencies.html

Then include the 1.0 API dependency.

Something like:

<!-- API -->
<dependency>
    <groupId>javax.security.enterprise</groupId>
    <artifactId>javax.security.enterprise-api</artifactId>
    <version>1.0</version>
</dependency>

<!-- Impl, without Api -->
<dependency>
    <groupId>org.glassfish.soteria</groupId>
    <artifactId>javax.security.enterprise</artifactId>
    <version>1.0</version>
    <exclusions> 
        <exclusion> 
          <groupId>javax.security.enterprise</groupId>
          <artifactId>javax.security.enterprise-api</artifactId>
        </exclusion>
      </exclusions> 
</dependency>

Join javaee-security-spec@javaee.groups.io to automatically receive all group messages.