implement register_server

Signed-off-by: you <ylcaa@foxmail.com>