s3-librpc: move server_id marshalling to own helper file.