update register interface to make it better, and the resolve with parameter more generic