Optimization of query data method

-for Tuskar-UI we don't need to fetch all the resources,
 but we can just limit them by query
-parametrized number of samples, due to ineffective mysql
 Ceilometer driver, we need to show less samples for charts

Change-Id: I9ce7dc5f832094296b3e243fd151ee4e9fed0a7d
Merge "Optimization of query data method"