StateConfig getStateConfig(Map<String, Object> topoConf) throws Exception {
        StateConfig stateConfig;
        String providerConfig;
        ObjectMapper mapper = new ObjectMapper();
        mapper.setVisibility(PropertyAccessor.FIELD, JsonAutoDetect.Visibility.ANY);
        if (topoConf.containsKey(Config.TOPOLOGY_STATE_PROVIDER_CONFIG)) {
            providerConfig = (String) topoConf.get(Config.TOPOLOGY_STATE_PROVIDER_CONFIG);
            stateConfig = mapper.readValue(providerConfig, StateConfig.class);
        } else {
            stateConfig = new StateConfig();
        }
        return stateConfig;
    }
@Test
    public void testgetDefaultConfig() throws Exception {

        RedisKeyValueStateProvider provider = new RedisKeyValueStateProvider();
        Map<String, Object> topoConf = new HashMap<>();
        //topoConf.put(Config.TOPOLOGY_STATE_PROVIDER_CONFIG, "{\"keyClass\":\"String\"}");
        RedisKeyValueStateProvider.StateConfig config = provider.getStateConfig(topoConf);
        assertNotNull(config);
    }