felix-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Karl Pauls (JIRA)" <j...@apache.org>
Subject [jira] [Commented] (FELIX-3262) Startup delay due to URLHandlersBundleStreamHandler
Date Thu, 03 May 2012 20:36:48 GMT

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

Karl Pauls commented on FELIX-3262:

I think what we need to do is to override getHostAddress and return null there. The bundle
url doesn't really have one. 

I'll commited a fix for this, can your verify and close this issue if it works for you?
> Startup delay due to URLHandlersBundleStreamHandler 
> ----------------------------------------------------
>                 Key: FELIX-3262
>                 URL: https://issues.apache.org/jira/browse/FELIX-3262
>             Project: Felix
>          Issue Type: Improvement
>          Components: Framework
>    Affects Versions: framework-3.0.9
>         Environment: Karaf 2.2.3 with spring-dm, spring
>            Reporter: Sergey Epik
>            Assignee: Karl Pauls
>             Fix For: framework-4.2.0
>         Attachments: getHosts-osgiextender.txt
>   Original Estimate: 1h
>  Remaining Estimate: 1h
> Problem: slow startup of bundles that use spring and spring-dm.
> When spring-dm starts spring application context, it puts a lot of objects that contain
URL into set/map structures.
> URL.hashCode delegates call to handler. 
> URLHandlersBundleStreamHandler does not implement hashCode(URL u), but URLStreamHandler
(parent) calls InetAddress.getByName(name) with bundle number. 
> This call is very slow and method URLStreamHandler.getHostAddress is synchronized.
> We have found that Equinox's handler org.eclipse.osgi.framework.internal.core.BundleResourceHandler
overrides hashCode(URL u).
> Thread dump that demonstrates problem is attached.

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


View raw message