org.teiid.translator.ExecutionContext.getRequestId()方法的使用及代码示例

x33g5p2x  于2022-01-19 转载在 其他  
字(3.9k)|赞(0)|评价(0)|浏览(108)

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

ExecutionContext.getRequestId介绍

[英]Get the identifier for the command being executed. This can be correlated back to identifiers exposed in other parts of the system. shortcut for #getCommandContext().getRequestId()
[中]获取正在执行的命令的标识符。这可以关联回系统其他部分中公开的标识符。#getCommandContext()的快捷方式。getRequestId()

代码示例

代码示例来源:origin: org.teiid.connectors/translator-jdbc

protected void setSizeContraints(Statement statement) {
  try {
    executionFactory.setFetchSize(command, context, statement, fetchSize);
  } catch (SQLException e) {
    if (LogManager.isMessageToBeRecorded(LogConstants.CTX_CONNECTOR, MessageLevel.DETAIL)) {
      LogManager.logDetail(LogConstants.CTX_CONNECTOR, context.getRequestId(), " could not set fetch size: ", fetchSize); //$NON-NLS-1$
    }
  }
}

代码示例来源:origin: org.teiid.connectors/translator-salesforce

public QueryExecutionImpl(QueryExpression command, SalesforceConnection connection, RuntimeMetadata metadata, ExecutionContext context, SalesForceExecutionFactory salesForceExecutionFactory) {
  this.connection = connection;
  this.metadata = metadata;
  this.context = context;
  this.query = command;
  this.executionFactory = salesForceExecutionFactory;
  connectionIdentifier = context.getConnectionId();
  connectorIdentifier = context.getConnectorIdentifier();
  requestIdentifier = context.getRequestId();
  partIdentifier = context.getPartIdentifier();
}

代码示例来源:origin: org.teiid/teiid-engine

public boolean equals(Object obj) {
  if(obj == this) {
    return true;
  } 
  if(! (obj instanceof ExecutionContext)) {
    return false;
  } 
  ExecutionContext other = (ExecutionContext) obj;
  return EquivalenceUtil.areEqual(this.getRequestId(), other.getRequestId()) && 
  EquivalenceUtil.areEqual(this.getPartIdentifier(), other.getPartIdentifier());
}

代码示例来源:origin: teiid/teiid

public boolean equals(Object obj) {
  if(obj == this) {
    return true;
  } 
  if(! (obj instanceof ExecutionContext)) {
    return false;
  } 
  ExecutionContext other = (ExecutionContext) obj;
  return EquivalenceUtil.areEqual(this.getRequestId(), other.getRequestId()) && 
  EquivalenceUtil.areEqual(this.getPartIdentifier(), other.getPartIdentifier());
}

代码示例来源:origin: org.jboss.teiid/teiid-engine

public boolean equals(Object obj) {
  if(obj == this) {
    return true;
  } 
  if(! (obj instanceof ExecutionContext)) {
    return false;
  } 
  ExecutionContext other = (ExecutionContext) obj;
  return EquivalenceUtil.areEqual(this.getRequestId(), other.getRequestId()) && 
  EquivalenceUtil.areEqual(this.getPartIdentifier(), other.getPartIdentifier());
}

代码示例来源:origin: org.teiid.connectors/translator-jdbc

/**
 * Returns the source comment for the given command
 * @param context
 * @param command
 * @return the comment
 */
public String getSourceComment(ExecutionContext context, Command command) {
  if (addSourceComment() && context != null) {
    return comment.get().format(new Object[] {context.getConnectionId(), context.getRequestId(), context.getPartIdentifier(), 
        context.getExecutionCountIdentifier(), context.getSession().getUserName(), context.getVdbName(), context.getVdbVersion(), context.isTransactional() });
  }
  return ""; //$NON-NLS-1$ 
}

代码示例来源:origin: org.teiid.connectors/translator-jdbc

public void addStatementWarnings() throws SQLException {
    SQLWarning warning = this.statement.getWarnings();
    if (warning != null) {
      context.addWarning(warning);
      if (LogManager.isMessageToBeRecorded(LogConstants.CTX_CONNECTOR, MessageLevel.DETAIL)) {
        while (warning != null) {
          LogManager.logDetail(LogConstants.CTX_CONNECTOR, context.getRequestId() + " Warning: ", warning); //$NON-NLS-1$
          warning = warning.getNextWarning();
        }
      }
    }
    this.statement.clearWarnings();
  }
}

代码示例来源:origin: teiid/teiid

public FakeExecutionContextImpl(ExecutionContext c) {
  super(c.getVdbName(), c.getVdbVersion(), c.getCommandPayload(), c
      .getConnectionId(), c.getConnectorIdentifier(), Long.valueOf(c
      .getRequestId()), c.getPartIdentifier(), c
      .getExecutionCountIdentifier());
}

相关文章