Class: Lutaml::Model::Performance::Runner

Inherits:
Object
  • Object
show all
Defined in:
lib/tasks/performance_benchmark.rb

Overview

Benchmark runner

Instance Method Summary collapse

Constructor Details

#initialize(run_time: 5, warmup: 2) ⇒ Runner

Returns a new instance of Runner.



266
267
268
269
# File 'lib/tasks/performance_benchmark.rb', line 266

def initialize(run_time: 5, warmup: 2)
  @run_time = run_time
  @warmup = warmup
end

Instance Method Details

#run_allObject



271
272
273
274
275
276
277
278
279
280
281
282
283
284
# File 'lib/tasks/performance_benchmark.rb', line 271

def run_all
  puts "=" * 80
  puts "Lutaml::Model Comprehensive Performance Benchmarks"
  puts "=" * 80
  puts

  benchmark_model_creation
  benchmark_model_access
  benchmark_xml_parsing
  benchmark_xml_serialization
  benchmark_json_parsing
  benchmark_json_serialization
  benchmark_nested_operations
end