[
https://issues.apache.org/jira/browse/FELIX-5251?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15279720#comment-15279720
]
Christian Schneider commented on FELIX-5251:
--------------------------------------------
The change looks good to me. We still have kind of a hotspot in ResolverImpl
though. The method checkpackageSpaceConsistency is very long and complex:
https://github.com/apache/felix/blob/trunk/resolver/src/main/java/org/apache/felix/resolver/ResolverImpl.java#L1262-L1569
I do not have a good idea how to split it up but this would be a good spot for
further improvements.
> Resolver impl is in need of extensive cleanup
> ---------------------------------------------
>
> Key: FELIX-5251
> URL: https://issues.apache.org/jira/browse/FELIX-5251
> Project: Felix
> Issue Type: Bug
> Components: Resolver
> Affects Versions: resolver-1.8.0
> Environment: All
> Reporter: Thomas Watson
> Assignee: Thomas Watson
>
> The Resolver implementation has undergone a lot of changes since it was first
> contributed. Over the coarse of development the code has deteriorated a bit.
> This is not to blame the contributors to the codebase. The codebase and
> overall problem is complicated and already hard enough to understand.
> I have been looking to implement some upcoming changes that are being
> proposed for the OSGi R7 specification. Before I start that work I have been
> spending significant time scrubbing the resolver code and trying to make it a
> little more understandable. Here are the main things I have done:
> 1) Create a common code path for dynamic resolution and regular resolution.
> 2) Extract common code and greatly reduce the number of lines contained in
> complicated do/while loops.
> 3) Make proper use of the existing ResolveSession class to keep track of
> state during the resolution process. This keeps the maintenance of state in
> one place. The code had evolved into many separate options being passed
> around to methods, each maintaining some kind of state.
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)