[jboss-jira] [JBoss JIRA] (WFLY-9747) wildfly-arquillian-container-managed: java.lang.ClassNotFoundException: org.wildfly.security.permission.AbstractNameSetOnlyPermission

James Perkins (Jira) issues at jboss.org
Sun Jan 27 04:30:02 EST 2019


     [ https://issues.jboss.org/browse/WFLY-9747?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

James Perkins resolved WFLY-9747.
---------------------------------
    Resolution: Out of Date


This does seem out of date as I can't seem to reproduce it. One thing that struck me as odd is 2.1.0.Final was pulling in an older version of the jmx-protocol. If this still is an issue I'd be interesting in seeing a reproducer or at least the full pom really.

> wildfly-arquillian-container-managed: java.lang.ClassNotFoundException: org.wildfly.security.permission.AbstractNameSetOnlyPermission
> -------------------------------------------------------------------------------------------------------------------------------------
>
>                 Key: WFLY-9747
>                 URL: https://issues.jboss.org/browse/WFLY-9747
>             Project: WildFly
>          Issue Type: Bug
>            Reporter: Geoffrey De Smet
>            Assignee: James Perkins
>            Priority: Major
>
> On a pretty vanilla war file with a bit JAX-RS and arquillian, I get this error when trying to run an arquillian test (that worked before we upgraded the wildfly version):
> {code}
> [INFO] Running org.optaplanner.openshift.employeerostering.webapp.skill.SkillRestServiceTest
> Jan 31, 2018 7:52:20 PM org.jboss.as.arquillian.container.managed.ManagedDeployableContainer startInternal
> WARNING: Bundles path is deprecated and no longer used.
> Jan 31, 2018 7:52:20 PM org.jboss.as.arquillian.container.managed.ManagedDeployableContainer startInternal
> INFO: Starting container with: [/usr/lib/jvm/java-openjdk/bin/java, -D[Standalone], -Djboss.socket.binding.port-offset=10000, -Xms512m, -Xmx1024m, -XX:MaxPermSize=512m, -ea, -Djboss.home.dir=/home/ge0ffrey/projects/jboss/optashift/optashift-employee-rostering/local/appserver/wildfly-10.1.0.Final, -Dorg.jboss.boot.log.file=/home/ge0ffrey/projects/jboss/optashift/optashift-employee-rostering/local/appserver/wildfly-10.1.0.Final/standalone/log/server.log, -Dlogging.configuration=file:/home/ge0ffrey/projects/jboss/optashift/optashift-employee-rostering/local/appserver/wildfly-10.1.0.Final/standalone/configuration/logging.properties, -jar, /home/ge0ffrey/projects/jboss/optashift/optashift-employee-rostering/local/appserver/wildfly-10.1.0.Final/jboss-modules.jar, -mp, /home/ge0ffrey/projects/jboss/optashift/optashift-employee-rostering/local/appserver/wildfly-10.1.0.Final/modules, org.jboss.as.standalone, -Djboss.home.dir=/home/ge0ffrey/projects/jboss/optashift/optashift-employee-rostering/local/appserver/wildfly-10.1.0.Final, -Djboss.server.base.dir=/home/ge0ffrey/projects/jboss/optashift/optashift-employee-rostering/local/appserver/wildfly-10.1.0.Final/standalone, -Djboss.server.log.dir=/home/ge0ffrey/projects/jboss/optashift/optashift-employee-rostering/local/appserver/wildfly-10.1.0.Final/standalone/log, -Djboss.server.config.dir=/home/ge0ffrey/projects/jboss/optashift/optashift-employee-rostering/local/appserver/wildfly-10.1.0.Final/standalone/configuration]
> OpenJDK 64-Bit Server VM warning: ignoring option MaxPermSize=512m; support was removed in 8.0
> [ERROR] Tests run: 1, Failures: 0, Errors: 1, Skipped: 0, Time elapsed: 0.449 s <<< FAILURE! - in org.optaplanner.openshift.employeerostering.webapp.skill.SkillRestServiceTest
> [ERROR] org.optaplanner.openshift.employeerostering.webapp.skill.SkillRestServiceTest  Time elapsed: 0.448 s  <<< ERROR!
> java.lang.NoClassDefFoundError: org/wildfly/security/permission/AbstractNameSetOnlyPermission
>         at org.apache.maven.surefire.junit4.JUnit4Provider.execute(JUnit4Provider.java:365)
>         at org.apache.maven.surefire.junit4.JUnit4Provider.executeWithRerun(JUnit4Provider.java:272)
>         at org.apache.maven.surefire.junit4.JUnit4Provider.executeTestSet(JUnit4Provider.java:236)
>         at org.apache.maven.surefire.junit4.JUnit4Provider.invoke(JUnit4Provider.java:159)
> Caused by: java.lang.ClassNotFoundException: org.wildfly.security.permission.AbstractNameSetOnlyPermission
>         at org.apache.maven.surefire.junit4.JUnit4Provider.execute(JUnit4Provider.java:365)
>         at org.apache.maven.surefire.junit4.JUnit4Provider.executeWithRerun(JUnit4Provider.java:272)
>         at org.apache.maven.surefire.junit4.JUnit4Provider.executeTestSet(JUnit4Provider.java:236)
>         at org.apache.maven.surefire.junit4.JUnit4Provider.invoke(JUnit4Provider.java:159)
> {code}
> With this parent pom:
> {code}
>   <properties>
>     <version.org.jboss.arquillian>1.2.1.Final</version.org.jboss.arquillian>
>     <version.org.wildfly.arquillian>2.1.0.Final</version.org.wildfly.arquillian>
>     <version.org.jboss.resteasy>3.1.4.Final</version.org.jboss.resteasy>
>   </properties>
>   <dependencyManagement>
>     <dependencies>
>       <dependency>
>         <groupId>org.jboss.arquillian</groupId>
>         <artifactId>arquillian-bom</artifactId>
>         <version>${version.org.jboss.arquillian}</version>
>         <type>pom</type>
>         <scope>import</scope>
>       </dependency>
>       <dependency>
>         <groupId>org.wildfly.arquillian</groupId>
>         <artifactId>wildfly-arquillian-container-managed</artifactId>
>         <version>${version.org.wildfly.arquillian}</version>
>       </dependency>
>       <dependency>
>         <groupId>org.jboss.resteasy</groupId>
>         <artifactId>resteasy-client</artifactId>
>         <version>${version.org.jboss.resteasy}</version>
>       </dependency>
> ...
> {code}
> and this child pom:
> {code}
>     <dependency>
>       <groupId>junit</groupId>
>       <artifactId>junit</artifactId>
>       <scope>test</scope>
>     </dependency>
>     <dependency>
>       <groupId>org.jboss.arquillian.junit</groupId>
>       <artifactId>arquillian-junit-container</artifactId>
>       <scope>test</scope>
>     </dependency>
>     <dependency>
>       <groupId>org.jboss.shrinkwrap.resolver</groupId>
>       <artifactId>shrinkwrap-resolver-depchain</artifactId>
>       <type>pom</type>
>       <scope>test</scope>
>     </dependency>
>     <dependency>
>       <groupId>org.wildfly.arquillian</groupId>
>       <artifactId>wildfly-arquillian-container-managed</artifactId>
>       <scope>test</scope>
>     </dependency>
>     <dependency>
>       <groupId>org.jboss.resteasy</groupId>
>       <artifactId>resteasy-client</artifactId>
>       <scope>test</scope>
>     </dependency>
> {code}
> I am probably not using a correct version combination of arquillian and wildfly, but for mere mortals such as myself it takes days to find a working versions combination of arquillian and wildfly - everytime I need to upgrade wildfly. (The arquillian guides and arquillian-showcase-jaxrs are all hopelessly outdated in this aspect, they still mention jboss-as (= wildfly 7)).
> Solution proposal A)
> wildfly-arquillian-managed should automatically detect that it's a wrong version combination and give an error message like "I am not build to work with version x, but it seems like you're combining me with version y."
> Solution proposal B)
> Use the same version numbers for wildfly-arquillian-container-managed (currently 2.1.0.Final) as for wildfly.



--
This message was sent by Atlassian Jira
(v7.12.1#712002)



More information about the jboss-jira mailing list