4 Replies Latest reply on Jul 13, 2007 1:42 PM by Adrian Brock

    VFSClassLoader has been committed

    Adrian Brock Master

      The new VFSClassLoader has been committed.

      But it is disabled. JBoss Head is still using the UCL (UnifiedClassLoader).

      If you want to try it out, then you need to goto conf/bootstrap-beans.xml and set
      oldClassLoader=false
      on the JMXKernel
      and then go further down the file, comment out the ServiceClassLoaderDeployer
      and uncomment the section marked as VFSClassLoader
      (including the one that says it is a hack :-).

      This really needs integrating in a cleaner way possibly using the deployers
      notion of the ClassLoaderFactory so you only have to define it in one place.

      AFAIK, everything should work with the new classloader,
      but I need to do more testing to make sure there isn't something overlooked.

      The exceptions are the following:

      1) Anything that is referencing RepositoryClassLoader directly.

      At time of writing the ones I'm aware of are:
      a) The Hibernate MBean (which is broken anyway since it still used DeploymentInfo)
      b) AOP in a scoped deployment, there's a seperate thread about this in the AOP forum

      2) Jasper - jsp compilation

      This works, as long as you use the default compiler, i.e. JDT (eclipse compiler)
      If you try to use the ANT compiler it won't know the classpath.
      Since the ANT compiler is inefficient and won't work anyway when we do
      full OSGi classloading semantics, I'm not worried about this.

      3) Testsuite
      Some of the tests are assuming the UCL. A lot of them run on the client side,
      so its not really an issue. But some are designed to run inside the appserver.

      All of these tests have already been duplicated into the jboss-classloader
      project for the new classloader, so the issue is how we do the tests
      if we want to maintain support for the UCL.