Apache JMeter

org.apache.jmeter.samplers
Class RemoteSampleListenerImpl

java.lang.Object
  extended by java.rmi.server.RemoteObject
      extended by java.rmi.server.RemoteServer
          extended by java.rmi.server.UnicastRemoteObject
              extended by org.apache.jmeter.samplers.RemoteSampleListenerImpl
All Implemented Interfaces:
Serializable, Remote, RemoteSampleListener, SampleListener, TestStateListener

public class RemoteSampleListenerImpl
extends UnicastRemoteObject
implements RemoteSampleListener, SampleListener, TestStateListener

Implementation of remote sampler listener, also supports TestStateListener

See Also:
Serialized Form

Field Summary
 
Fields inherited from class java.rmi.server.RemoteObject
ref
 
Constructor Summary
RemoteSampleListenerImpl(Object listener)
           
 
Method Summary
 void processBatch(List<SampleEvent> samples)
          This method is called remotely and fires a list of samples events received locally.
 void sampleOccurred(SampleEvent e)
          A sample has started and stopped.
 void sampleStarted(SampleEvent e)
          A sample has started.
 void sampleStopped(SampleEvent e)
          A sample has stopped.
 void testEnded()
           Called once for all threads after the end of a test.
 void testEnded(String host)
           Called once for all threads after the end of a test.
 void testStarted()
           Called just before the start of the test from the main engine thread.
 void testStarted(String host)
           Called just before the start of the test from the main engine thread.
 
Methods inherited from class java.rmi.server.UnicastRemoteObject
clone, exportObject, exportObject, exportObject, unexportObject
 
Methods inherited from class java.rmi.server.RemoteServer
getClientHost, getLog, setLog
 
Methods inherited from class java.rmi.server.RemoteObject
equals, getRef, hashCode, toString, toStub
 
Methods inherited from class java.lang.Object
finalize, getClass, notify, notifyAll, wait, wait, wait
 

Constructor Detail

RemoteSampleListenerImpl

public RemoteSampleListenerImpl(Object listener)
                         throws RemoteException
Throws:
RemoteException
Method Detail

testStarted

public void testStarted()
Description copied from interface: TestStateListener

Called just before the start of the test from the main engine thread. This is before the test elements are cloned. Note that not all the test variables will have been set up at this point.

N.B. testStarted() and testEnded() are called from different threads.

Specified by:
testStarted in interface RemoteSampleListener
Specified by:
testStarted in interface TestStateListener
See Also:
StandardJMeterEngine.run()

testStarted

public void testStarted(String host)
Description copied from interface: TestStateListener

Called just before the start of the test from the main engine thread. This is before the test elements are cloned. Note that not all the test variables will have been set up at this point.

N.B. testStarted() and testEnded() are called from different threads.

Specified by:
testStarted in interface RemoteSampleListener
Specified by:
testStarted in interface TestStateListener
Parameters:
host - name of host
See Also:
StandardJMeterEngine.run()

testEnded

public void testEnded()
Description copied from interface: TestStateListener

Called once for all threads after the end of a test. This will use the same element instances as at the start of the test.

N.B. testStarted() and testEnded() are called from different threads.

Specified by:
testEnded in interface RemoteSampleListener
Specified by:
testEnded in interface TestStateListener
See Also:
StandardJMeterEngine.stopTest()

testEnded

public void testEnded(String host)
Description copied from interface: TestStateListener

Called once for all threads after the end of a test. This will use the same element instances as at the start of the test.

N.B. testStarted() and testEnded() are called from different threads.

Specified by:
testEnded in interface RemoteSampleListener
Specified by:
testEnded in interface TestStateListener
Parameters:
host - name of host
See Also:
StandardJMeterEngine.stopTest()

processBatch

public void processBatch(List<SampleEvent> samples)
This method is called remotely and fires a list of samples events received locally. The function is to reduce network load when using remote testing.

Specified by:
processBatch in interface RemoteSampleListener
Parameters:
samples - the list of sample events to be fired locally

sampleOccurred

public void sampleOccurred(SampleEvent e)
Description copied from interface: RemoteSampleListener
A sample has started and stopped.

Specified by:
sampleOccurred in interface RemoteSampleListener
Specified by:
sampleOccurred in interface SampleListener

sampleStarted

public void sampleStarted(SampleEvent e)
A sample has started.

Specified by:
sampleStarted in interface RemoteSampleListener
Specified by:
sampleStarted in interface SampleListener

sampleStopped

public void sampleStopped(SampleEvent e)
A sample has stopped.

Specified by:
sampleStopped in interface RemoteSampleListener
Specified by:
sampleStopped in interface SampleListener

Apache JMeter

Copyright © 1998-2013 Apache Software Foundation. All Rights Reserved.