[arquillian-issues] [JBoss JIRA] (ARQ-2109) EJBInjectionEnricher makes too strong assumptions about JNDI names in the "anonymous" case

Ladislav Thon (JIRA) issues at jboss.org
Wed Dec 6 03:27:00 EST 2017


    [ https://issues.jboss.org/browse/ARQ-2109?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13497708#comment-13497708 ] 

Ladislav Thon commented on ARQ-2109:
------------------------------------

Just FYI, since this happened in WildFly Swarm, there's now a test in WildFly Swarm, see SWARM-1713.

> EJBInjectionEnricher makes too strong assumptions about JNDI names in the "anonymous" case
> ------------------------------------------------------------------------------------------
>
>                 Key: ARQ-2109
>                 URL: https://issues.jboss.org/browse/ARQ-2109
>             Project: Arquillian
>          Issue Type: Bug
>          Components: Runtime Enricher SPI
>    Affects Versions: 1.1.13.Final
>            Reporter: Ladislav Thon
>             Fix For: 1.1.14.Final
>
>
> The {{EJBInjectionEnricher}} supports injecting the test instance fields annotated with {{javax.ejb.EJB}}. However, looking at the {{EJBInjectionEnricher.getJndiNamesForAnonymousEJB}} method, it makes too strong assumptions about the JNDI name. Specifically, it assumes the {{test.ear}} and {{test}} names. That doesn't necessarily have to be correct (e.g. WildFly Swarm Arquillian adapter doesn't use these names). There's an easy way to improve this for some situations: also consider the {{java:module}} portable namespace. It can't fix all situations, but it does fix some of them. (For Swarm, it's completely enough, since Swarm doesn't support EARs.)



--
This message was sent by Atlassian JIRA
(v7.5.0#75005)


More information about the arquillian-issues mailing list