change retrieve_id_by_some method using decorator

Signed-off-by: Kouhei Maeda <mkouhei@palmtb.net>