Use change notes instead of index lookup when possible

Don't perform index lookup for change notes creation, as it is readily
available in ChangeData for has:a_depends-on operand. This change
improves the performance of "change:<> has:a_depends-on" by 2ms against
ES index backend (i.e. on avg took 16ms before and 14ms after this
change over 50 samples).

Change-Id: I404fea1ebc42beb8679cbc923bf8ba70aa55cbf8
2 files changed