[jboss-cvs] JBossAS SVN: r69653 - in trunk: system and 2 other directories.
jboss-cvs-commits at lists.jboss.org
jboss-cvs-commits at lists.jboss.org
Wed Feb 6 08:54:19 EST 2008
Author: kabir.khan at jboss.com
Date: 2008-02-06 08:54:19 -0500 (Wed, 06 Feb 2008)
New Revision: 69653
Added:
trunk/system/src/main/org/jboss/system/deployers/
trunk/system/src/main/org/jboss/system/deployers/TempBeanMetaDataDeployer.java
Modified:
trunk/server/src/etc/conf/default/bootstrap-beans.xml
trunk/system/.classpath
Log:
[JBAS-5215] Temporary fix: Set TCL and BeanMetaData classloader to the deployment classloader in TempBeanMetaDataDeployer
Modified: trunk/server/src/etc/conf/default/bootstrap-beans.xml
===================================================================
--- trunk/server/src/etc/conf/default/bootstrap-beans.xml 2008-02-06 13:51:44 UTC (rev 69652)
+++ trunk/server/src/etc/conf/default/bootstrap-beans.xml 2008-02-06 13:54:19 UTC (rev 69653)
@@ -255,7 +255,9 @@
<bean name="KernelDeploymentDeployer" class="org.jboss.deployers.vfs.deployer.kernel.KernelDeploymentDeployer">
<property name="type">beans</property>
</bean>
- <bean name="BeanMetaDataDeployer" class="org.jboss.deployers.vfs.deployer.kernel.BeanMetaDataDeployer">
+ <!-- FIXME: Put back to BeanMetaDataDeployer once JBMICROCONT-234 has been added to trunk -->
+ <bean name="BeanMetaDataDeployer" class="org.jboss.system.deployers.TempBeanMetaDataDeployer">
+ <!--bean name="BeanMetaDataDeployer" class="org.jboss.deployers.vfs.deployer.kernel.BeanMetaDataDeployer"-->
<constructor><parameter><inject bean="jboss.kernel:service=Kernel"/></parameter></constructor>
<property name="type">beans</property>
</bean>
Modified: trunk/system/.classpath
===================================================================
--- trunk/system/.classpath 2008-02-06 13:51:44 UTC (rev 69652)
+++ trunk/system/.classpath 2008-02-06 13:54:19 UTC (rev 69653)
@@ -34,5 +34,6 @@
<classpathentry combineaccessrules="false" kind="src" path="/bootstrap"/>
<classpathentry kind="lib" path="/thirdparty/jboss/microcontainer/lib/jboss-aop-mc-int.jar" sourcepath="/thirdparty/jboss/microcontainer/lib/jboss-aop-mc-int-sources.jar"/>
<classpathentry kind="lib" path="/thirdparty/trove/lib/trove.jar"/>
+ <classpathentry kind="lib" path="/thirdparty/jboss/microcontainer/lib/jboss-deployers-vfs.jar" sourcepath="/thirdparty/jboss/microcontainer/lib/jboss-deployers-vfs-sources.jar"/>
<classpathentry kind="output" path="output/eclipse-classes"/>
</classpath>
Added: trunk/system/src/main/org/jboss/system/deployers/TempBeanMetaDataDeployer.java
===================================================================
--- trunk/system/src/main/org/jboss/system/deployers/TempBeanMetaDataDeployer.java (rev 0)
+++ trunk/system/src/main/org/jboss/system/deployers/TempBeanMetaDataDeployer.java 2008-02-06 13:54:19 UTC (rev 69653)
@@ -0,0 +1,55 @@
+/*
+* JBoss, Home of Professional Open Source.
+* Copyright 2006, Red Hat Middleware LLC, and individual contributors
+* as indicated by the @author tags. See the copyright.txt file in the
+* distribution for a full listing of individual contributors.
+*
+* This is free software; you can redistribute it and/or modify it
+* under the terms of the GNU Lesser General Public License as
+* published by the Free Software Foundation; either version 2.1 of
+* the License, or (at your option) any later version.
+*
+* This software is distributed in the hope that it will be useful,
+* but WITHOUT ANY WARRANTY; without even the implied warranty of
+* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+* Lesser General Public License for more details.
+*
+* You should have received a copy of the GNU Lesser General Public
+* License along with this software; if not, write to the Free
+* Software Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA
+* 02110-1301 USA, or see the FSF site: http://www.fsf.org.
+*/
+package org.jboss.system.deployers;
+
+import org.jboss.beans.metadata.spi.BeanMetaData;
+import org.jboss.deployers.spi.DeploymentException;
+import org.jboss.deployers.structure.spi.DeploymentUnit;
+import org.jboss.deployers.vfs.deployer.kernel.BeanMetaDataDeployer;
+import org.jboss.kernel.Kernel;
+
+/**
+ *
+ * @author <a href="kabir.khan at jboss.com">Kabir Khan</a>
+ * @version $Revision: 1.1 $
+ */
+public class TempBeanMetaDataDeployer extends BeanMetaDataDeployer
+{
+ public TempBeanMetaDataDeployer(Kernel kernel)
+ {
+ super(kernel);
+ }
+
+ public void deploy(DeploymentUnit unit, BeanMetaData deployment) throws DeploymentException
+ {
+ ClassLoader old = Thread.currentThread().getContextClassLoader();
+ Thread.currentThread().setContextClassLoader(unit.getClassLoader());
+ try
+ {
+ super.deploy(unit, deployment);
+ }
+ finally
+ {
+ Thread.currentThread().setContextClassLoader(old);
+ }
+ }
+}
More information about the jboss-cvs-commits
mailing list