[jboss-jira] [JBoss JIRA] (WFLY-13598) Hard coded dependencies from resource adapters to legacy security sercvies.

Darran Lofthouse (Jira) issues at jboss.org
Thu Jun 18 12:06:22 EDT 2020


    [ https://issues.redhat.com/browse/WFLY-13598?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14165424#comment-14165424 ] 

Darran Lofthouse commented on WFLY-13598:
-----------------------------------------

I have been able to eliminate the error by converting the last CLI operation to:

/subsystem=resource-adapters/resource-adapter=myrar.rar/connection-definitions=connection-definition:add(class-name=org.wildfly.test.MyRar, *elytron-enabled=true, recovery-elytron-enabled=true*)

I am converting to an enhancement for now but maybe this is still borderline bug, I think for a couple of reasons:
# Removal of the legacy security subsystem shouldn't break a resource adapter which has no security configuration of it's own.
# A resource adapter with no security configuration should not require security attributes just to get it to install.

Ideally we would have something that detects if legacy security is installed or not.

The specific dependencies are added at this point:
https://github.com/wildfly/wildfly/blob/master/connector/src/main/java/org/jboss/as/connector/subsystems/resourceadapters/ConnectionDefinitionAdd.java#L183



> Hard coded dependencies from resource adapters to legacy security sercvies.
> ---------------------------------------------------------------------------
>
>                 Key: WFLY-13598
>                 URL: https://issues.redhat.com/browse/WFLY-13598
>             Project: WildFly
>          Issue Type: Enhancement
>          Components: JCA, Security
>    Affects Versions: 20.0.0.Final
>            Reporter: Darran Lofthouse
>            Assignee: Darran Lofthouse
>            Priority: Major
>              Labels: legacy_security_removal
>             Fix For: 21.0.0.Beta1
>
>
> A resource adapter defined similar to:
>  
> {code:xml}
>             <resource-adapters>
>                 <resource-adapter id="myrar.rar">
>                     <archive>
>                         myrar.rar
>                     </archive>
>                     <connection-definitions>
>                         <connection-definition class-name="org.wildfly.test.MyRar" pool-name="connection-definition"/>
>                     </connection-definitions>
>                 </resource-adapter>
>             </resource-adapters>
> {code}
> Leads to an error:
> {code}
> 13:48:11,932 ERROR [org.jboss.as.controller.management-operation] (Controller Boot Thread) WFLYCTL0013: Operation ("add") failed - address: ([
>     ("subsystem" => "resource-adapters"),
>     ("resource-adapter" => "myrar.rar"),
>     ("connection-definitions" => "connection-definition")
> ]) - failure description: {
>     "WFLYCTL0412: Required services that are not installed:" => [
>         "jboss.security.subject-factory",
>         "jboss.security.simple-security-manager"
>     ],
>     "WFLYCTL0180: Services with missing/unavailable dependencies" => ["jboss.resourceadapters.ra.\"myrar.rar\".connection-definition is missing [jboss.security.simple-security-manager, jboss.security.subject-factory]"]
> }
> {code}
> Resources should not depend on legacy security by default as it may not be there.



--
This message was sent by Atlassian Jira
(v7.13.8#713008)



More information about the jboss-jira mailing list