Improved and fixed connection to XDS Server