void (@NotNull FilePath filePath, @Nullable VcsRevisionNumber startRevisionNumber, @NotNull VcsKey vcsKey, @NotNull VcsHistorySessionConsumer partner, boolean canUseCache) { try { if (startRevisionNumber == null) { partner = wrapPartnerToCachingPartner(vcsKey, filePath, partner); } VcsAbstractHistorySession cachedSession = null; VcsCacheableHistorySessionFactory<Serializable, VcsAbstractHistorySession> cacheableFactory = getCacheableFactory(); if (canUseCache && cacheableFactory != null) { cachedSession = getSessionFromCacheWithLastRevisionCheck(filePath, vcsKey, cacheableFactory); } if (cachedSession != null) { partner.reportCreatedEmptySession(cachedSession); } else if (myHistoryProvider instanceof VcsHistoryProviderEx) { ((VcsHistoryProviderEx)myHistoryProvider).reportAppendableHistory(filePath, startRevisionNumber, partner); } else { myHistoryProvider.reportAppendableHistory(filePath, partner); } partner.finished(); } catch (ProcessCanceledException e) { throw e; } catch (VcsFileHistoryLimitReachedException ignored) { partner.finished(); } catch (VcsException e) { partner.reportException(e); } catch (Throwable t) { partner.reportException(new VcsException(t)); } }