Java Code Examples for org.apache.kylin.common.persistence.ResourceStore#CUBE_RESOURCE_ROOT

The following examples show how to use org.apache.kylin.common.persistence.ResourceStore#CUBE_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: CubeManager.java    From kylin-on-parquet-v2 with Apache License 2.0 6 votes vote down vote up
private CubeManager(KylinConfig cfg) throws IOException {
    logger.info("Initializing CubeManager with config {}", cfg);
    this.config = cfg;
    this.cubeMap = new CaseInsensitiveStringCache<CubeInstance>(config, "cube");
    this.crud = new CachedCrudAssist<CubeInstance>(getStore(), ResourceStore.CUBE_RESOURCE_ROOT, CubeInstance.class,
            cubeMap) {
        @Override
        protected CubeInstance initEntityAfterReload(CubeInstance cube, String resourceName) {
            cube.init(config);

            for (CubeSegment segment : cube.getSegments()) {
                usedStorageLocation.put(segment.getUuid(), segment.getStorageLocationIdentifier());
            }
            return cube;
        }
    };
    this.crud.setCheckCopyOnWrite(true);

    // touch lower level metadata before registering my listener
    crud.reloadAll();
    Broadcaster.getInstance(config).registerListener(new CubeSyncListener(), "cube");
}
 
Example 2
Source File: CubeManager.java    From kylin with Apache License 2.0 6 votes vote down vote up
private CubeManager(KylinConfig cfg) throws IOException {
    logger.info("Initializing CubeManager with config {}", cfg);
    this.config = cfg;
    this.cubeMap = new CaseInsensitiveStringCache<>(config, "cube");
    this.crud = new CachedCrudAssist<CubeInstance>(getStore(), ResourceStore.CUBE_RESOURCE_ROOT, CubeInstance.class,
            cubeMap) {
        @Override
        protected CubeInstance initEntityAfterReload(CubeInstance cube, String resourceName) {
            cube.init(config);

            for (CubeSegment segment : cube.getSegments()) {
                usedStorageLocation.put(segment.getUuid(), segment.getStorageLocationIdentifier());
            }
            return cube;
        }
    };
    this.crud.setCheckCopyOnWrite(true);

    // touch lower level metadata before registering my listener
    crud.reloadAll();
    Broadcaster.getInstance(config).registerListener(new CubeSyncListener(), "cube");
}
 
Example 3
Source File: CubeInstance.java    From kylin-on-parquet-v2 with Apache License 2.0 4 votes vote down vote up
public static String concatResourcePath(String cubeName) {
    return ResourceStore.CUBE_RESOURCE_ROOT + "/" + cubeName + ".json";
}
 
Example 4
Source File: CubeInstance.java    From kylin with Apache License 2.0 4 votes vote down vote up
public static String concatResourcePath(String cubeName) {
    return ResourceStore.CUBE_RESOURCE_ROOT + "/" + cubeName + ".json";
}
 
Example 5
Source File: CubeInstance.java    From Kylin with Apache License 2.0 4 votes vote down vote up
public static String concatResourcePath(String cubeName) {
    return ResourceStore.CUBE_RESOURCE_ROOT + "/" + cubeName + ".json";
}
 
Example 6
Source File: CubeInstance.java    From Kylin with Apache License 2.0 4 votes vote down vote up
public static String concatResourcePath(String cubeName) {
    return ResourceStore.CUBE_RESOURCE_ROOT + "/" + cubeName + ".json";
}