~viswesn/juju-ci-tools/aws_boto3

« back to all changes in this revision

Viewing changes to generate_perfscale_results.py

Perfscale tests are now passed pprof objects.

Show diffs side-by-side

added added

removed removed

Lines of Context:
29
29
    breakdown_log_by_timeframes,
30
30
)
31
31
import perf_graphing
 
32
from pprof_collector import PPROFCollector
32
33
from utility import add_basic_testing_arguments
33
34
 
34
35
 
128
129
    Run the callable `target_test` and collect timing data and system metrics
129
130
    for the controller during the test run.
130
131
 
131
 
    :param target_test: A callable that takes 2 arguments:
 
132
    :param target_test: A callable that takes 3 arguments:
132
133
        - ModelClient client object  (bootstrapped)
 
134
        - PPROFCollector object
133
135
        - argparse args object
134
136
      This callable must return a `DeployDetails` object.
135
137
 
158
160
 
159
161
            machine_ids = setup_system_monitoring(admin_client)
160
162
 
161
 
            deploy_details = target_test(client, args)
 
163
            pprof_collector = PPROFCollector(
 
164
                admin_client,
 
165
                machine_ids[0],
 
166
                bs_manager.log_dir,
 
167
                args.enable_pprof)
 
168
            deploy_details = target_test(client, pprof_collector, args)
162
169
        finally:
163
170
            results_dir = dump_performance_metrics_logs(
164
171
                bs_manager.log_dir, admin_client, machine_ids)