add tiid to metric, small fixes