From a2097a5890c4d83005587b9ef2a7c017490d36df Mon Sep 17 00:00:00 2001 From: Jordan Sissel Date: Wed, 12 Sep 2012 10:41:38 -0700 Subject: [PATCH] make the date perf test smarter --- spec/filters/date_performance.rb | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/spec/filters/date_performance.rb b/spec/filters/date_performance.rb index 3f298552e..1bac0cc70 100644 --- a/spec/filters/date_performance.rb +++ b/spec/filters/date_performance.rb @@ -6,8 +6,10 @@ describe LogStash::Filters::Date do describe "performance test of java syntax parsing" do - event_count = 50000 - max_duration = 10 + event_count = 100000 + min_rate = 10000 + + max_duration = event_count / min_rate input = "Nov 24 01:29:01 -0800" config <<-CONFIG input { @@ -22,9 +24,11 @@ describe LogStash::Filters::Date do mydate => "MMM dd HH:mm:ss Z" } } + output { null { } } CONFIG agent do + puts "date parse rate: #{event_count / @duration}" insist { @duration } < max_duration end end