[Design of JBoss Labs] - Classpath Problem
by jthorn
After checking out and compiling jboss labs when I execute run.sh -c all I get several classpath errors. Has anybody else seen this and know of a solution?
11:28:49,510 ERROR [STDERR] org.jboss.aop.instrument.TransformationException: Failed to aspectize class org.jboss.forge.common.projects.Projects. Could not find class it references org.jboss.forge.common.projects.ProjectDescriptor It may not be in your classpath and you may not be getting field and constructor weaving for this class.
11:29:12,609 ERROR [STDERR] [warn] Could not find class org.jboss.shotoku.exceptions.RepositoryException that org.jboss.forge.portal.TitleChangeFilter references. It may not be in your classpath and you may not be getting field and constructor weaving for this class.
11:29:12,612 ERROR [STDERR] [warn] Could not find class org.jboss.shotoku.Node that org.jboss.forge.portal.TitleChangeFilter references. It may not be in your classpath and you may not be getting field and constructor weaving for this class.
11:29:12,618 ERROR [STDERR] [warn] Could not find class org.jboss.shotoku.exceptions.ResourceDoesNotExist that org.jboss.forge.portal.TitleChangeFilter references. It may not be in your classpath and you may not be getting field and constructor weaving for this class.
11:29:12,620 ERROR [STDERR] [warn] Could not find class org.jboss.shotoku.ContentManager that org.jboss.forge.portal.TitleChangeFilter references. It may not be in your classpath and you may not be getting field and constructor weaving for this class.
11:29:36,483 ERROR [STDERR] org.jboss.aop.instrument.TransformationException: Failed to aspectize class org.quartz.impl.StdSchedulerFactory. Could not find class it references org.quartz.utils.PoolingConnectionProvider It may not be in your classpath and you may not be getting field and constructor weaving for this class.
11:30:19,902 ERROR [STDERR] org.jboss.aop.instrument.TransformationException: Failed to aspectize class org.jbosslabs.portlets.primates.service.PrimatesServiceImpl. Could not find class it references org.jbosslabs.portlets.primates.PrimatesTools It may not be in your classpath and you may not be getting field and constructor weaving for this class.
11:30:27,738 ERROR [STDERR] org.jboss.aop.instrument.TransformationException: Failed to aspectize class org.springframework.aop.support.RegexpMethodPointcutAdvisor. Could not find class it references org.springframework.aop.support.Perl5RegexpMethodPointcut It may not be in your classpath and you may not be getting field and constructor weaving for this class.
11:30:30,046 ERROR [STDERR] [warn] Could not find class net.sf.cglib.asm.util.TraceClassVisitor that net.sf.cglib.core.DebuggingClassWriter$1 references. It may not be in your classpath and you may not be getting field and constructor weaving for this class.
11:30:31,778 ERROR [STDERR] org.jboss.aop.instrument.TransformationException: Failed to aspectize class org.quartz.impl.StdSchedulerFactory. Could not find class it references org.quartz.utils.PoolingConnectionProvider It may not be in your classpath and you may not be getting field and constructor weaving for this class.
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3999134#3999134
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3999134
19 years, 3 months
[Design the new POJO MicroContainer] - Re: Aspect integration to bootstrap classes
by scott.stark@jboss.org
Or do what Adrian did in the org.jboss.test.managed.mock.MockTest of the managed project:
| public void testMock() throws Exception
| {
| MockDataSourceManagedObject mock = new MockDataSourceManagedObject();
|
| ManagedObject mo = WrapperAdvice.wrapManagedObject(mock);
| ...
|
| package org.jboss.managed.plugins.advice;
|
| import java.util.Set;
|
| import org.jboss.aop.joinpoint.Invocation;
| import org.jboss.aop.proxy.container.AOPProxyFactoryParameters;
| import org.jboss.aop.proxy.container.GeneratedAOPProxyFactory;
| import org.jboss.logging.Logger;
| import org.jboss.managed.api.Fields;
| import org.jboss.managed.api.ManagedObject;
| import org.jboss.managed.api.ManagedProperty;
|
| /**
| * WrapperAdvice, intercepts methods that produce objects
| * that require proxies.
| *
| * @author <a href="adrian(a)jboss.com">Adrian Brock</a>
| * @version $Revision: 59258 $
| */
| public class WrapperAdvice
| {
| private static Logger log = Logger.getLogger(WrapperAdvice.class);
|
| /**
| * Wrap a managed object
| *
| * @param managedObject the managed object
| * @return the managed object wrapper
| */
| public static ManagedObject wrapManagedObject(ManagedObject managedObject)
| {
| return createProxy(managedObject, ManagedObject.class);
| }
|
| /**
| * Wrap a managed property
| *
| * @param managedProperty the managed property
| * @return the managed property wrapper
| */
| public static ManagedProperty wrapManagedProperty(ManagedProperty managedProperty)
| {
| return createProxy(managedProperty, ManagedProperty.class);
| }
|
| /**
| * Wrap fields
| *
| * @param fields the fields
| * @return the fields wrapper
| */
| public static Fields wrapFields(Fields fields)
| {
| return createProxy(fields, Fields.class);
| }
|
| /**
| * Wrap a returned managed object
| *
| * @param invocation the invocation
| * @return the wrapped managed object
| * @throws Throwable for any error
| */
| public ManagedObject wrapManagedObject(Invocation invocation) throws Throwable
| {
| ManagedObject result = (ManagedObject) invocation.invokeNext();
| return wrapManagedObject(result);
| }
|
| /**
| * Wrap a returned managed property
| *
| * @param invocation the invocation
| * @return the wrapped managed property
| * @throws Throwable for any error
| */
| public ManagedProperty wrapManagedProperty(Invocation invocation) throws Throwable
| {
| ManagedProperty result = (ManagedProperty) invocation.invokeNext();
| return wrapManagedProperty(result);
| }
|
| /**
| * Wrap a returned managed property set
| *
| * @param invocation the invocation
| * @return the wrapped managed property set
| * @throws Throwable for any error
| */
| @SuppressWarnings("unchecked")
| public Set<ManagedProperty> wrapManagedPropertySet(Invocation invocation) throws Throwable
| {
| Set<ManagedProperty> result = (Set<ManagedProperty>) invocation.invokeNext();
| return new WrapperSet<ManagedProperty>(result, ManagedProperty.class);
| }
|
| /**
| * Wrap fields
| *
| * @param invocation the invocation
| * @return the wrapped managed property
| * @throws Throwable for any error
| */
| public Fields wrapFields(Invocation invocation) throws Throwable
| {
| Fields result = (Fields) invocation.invokeNext();
| return wrapFields(result);
| }
|
| /**
| * Create a proxy
| *
| * @param <T> the expected type
| * @param target the target
| * @param interfaceClass the interface class
| * @return the proxy
| */
| static <T> T createProxy(T target, Class<T> interfaceClass)
| {
| if (target == null)
| return null;
|
| GeneratedAOPProxyFactory proxyFactory = new GeneratedAOPProxyFactory();
| AOPProxyFactoryParameters params = new AOPProxyFactoryParameters();
| params.setInterfaces(new Class[] { interfaceClass });
| params.setObjectAsSuperClass(true);
| params.setTarget(target);
| Object proxy = proxyFactory.createAdvisedProxy(params);
| if( log.isTraceEnabled() )
| log.trace("Created proxy: "+proxy.getClass()+"@"+System.identityHashCode(proxy)+" target: "+target.getClass());
| return interfaceClass.cast(proxy);
| }
| }
|
|
which uses the WrapperAdvice to bootstrap a aop proxy so that subsequent access to the ManagedProperty are proxied. This is what I was planning on using in the ManagedObjectBuilder that created the top-level MnagedObject of a deployment.
This works right?
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3999129#3999129
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3999129
19 years, 3 months
[Design of JBossCache] - Re: PojoCache uses a special node factory
by manik.surtani@jboss.com
"bstansberry(a)jboss.com" wrote : "manik.surtani(a)jboss.com" wrote :
| | This possibility always was there, even the way the NodeFactory was used before - and still is in JBC 1.x.y - as a Singleton. That's the whole purpose of a factory.
|
| I'm not sure how it can be done in 1.x, as NodeFactory doesn't expose any way to change the singleton.
You'd have to:
1) Subclass Node to add more specialised behaviour, maps, locks, etc. tuned for this (InternalNode?) Perhaps even add more specialised checks that "user" methods like get() and put() from the Node interface throw exceptions so end-users don't mess with these regions?
2) The factory would have to instantiate the appropriate class, based on the Fqn requested.
Changing the NodeFactory wouldn't help anyway, without 1) and 2) above, and wouldn't really add much specific benefit given how few InternalNodes would ever be created (just /_JBoss_Internal_ and /_BuddyBackup_? I don't think sub-nodes under /_JBoss_Internal_ and /_BuddyBackup_ needs any further special behaviour?)
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3999110#3999110
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3999110
19 years, 3 months