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

Karl Pauls commented on FELIX-6729:
-----------------------------------

Additionally, it sounds strange that they would have both, framework and main 
on the class path. The main jar does contain the framework already so it 
shouldn't be needed to have both on the class path. Regardless, I don't think 
that is the issue but it might be related as judging by the stack trace, you 
are not using 7.0.5 but <=6.0.4. The URLHandlers have been reworked quite a bit 
since then - can you please try to identify where <=6.0.4 comes into the mix 
(as the URLHandlers are shared, it could be anything in the JVM) and see if 
updating to 7.0.5 helps?

> Repeated Looping observed with Felix Main and Felix Framework jar usage
> -----------------------------------------------------------------------
>
>                 Key: FELIX-6729
>                 URL: https://issues.apache.org/jira/browse/FELIX-6729
>             Project: Felix
>          Issue Type: Bug
>          Components: Framework, Main
>    Affects Versions: framework-7.0.5
>         Environment: Oracle WebLogic on which Custom Plugin applications have 
> been deployed which uses the "org.apache.felix.org.apache.felix.main.jar" and 
> "org.apache.felix.framework.jar" jar as 3rd party references for OSGi 
> implementation.
> Operating System : Oracle Linux
>            Reporter: Mahesh Kantharaj
>            Priority: Blocker
>             Fix For: framework-7.0.5
>
>   Original Estimate: 168h
>  Remaining Estimate: 168h
>
> The Custom Plugin which references the 
> "org.apache.felix.org.apache.felix.main.jar" and 
> "org.apache.felix.framework.jar" 3rd Party jars is deployed on WLS (Oracle 
> WebLogic Server). The Felix Framework jar is used in the Custom Plugin to 
> enable the plugin to interact with the OAM (Oracle Access Manager) system 
> wherein it helps in integrating the custom plugin with the OAM seamlessly and 
> efficiently.
> However there is an intermittent issue that is observed during the 
> initialization phase (Deployed Server restart) of the custom plugin wherein 
> repeated looping is observed 3ith the below mentioned stack upon  
> java.net.URL usage.
> This results in Stack Over Exception with an abnormal compressed class space 
> growth that eventually leads to Out of Memory exception and thereby the JVM 
> crashes. The only workaround available with us now is to perform the Server 
> restart on which the custom plugin is deployed so that the Full GC is 
> triggered and thereby the compressed class space is cleared as a temporary 
> relief to the issue. We would like to have the URL Handler related looping 
> stack from Felix Main and Framework to be investigated to devise a solution 
> from Apache team, to resolve the issue (This seems to be a race condition 
> scenario based on issue symptoms). 
>         at 
> org.apache.felix.framework.util.SecureAction.getDeclaredMethod(SecureAction.java:850)
>         at 
> org.apache.felix.framework.URLHandlers.getFrameworkFromContext(URLHandlers.java:752)
>         at 
> org.apache.felix.framework.URLHandlersStreamHandlerProxy.getStreamHandlerService(URLHandlersStreamHandlerProxy.java:574)
>         at 
> org.apache.felix.framework.URLHandlersStreamHandlerProxy.parseURL(URLHandlersStreamHandlerProxy.java:369)
>         at java.net.URL.<init>(URL.java:639)
>         at java.net.URL.<init>(URL.java:507)
> **********
> The complete stack trace having the deep recursive call related to Felix jar 
> is pasted below for your reference:
> <FINER> <ClassLoader> Thread [ACTIVE] ExecuteThread: '37' for queue: 
> 'weblogic.kernel.Default (self-tuning)' Defining 
> org.osgi.service.packageadmin.ExportedPackage from 
> file:/p01/app/oracle/oam12c/wlserver/server/lib/org.apache.felix.org.apache.felix.main.jar
>  in 'weblogic-launcher'
> java.lang.Exception
>         at 
> sun.misc.URLClassPath$FileLoader.getResource(URLClassPath.java:1340)
>         at sun.misc.URLClassPath.getResource(URLClassPath.java:250)
>         at java.net.URLClassLoader$1.run(URLClassLoader.java:366)
>         at java.net.URLClassLoader$1.run(URLClassLoader.java:363)
>         at java.security.AccessController.doPrivileged(Native Method)
>         at java.net.URLClassLoader.findClass(URLClassLoader.java:362)
>         at java.lang.ClassLoader.loadClass(ClassLoader.java:418)
>         at java.lang.ClassLoader.loadClass(ClassLoader.java:351)
>         at java.lang.Class.getDeclaredMethods0(Native Method)
>         at java.lang.Class.privateGetDeclaredMethods(Class.java:2701)
>         at java.lang.Class.getDeclaredMethod(Class.java:2128)
>         at 
> org.apache.felix.framework.util.SecureAction.getDeclaredMethod(SecureAction.java:850)
>         at 
> org.apache.felix.framework.URLHandlers.getFrameworkFromContext(URLHandlers.java:752)
>         at 
> org.apache.felix.framework.URLHandlersStreamHandlerProxy.getStreamHandlerService(URLHandlersStreamHandlerProxy.java:574)
>         at 
> org.apache.felix.framework.URLHandlersStreamHandlerProxy.parseURL(URLHandlersStreamHandlerProxy.java:369)
>         at java.net.URL.<init>(URL.java:639)
>         at java.net.URL.<init>(URL.java:507)
>         at 
> sun.misc.URLClassPath$FileLoader.getResource(URLClassPath.java:1340)
>         at sun.misc.URLClassPath.getResource(URLClassPath.java:250)
>         at java.net.URLClassLoader$1.run(URLClassLoader.java:366)
>         at java.net.URLClassLoader$1.run(URLClassLoader.java:363)
>         at java.security.AccessController.doPrivileged(Native Method)
>         at java.net.URLClassLoader.findClass(URLClassLoader.java:362)
>         at java.lang.ClassLoader.loadClass(ClassLoader.java:418)
>         at java.lang.ClassLoader.loadClass(ClassLoader.java:351)
>         at java.lang.Class.getDeclaredMethods0(Native Method)
>         at java.lang.Class.privateGetDeclaredMethods(Class.java:2701)
>         at java.lang.Class.getDeclaredMethod(Class.java:2128)
>         at 
> org.apache.felix.framework.util.SecureAction.getDeclaredMethod(SecureAction.java:850)
>         at 
> org.apache.felix.framework.URLHandlers.getFrameworkFromContext(URLHandlers.java:752)
>         at 
> org.apache.felix.framework.URLHandlersStreamHandlerProxy.getStreamHandlerService(URLHandlersStreamHandlerProxy.java:574)
>         at 
> org.apache.felix.framework.URLHandlersStreamHandlerProxy.parseURL(URLHandlersStreamHandlerProxy.java:369)
>         at java.net.URL.<init>(URL.java:639)
>         at java.net.URL.<init>(URL.java:507)
>         at 
> sun.misc.URLClassPath$FileLoader.getResource(URLClassPath.java:1340)
>         at sun.misc.URLClassPath.getResource(URLClassPath.java:250)
>         at java.net.URLClassLoader$1.run(URLClassLoader.java:366)
>         at java.net.URLClassLoader$1.run(URLClassLoader.java:363)
>         at java.security.AccessController.doPrivileged(Native Method)
>         at java.net.URLClassLoader.findClass(URLClassLoader.java:362)
>         at java.lang.ClassLoader.loadClass(ClassLoader.java:418)
>         at java.lang.ClassLoader.loadClass(ClassLoader.java:351)
>         at java.lang.Class.getDeclaredMethods0(Native Method)
>         at java.lang.Class.privateGetDeclaredMethods(Class.java:2701)
>         at java.lang.Class.getDeclaredMethod(Class.java:2128)
>         at 
> org.apache.felix.framework.util.SecureAction.getDeclaredMethod(SecureAction.java:850)
>   
>  
>  
>  



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

Reply via email to