use of org.apache.ofbiz.service.config.model.ServiceGroups in project ofbiz-framework by apache.
the class ServiceGroupReader method readConfig.
public static void readConfig() {
List<ServiceGroups> serviceGroupsList = null;
try {
serviceGroupsList = ServiceConfigUtil.getServiceEngine().getServiceGroups();
} catch (GenericConfigException e) {
// FIXME: Refactor API so exceptions can be thrown and caught.
Debug.logError(e, module);
throw new RuntimeException(e.getMessage());
}
for (ServiceGroups serviceGroup : serviceGroupsList) {
ResourceHandler handler = new MainResourceHandler(ServiceConfigUtil.getServiceEngineXmlFileName(), serviceGroup.getLoader(), serviceGroup.getLocation());
addGroupDefinitions(handler);
}
// get all of the component resource group stuff, ie specified in each ofbiz-component.xml file
for (ComponentConfig.ServiceResourceInfo componentResourceInfo : ComponentConfig.getAllServiceResourceInfos("group")) {
addGroupDefinitions(componentResourceInfo.createResourceHandler());
}
}
Aggregations