Factorization of client and server common interface