use orientdb entity session when possible