implement a basic meter, only draft version

Signed-off-by: Hui Wang <hui.wang@canonical.com>