@Override
    protected IdentifiedDataSerializable getConfig() {
        UserCodeNamespaceConfig config = new UserCodeNamespaceConfig(parameters.name);
        parameters.resources.forEach(holder -> ConfigAccessor.add(config, holder));
        return config;
    }
@Test
    public void test() {
        UserCodeNamespaceConfig config = new UserCodeNamespaceConfig("my-namespace");

        AddUserCodeNamespaceConfigMessageTask task = createMessageTask(
                DynamicConfigAddUserCodeNamespaceConfigCodec.encodeRequest(config.getName(),
                        ConfigAccessor.getResourceDefinitions(config)
                                      .stream()
                                      .map(ResourceDefinitionHolder::new)
                                      .collect(Collectors.toList())));
        task.run();

        assertEquals(config, task.getConfig());
    }