Java Code Examples for org.apache.kylin.common.persistence.ResourceStore#DATA_MODEL_DESC_RESOURCE_ROOT
The following examples show how to use
org.apache.kylin.common.persistence.ResourceStore#DATA_MODEL_DESC_RESOURCE_ROOT .
You can vote up the ones you like or vote down the ones you don't like,
and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example 1
Source File: DataModelManager.java From kylin-on-parquet-v2 with Apache License 2.0 | 6 votes |
protected void init(KylinConfig cfg) throws IOException { this.config = cfg; this.dataModelDescMap = new CaseInsensitiveStringCache<>(config, "data_model"); this.crud = new CachedCrudAssist<DataModelDesc>(getStore(), ResourceStore.DATA_MODEL_DESC_RESOURCE_ROOT, getDataModelImplClass(), dataModelDescMap) { @Override protected DataModelDesc initEntityAfterReload(DataModelDesc model, String resourceName) { String prj = (null == model.getProjectName() ? ProjectManager.getInstance(config).getProjectOfModel(model.getName()).getName() : model.getProjectName()); if (!model.isDraft()) { model.init(config, getAllTablesMap(prj)); } return model; } }; // touch lower level metadata before registering model listener TableMetadataManager.getInstance(config); crud.reloadAll(); Broadcaster.getInstance(config).registerListener(new DataModelSyncListener(), "data_model"); }
Example 2
Source File: DataModelManager.java From kylin with Apache License 2.0 | 6 votes |
protected void init(KylinConfig cfg) throws IOException { this.config = cfg; this.dataModelDescMap = new CaseInsensitiveStringCache<>(config, "data_model"); this.crud = new CachedCrudAssist<DataModelDesc>(getStore(), ResourceStore.DATA_MODEL_DESC_RESOURCE_ROOT, getDataModelImplClass(), dataModelDescMap) { @Override protected DataModelDesc initEntityAfterReload(DataModelDesc model, String resourceName) { String prj = (null == model.getProjectName() ? ProjectManager.getInstance(config).getProjectOfModel(model.getName()).getName() : model.getProjectName()); if (!model.isDraft()) { model.init(config, getAllTablesMap(prj)); } return model; } }; // touch lower level metadata before registering model listener TableMetadataManager.getInstance(config); crud.reloadAll(); Broadcaster.getInstance(config).registerListener(new DataModelSyncListener(), "data_model"); }
Example 3
Source File: DataModelDesc.java From kylin-on-parquet-v2 with Apache License 2.0 | 4 votes |
public static String concatResourcePath(String descName) { return ResourceStore.DATA_MODEL_DESC_RESOURCE_ROOT + "/" + descName + MetadataConstants.FILE_SURFIX; }
Example 4
Source File: DataModelDesc.java From kylin with Apache License 2.0 | 4 votes |
public static String concatResourcePath(String descName) { return ResourceStore.DATA_MODEL_DESC_RESOURCE_ROOT + "/" + descName + MetadataConstants.FILE_SURFIX; }
Example 5
Source File: DataModelDesc.java From Kylin with Apache License 2.0 | 4 votes |
public static String concatResourcePath(String descName) { return ResourceStore.DATA_MODEL_DESC_RESOURCE_ROOT + "/" + descName + MetadataConstants.FILE_SURFIX; }