You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@felix.apache.org by "Felix Meschberger (Commented) (JIRA)" <ji...@apache.org> on 2012/01/29 13:49:10 UTC

[jira] [Commented] (FELIX-3325) Finding activate/deactivate/modified methods has numerous problems

    [ https://issues.apache.org/jira/browse/FELIX-3325?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13195747#comment-13195747 ] 

Felix Meschberger commented on FELIX-3325:
------------------------------------------

Thanks for providing the patch.

> ReferenceMetadata.validate

right, not a big deal in reality, but good for code completeness.

> BaseMethod.getMethod

Wow, yeah, the expected exception is eaten.

> ActivateMethod.doFindMethod

right.

going to apply this patch.
                
> Finding activate/deactivate/modified methods has numerous problems
> ------------------------------------------------------------------
>
>                 Key: FELIX-3325
>                 URL: https://issues.apache.org/jira/browse/FELIX-3325
>             Project: Felix
>          Issue Type: Bug
>          Components: Declarative Services (SCR)
>    Affects Versions:  scr-1.6.0
>            Reporter: David Jencks
>         Attachments: FELIX-3325.diff
>
>
> I've identified at least 3 problems in the code finding appropriate activate/deactivate/modified methods on DS components.
> 1. BaseMethod.getMethod wraps SuitableMethodNotAccessibleException exceptions in InvocationTargetExceptions, which prevents callers from detecting the SuitableMethodNotAccessibleException and responding appropriately.
> 2. ActivateMethod.doFindMethod: if it gets to looking for an empty method, it will return null if there isn't one, even if there was a previous SuitableMethodNotAccessible detected.  It should only return a non-null method.
> 3. ActivateMethod.getSingleParameterMethod will throw a SuitableMethodNotAccessibleException even if it finds an accessible suitable method after the non-accessible one.
> In addition, ReferenceMetadata.validate does not make the object read-only by setting m_validate.

--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.apache.org/jira/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira