public ServiceInfo getService(String key) {
        ServiceInfo serviceInfo = serviceMap.get(key);
        
        if (serviceInfo == null) {
            serviceInfo = new ServiceInfo();
            serviceInfo.setName(key);
        }
        
        return serviceInfo;
    }
@Test
    void testRefreshFromEnabledToDisabled() throws InterruptedException, NoSuchFieldException, IllegalAccessException {
        // make sure the first no delay refresh thread finished.
        TimeUnit.MILLISECONDS.sleep(500);
        FailoverSwitch mockFailoverSwitch = new FailoverSwitch(false);
        when(failoverDataSource.getSwitch()).thenReturn(mockFailoverSwitch);
        Field failoverSwitchEnableField = FailoverReactor.class.getDeclaredField("failoverSwitchEnable");
        failoverSwitchEnableField.setAccessible(true);
        failoverSwitchEnableField.set(failoverReactor, true);
        Map<String, ServiceInfo> map = new HashMap<>();
        ServiceInfo serviceInfo = new ServiceInfo("a@@b");
        serviceInfo.addHost(new Instance());
        map.put("a@@b", serviceInfo);
        when(holder.getServiceInfoMap()).thenReturn(map);
        Field serviceMapField = FailoverReactor.class.getDeclaredField("serviceMap");
        serviceMapField.setAccessible(true);
        serviceMapField.set(failoverReactor, map);
        // waiting refresh thread work
        TimeUnit.MILLISECONDS.sleep(5500);
        ServiceInfo actual = failoverReactor.getService("a@@b");
        assertNotEquals(serviceInfo, actual);
    }