25d42dd5f4
Move ChangeCache implementation binding from GerritGlobalModule to new ChangeCacheImplModule. This is so that GerritGlobalModule no longer assumes a SearchingChangeCacheImpl. This was preventing slave gerrit servers from binding a ScanningChangeCacheImpl instead, as they do not rely on searching (an index); scanning, rather, relies on the git repo. Add new ChangeCacheImplModule usage to Daemon, so the latter can tell the former about gerrit server running as a slave or not. ChangeCacheImplModule can then install either the ScanningChangeCacheImpl or SearchingChangeCacheImpl module, which binds the corresponding ChangeCache implementation. Adapt InMemoryModule and WebAppInitializer accordingly. Fix ScanningChangeCacheImpl logger initialization. The Daemon non-slave case is already covered by existing IT testing. The slave case (involving a new branch in ChangeCacheImplModule) has to be tested manually; below bug/issue has a scenario. Now, ScanningChangeCacheImpl is already covered by IT. And, that slave case is exercised each time a slave gerrit server runs. InMemoryModule is exercised by existing unit testing; WebAppInitializer is used by web.xml. In both cases, the existing behavior was kept in the code. Bug: Issue 3323 Change-Id: Idfa255a5ef754979ca8289ae178e022c1e94be97 |
||
---|---|---|
.. | ||
src | ||
BUCK |