org.apache.druid.query.Query.getContext()方法的使用及代码示例

x33g5p2x  于2022-01-28 转载在 其他  
字(2.8k)|赞(0)|评价(0)|浏览(131)

本文整理了Java中org.apache.druid.query.Query.getContext方法的一些代码示例,展示了Query.getContext的具体用法。这些代码示例主要来源于Github/Stackoverflow/Maven等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Query.getContext方法的具体详情如下:
包路径:org.apache.druid.query.Query
类名称:Query
方法名:getContext

Query.getContext介绍

暂无

代码示例

代码示例来源:origin: apache/incubator-druid

@Override
public Map<String, Object> getContext()
{
 return query.getContext();
}

代码示例来源:origin: apache/incubator-druid

@Override
public void context(QueryType query)
{
 try {
  setDimension(
    "context",
    jsonMapper.writeValueAsString(query.getContext() == null ? ImmutableMap.of() : query.getContext())
  );
 }
 catch (JsonProcessingException e) {
  throw new RuntimeException(e);
 }
}

代码示例来源:origin: apache/incubator-druid

@Nullable
final byte[] queryCacheKey = computeQueryCacheKey();
if (query.getContext().get(QueryResource.HEADER_IF_NONE_MATCH) != null) {
 @Nullable
 final String prevEtag = (String) query.getContext().get(QueryResource.HEADER_IF_NONE_MATCH);
 @Nullable
 final String currentEtag = computeCurrentEtag(segments, queryCacheKey);

代码示例来源:origin: apache/incubator-druid

MDC.put("descending", Boolean.toString(query.isDescending()));
if (setContextMDC) {
 final Iterable<Map.Entry<String, Object>> entries = query.getContext() == null
                           ? ImmutableList.of()
                           : query.getContext().entrySet();
 for (Map.Entry<String, Object> entry : entries) {
  MDC.put(entry.getKey(), entry.getValue() == null ? "NULL" : entry.getValue().toString());

代码示例来源:origin: apache/incubator-druid

if (((QueryDataSource) dataSource).getQuery().getContext() != null) {
 subqueryContext.putAll(((QueryDataSource) dataSource).getQuery().getContext());

代码示例来源:origin: org.apache.druid/druid-processing

@Override
public void context(QueryType query)
{
 try {
  setDimension(
    "context",
    jsonMapper.writeValueAsString(query.getContext() == null ? ImmutableMap.of() : query.getContext())
  );
 }
 catch (JsonProcessingException e) {
  throw new RuntimeException(e);
 }
}

代码示例来源:origin: org.apache.druid/druid-server

MDC.put("descending", Boolean.toString(query.isDescending()));
if (setContextMDC) {
 final Iterable<Map.Entry<String, Object>> entries = query.getContext() == null
                           ? ImmutableList.of()
                           : query.getContext().entrySet();
 for (Map.Entry<String, Object> entry : entries) {
  MDC.put(entry.getKey(), entry.getValue() == null ? "NULL" : entry.getValue().toString());

代码示例来源:origin: org.apache.druid/druid-server

@Nullable
final byte[] queryCacheKey = computeQueryCacheKey();
if (query.getContext().get(QueryResource.HEADER_IF_NONE_MATCH) != null) {
 @Nullable
 final String prevEtag = (String) query.getContext().get(QueryResource.HEADER_IF_NONE_MATCH);
 @Nullable
 final String currentEtag = computeCurrentEtag(segments, queryCacheKey);

代码示例来源:origin: org.apache.druid/druid-processing

if (((QueryDataSource) dataSource).getQuery().getContext() != null) {
 subqueryContext.putAll(((QueryDataSource) dataSource).getQuery().getContext());

相关文章