Add work around if not all messages were consumed by ceilometer

If some ceilometer messages were lost we should set duration to 0ms.