1
2
3
4
5
6
7
8
9
10
11
12
13 package com.eviware.soapui.model.testsuite;
14
15 /***
16 * Runner for loadtests
17 *
18 * @author Ole.Matzura
19 */
20
21 public interface LoadTestRunner
22 {
23 /***
24 * Gets the number of threads currently running
25 */
26
27 public int getRunningThreadCount();
28
29 public LoadTest getLoadTest();
30
31 /***
32 * Cancels the loadtest with the specified reason. This should be used for "normal" cancellations,
33 * ie from a ui or some expected signal.
34 *
35 * @param reason
36 */
37
38 public void cancel( String reason );
39
40 /***
41 * Fails the loadtest with the specified reason. This should be used for error conditions
42 */
43
44 public void fail( String reason );
45
46 /***
47 * Gets the current status of this runner
48 */
49
50 public Status getStatus();
51
52 public enum Status { INITIALIZED, RUNNING, CANCELED, FINISHED, FAILED }
53
54 /***
55 * Returns the progress of the loadtest as a value between 0 and 1. Progress is measured depending
56 * on the LoadTest limit configuration
57 */
58
59 public float getProgress();
60
61 /***
62 * Gets the reason why a loadtest was cancelled or failed
63 */
64
65 public String getReason();
66
67 /***
68 * Gets the time taken for this loadtest
69 */
70 public long getTimeTaken();
71 }