public DistQueueConfig setup(Config cfg, String name, QueueStore<URLInfo> storeImplementation) { QueueConfig qConfig = new QueueConfig(); //TODO: Refactor the configuration entries qConfig.setName(name); qConfig.setBackupCount(1); if(storeImplementation != null) { QueueStoreConfig storeConfig = new QueueStoreConfig(); storeConfig.setStoreImplementation(storeImplementation); storeConfig.setProperty("memory-limit", "30"); qConfig.setQueueStoreConfig(storeConfig); //todo Refactor to Config } cfg.addQueueConfig(qConfig); return this; }