From 61b690698c949fb7c92607651f1c5e02971df966 Mon Sep 17 00:00:00 2001 From: ike-dai Date: Thu, 20 Feb 2014 19:40:43 +0900 Subject: [PATCH] fixed getting metric bug --- server/lib/deltacloud/drivers/ec2/ec2_driver.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/server/lib/deltacloud/drivers/ec2/ec2_driver.rb b/server/lib/deltacloud/drivers/ec2/ec2_driver.rb index cc3878a37..8581478f7 100644 --- a/server/lib/deltacloud/drivers/ec2/ec2_driver.rb +++ b/server/lib/deltacloud/drivers/ec2/ec2_driver.rb @@ -404,7 +404,7 @@ def metric(credentials, opts={}) end_time = Time.now.utc.iso8601.to_s m.properties.each do |p| p.values = cw.get_metric_statistics(p.name, ['Minimum', 'Maximum', 'Average'], - start_time, end_time, metric_unit_for(p.name), { m.entity => opts[:id]}) + start_time, end_time, metric_unit_for(p.name), {:dimensions => { m.entity => opts[:id]}}) end m end