private ExecutingQuery Query(ClientConnectionInfo sessionInfo, string username, string queryText, IDictionary <string, object> @params, IDictionary <string, object> metaData) { Thread thread = Thread.CurrentThread; return(new ExecutingQuery(_queryId++, sessionInfo.WithUsername(username), username, queryText, ValueUtils.asMapValue(@params), metaData, () => 0, new PageCursorCountersAnonymousInnerClass(this) , thread.Id, thread.Name, _clock, CpuClock, HeapAllocation)); }
public override Neo4jTransactionalContext NewContext(ClientConnectionInfo clientConnection, InternalTransaction tx, string queryText, MapValue queryParameters) { Statement initialStatement = _statementSupplier.get(); ClientConnectionInfo connectionWithUserName = clientConnection.WithUsername(tx.SecurityContext().subject().username()); ExecutingQuery executingQuery = initialStatement.QueryRegistration().startQueryExecution(connectionWithUserName, queryText, queryParameters); return(_contextCreator.create(tx, initialStatement, executingQuery)); }
private string SessionConnectionDetails(ClientConnectionInfo sessionInfo, string username) { return(sessionInfo.WithUsername(username).asConnectionDetails()); }