10-30-2014 05:36 AM
<bean id="aspectLogger" class="com.kaunas.PerformanceAspect"/>
<aop:config>
<aop:pointcut id="pointcutLog" expression="@annotation(com.kaunas.AspectAdvice)"/>
<aop:aspect id="aopAspect" ref="aspectLogger" order="1">
<aop:around pointcut-ref="pointcutLog" method="logPerformance"/>
</aop:aspect>
</aop:config>
org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'applicationEventMulticaster' defined in class path resource [alfresco/core-services-context.xml]: BeanPostProcessor before instantiation of bean failed; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'crossRepositoryCopyServiceWriteTxnAdvisor' defined in class path resource [alfresco/public-services-context.xml]: Cannot resolve reference to bean 'retryingWriteTxnAdvice' while setting bean property 'advice'; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'retryingWriteTxnAdvice' defined in class path resource [alfresco/core-services-context.xml]: Cannot resolve reference to bean 'retryingTransactionHelper' while setting bean property 'txnHelper'; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'retryingTransactionHelper' defined in class path resource [alfresco/core-services-context.xml]: Cannot resolve reference to bean 'transactionService' while setting bean property 'transactionService'; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'transactionService' defined in class path resource [alfresco/core-services-context.xml]: Cannot resolve reference to bean 'transactionManager' while setting bean property 'transactionManager'; nested exception is org.springframework.beans.factory.BeanCreationException: Error creating bean with name 'transactionManager' defined in class path resource [alfresco/hibernate-context.xml]: Initialization of bean failed; nested exception is org.alfresco.error.AlfrescoRuntimeException: 09300000 A transaction has not be started for method 'isSingleton' on org.springframework.beans.factory.FactoryBean
10-30-2014 06:31 AM
10-30-2014 06:53 AM
02-12-2015 03:46 PM
07-16-2015 02:38 PM
<bean id="timingLogger" class="org.springframework.aop.interceptor.PerformanceMonitorInterceptor"/>
<bean id="timingAdvisor" class="org.springframework.aop.support.RegexpMethodPointcutAdvisor">
<property name="advice" ref="timingLogger"/>
<property name="patterns">
<list>
<value>.*</value>
</list>
</property>
</bean>
</bean>
<bean id="WorkflowService" class="org.springframework.aop.framework.ProxyFactoryBean">
<property name="proxyInterfaces">
<value>org.alfresco.service.cmr.workflow.WorkflowService</value>
</property>
<property name="target">
<ref bean="workflowServiceImpl"/>
</property>
<property name="interceptorNames">
<list>
<idref bean="WorkflowService_transaction"/>
<idref bean="AuditMethodInterceptor"/>
<idref bean="exceptionTranslator"/>
<idref bean="WorkflowService_security"/>
<idref bean="timingAdvisor"/>
</list>
</property>
</bean>
package foo.tools.monitor;
import org.aopalliance.intercept.MethodInterceptor;
import org.aopalliance.intercept.MethodInvocation;
import org.apache.log4j.Logger;
import org.springframework.aop.framework.Advised;
import org.springframework.beans.BeansException;
import org.springframework.beans.factory.BeanFactory;
import org.springframework.beans.factory.BeanFactoryAware;
import org.springframework.util.StopWatch;
public class CaptureExecutionTime implements MethodInterceptor, BeanFactoryAware{
private static final Logger log = Logger.getLogger(CaptureExecutionTime.class);
private static final String WORKFLOW_SERVICE = "WorkflowService";
@Override
public void setBeanFactory(BeanFactory beanFactory) throws BeansException
{
if(beanFactory.containsBean(WORKFLOW_SERVICE))
{
Advised proxy = (Advised) beanFactory.getBean(WORKFLOW_SERVICE);
proxy.addAdvice(this);
}
}
@Override
public Object invoke(MethodInvocation i) throws Throwable {
final StopWatch stopWatch = new StopWatch();
stopWatch.start("Method: "+i.getMethod().getName() +" :: Is called on: "+ i.getThis());
try{
return i.proceed();
}finally {
stopWatch.stop();
System.out.println(stopWatch.prettyPrint());
}
}
}
<bean id="profile_monitor" class="us.co.denver.tools.monitor.CaptureExecutionTime" >
</bean>
07-16-2015 05:15 PM
<bean id="WorkflowService" class="org.springframework.aop.framework.ProxyFactoryBean">
<property name="proxyInterfaces">
<value>org.alfresco.service.cmr.workflow.WorkflowService</value>
</property>
<property name="target">
<ref bean="workflowServiceImpl"/>
</property>
<property name="interceptorNames">
<list>
<idref bean="WorkflowService_transaction"/>
<idref bean="AuditMethodInterceptor"/>
<idref bean="exceptionTranslator"/>
<idref bean="WorkflowService_security"/>
<idref bean="timingAdvisor"/>
</list>
</property>
</bean>
07-17-2015 06:28 PM
<bean id="jbpm_template" class="org.springframework.aop.framework.ProxyFactoryBean">
<!– <property name="proxyInterfaces"> –>
<!– <value>org.springmodules.workflow.jbpm31.JbpmTemplate</value> –>
<!– </property> –>
<property name="proxyTargetClass">
<value>true</value>
</property>
<property name="target"><ref bean="jbpm_template_Trans_Target"/></property>
<property name="interceptorNames">
<list>
<value>profile_monitor</value>
</list>
</property>
</bean>
<bean id="jbpm_template_Trans_Target"
class="org.alfresco.repo.workflow.jbpm.JBPMTransactionTemplate">
<constructor-arg index="0" ref="jbpm_configuration" />
</bean>
Tags
Find what you came for
We want to make your experience in Hyland Connect as valuable as possible, so we put together some helpful links.