org.broadleafcommerce.core.util
Class ThirdPartyInteractionLatencySimulationActivity

java.lang.Object
  extended by org.broadleafcommerce.core.workflow.BaseActivity<ProcessContext>
      extended by org.broadleafcommerce.core.util.ThirdPartyInteractionLatencySimulationActivity
All Implemented Interfaces:
Activity<ProcessContext>, org.springframework.beans.factory.Aware, org.springframework.beans.factory.BeanNameAware, org.springframework.core.Ordered

public class ThirdPartyInteractionLatencySimulationActivity
extends BaseActivity<ProcessContext>

Simple workflow activity to simulate an amount of latency introduced by communicating with a third party provider (e.g. credit card processing). Useful for load testing.

Author:
Jeff Fischer

Field Summary
 
Fields inherited from class org.broadleafcommerce.core.workflow.BaseActivity
automaticallyRegisterRollbackHandler, beanName, errorHandler, order, rollbackHandler, rollbackRegion, stateConfiguration
 
Fields inherited from interface org.springframework.core.Ordered
HIGHEST_PRECEDENCE, LOWEST_PRECEDENCE
 
Constructor Summary
ThirdPartyInteractionLatencySimulationActivity()
           
 
Method Summary
 ProcessContext execute(ProcessContext context)
          Called by the encompassing processor to activate the execution of the Activity
 long getWaitTime()
           
 void setWaitTime(long waitTime)
           
 
Methods inherited from class org.broadleafcommerce.core.workflow.BaseActivity
getAutomaticallyRegisterRollbackHandler, getBeanName, getErrorHandler, getOrder, getRollbackHandler, getRollbackRegion, getStateConfiguration, setAutomaticallyRegisterRollbackHandler, setBeanName, setErrorHandler, setOrder, setRollbackHandler, setRollbackRegion, setStateConfiguration, shouldExecute
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

ThirdPartyInteractionLatencySimulationActivity

public ThirdPartyInteractionLatencySimulationActivity()
Method Detail

execute

public ProcessContext execute(ProcessContext context)
                       throws Exception
Description copied from interface: Activity
Called by the encompassing processor to activate the execution of the Activity

Parameters:
context - - process context for this workflow
Returns:
resulting process context
Throws:
Exception

getWaitTime

public long getWaitTime()

setWaitTime

public void setWaitTime(long waitTime)


Copyright © 2013. All Rights Reserved.