Venkat Ranganathan created FALCON-2050:
------------------------------------------

             Summary: Configure jetty parent classloader to be prioritized over 
webapp classloader
                 Key: FALCON-2050
                 URL: https://issues.apache.org/jira/browse/FALCON-2050
             Project: Falcon
          Issue Type: Bug
          Components: common
    Affects Versions: 0.10
            Reporter: Venkat Ranganathan
            Assignee: Venkat Ranganathan


FALCON-1942 allowed external libraries to be configured so that libraries like 
Atlas hook can be configured (which the Atlas code itself was part of the Atlas 
client installation).   Unfortunately, the FACLON_EXTRA_CLASSPATH only is 
available in the parent classloader and not via the webapp classloader causing 
stack trace like below to be thrown

To fix this, we need to enable the parent classloader to have priority over the 
webapp classloader.   When a class or resource is resolved, the parent 
classloader will be used and  then the child classloader.

Since all falcon jars are also in the parent path this should fix the issue 
with Atlas hook and similar scnearios.


{quote}
2016-06-24 14:50:47,022 ERROR - [main:] ~ Failed startup of context 
org.mortbay.jetty.webapp.WebAppContext@46e481d6{/,/usr/hdp/current/falcon-server/server/webapp/falcon}
 (log:87)
java.lang.ClassCastException: org.apache.falcon.atlas.service.AtlasService 
cannot be cast to org.apache.falcon.service.FalconService
        at 
org.apache.falcon.service.ServiceInitializer.initialize(ServiceInitializer.java:43)
        at 
org.apache.falcon.listener.ContextStartupListener.contextInitialized(ContextStartupListener.java:56)
        at 
org.mortbay.jetty.handler.ContextHandler.startContext(ContextHandler.java:550)
        at org.mortbay.jetty.servlet.Context.startContext(Context.java:136)
        at 
org.mortbay.jetty.webapp.WebAppContext.startContext(WebAppContext.java:1282)
        at 
org.mortbay.jetty.handler.ContextHandler.doStart(ContextHandler.java:519)
        at 
org.mortbay.jetty.webapp.WebAppContext.doStart(WebAppContext.java:499)
        at 
org.mortbay.component.AbstractLifeCycle.start(AbstractLifeCycle.java:50)
        at 
org.mortbay.jetty.handler.HandlerWrapper.doStart(HandlerWrapper.java:130)
        at org.mortbay.jetty.Server.doStart(Server.java:224)
        at 
org.mortbay.component.AbstractLifeCycle.start(AbstractLifeCycle.java:50)
        at org.apache.falcon.util.EmbeddedServer.start(EmbeddedServer.java:57)
        at org.apache.falcon.FalconServer.main(FalconServer.java:118)
{quote}



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Reply via email to