本文整理了Java中org.apache.kylin.common.QueryContextFacade.current
方法的一些代码示例,展示了QueryContextFacade.current
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。QueryContextFacade.current
方法的具体详情如下:
包路径:org.apache.kylin.common.QueryContextFacade
类名称:QueryContextFacade
方法名:current
暂无
代码示例来源:origin: apache/kylin
public CubeHBaseRPC(ISegment segment, Cuboid cuboid, GTInfo fullGTInfo, StorageContext context) {
Preconditions.checkArgument(segment instanceof CubeSegment, "segment must be CubeSegment");
this.cubeSeg = (CubeSegment) segment;
this.cuboid = cuboid;
this.fullGTInfo = fullGTInfo;
this.queryContext = QueryContextFacade.current();
this.storageContext = context;
this.fuzzyKeyEncoder = new FuzzyKeyEncoder(cubeSeg, cuboid);
this.fuzzyMaskEncoder = new FuzzyMaskEncoder(cubeSeg, cuboid);
}
代码示例来源:origin: apache/kylin
@Override
public ITuple next() {
if (scanCount++ % 100 == 1) {
QueryContextFacade.current().checkMillisBeforeDeadline();
}
if (++scanCountDelta >= 1000) {
flushScanCountDelta();
}
return tupleIterator.next();
}
代码示例来源:origin: apache/kylin
public OLAPQuery(DataContext optiqContext, EnumeratorTypeEnum type, int ctxId) {
this.optiqContext = optiqContext;
this.type = type;
this.contextId = ctxId;
QueryContextFacade.current().addContext(ctxId, type.toString(),
type == EnumeratorTypeEnum.OLAP);
}
代码示例来源:origin: apache/kylin
StringBuilder cubeSb = new StringBuilder();
StringBuilder logSb = new StringBuilder("Processed rows for each storageContext: ");
QueryContext queryContext = QueryContextFacade.current();
if (OLAPContext.getThreadLocalContexts() != null) { // contexts can be null in case of 'explain plan for'
for (OLAPContext ctx : OLAPContext.getThreadLocalContexts()) {
代码示例来源:origin: apache/kylin
QueryContextFacade.current().checkMillisBeforeDeadline();
代码示例来源:origin: apache/kylin
System.out.println("EXECUTION PLAN AFTER REWRITE");
System.out.println(dumpPlan);
QueryContextFacade.current().setCalcitePlan(this.copy(getTraitSet(), getInputs()));
代码示例来源:origin: apache/kylin
conn = QueryConnection.getConnection(sqlRequest.getProject());
String userInfo = SecurityContextHolder.getContext().getAuthentication().getName();
QueryContext context = QueryContextFacade.current();
context.setUsername(userInfo);
context.setGroups(AclPermissionUtil.getCurrentUserGroups());
代码示例来源:origin: apache/kylin
BackdoorToggles.addToggles(sqlRequest.getBackdoorToggles());
final QueryContext queryContext = QueryContextFacade.current();
代码示例来源:origin: apache/kylin
private SQLResponse queryAndUpdateCache(SQLRequest sqlRequest, boolean queryCacheEnabled) {
KylinConfig kylinConfig = KylinConfig.getInstanceFromEnv();
Message msg = MsgPicker.getMsg();
final QueryContext queryContext = QueryContextFacade.current();
代码示例来源:origin: apache/kylin
user = "unknown";
for (QueryContext.RPCStatistics entry : QueryContextFacade.current().getRpcStatisticsList()) {
RecordEvent rpcMetricsEvent = new TimedRecordEvent(
KylinConfig.getInstanceFromEnv().getKylinMetricsSubjectQueryRpcCall());
代码示例来源:origin: org.apache.kylin/kylin-storage-hbase
public CubeHBaseRPC(ISegment segment, Cuboid cuboid, GTInfo fullGTInfo, StorageContext context) {
Preconditions.checkArgument(segment instanceof CubeSegment, "segment must be CubeSegment");
this.cubeSeg = (CubeSegment) segment;
this.cuboid = cuboid;
this.fullGTInfo = fullGTInfo;
this.queryContext = QueryContextFacade.current();
this.storageContext = context;
this.fuzzyKeyEncoder = new FuzzyKeyEncoder(cubeSeg, cuboid);
this.fuzzyMaskEncoder = new FuzzyMaskEncoder(cubeSeg, cuboid);
}
代码示例来源:origin: org.apache.kylin/kylin-core-storage
@Override
public ITuple next() {
if (scanCount++ % 100 == 1) {
QueryContextFacade.current().checkMillisBeforeDeadline();
}
if (++scanCountDelta >= 1000) {
flushScanCountDelta();
}
return tupleIterator.next();
}
代码示例来源:origin: org.apache.kylin/kylin-query
public OLAPQuery(DataContext optiqContext, EnumeratorTypeEnum type, int ctxId) {
this.optiqContext = optiqContext;
this.type = type;
this.contextId = ctxId;
QueryContextFacade.current().addContext(ctxId, type.toString(),
type == EnumeratorTypeEnum.OLAP);
}
代码示例来源:origin: org.apache.kylin/kylin-core-storage
QueryContextFacade.current().checkMillisBeforeDeadline();
代码示例来源:origin: org.apache.kylin/kylin-query
System.out.println("EXECUTION PLAN AFTER REWRITE");
System.out.println(dumpPlan);
QueryContextFacade.current().setCalcitePlan(this.copy(getTraitSet(), getInputs()));
内容来源于网络,如有侵权,请联系作者删除!