Skip to content

Commit

Permalink
Correct name of IndexFieldData#loadGlobalDirect. (#60492)
Browse files Browse the repository at this point in the history
It seems 'localGlobalDirect' was just a typo.
  • Loading branch information
jtibshirani committed Jul 31, 2020
1 parent 771e9f1 commit f1d4fd8
Show file tree
Hide file tree
Showing 11 changed files with 13 additions and 13 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -253,7 +253,7 @@ interface Global<FD extends LeafFieldData> extends IndexFieldData<FD> {

IndexFieldData<FD> loadGlobal(DirectoryReader indexReader);

IndexFieldData<FD> localGlobalDirect(DirectoryReader indexReader) throws Exception;
IndexFieldData<FD> loadGlobalDirect(DirectoryReader indexReader) throws Exception;

}
}
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@ public <FD extends LeafFieldData, IFD extends IndexFieldData<FD>> FD load(LeafRe
@SuppressWarnings("unchecked")
public <FD extends LeafFieldData, IFD extends IndexFieldData.Global<FD>> IFD load(DirectoryReader indexReader,
IFD indexFieldData) throws Exception {
return (IFD) indexFieldData.localGlobalDirect(indexReader);
return (IFD) indexFieldData.loadGlobalDirect(indexReader);
}

@Override
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ public interface IndexOrdinalsFieldData extends IndexFieldData.Global<LeafOrdina
* Load a global view of the ordinals for the given {@link IndexReader}.
*/
@Override
IndexOrdinalsFieldData localGlobalDirect(DirectoryReader indexReader) throws Exception;
IndexOrdinalsFieldData loadGlobalDirect(DirectoryReader indexReader) throws Exception;

/**
* Returns the underlying {@link OrdinalMap} for this fielddata
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -92,7 +92,7 @@ public IndexOrdinalsFieldData loadGlobal(DirectoryReader indexReader) {
}

@Override
public IndexOrdinalsFieldData localGlobalDirect(DirectoryReader indexReader) throws Exception {
public IndexOrdinalsFieldData loadGlobalDirect(DirectoryReader indexReader) throws Exception {
return this;
}

Expand Down Expand Up @@ -183,7 +183,7 @@ public IndexOrdinalsFieldData loadGlobal(DirectoryReader indexReader) {
}

@Override
public IndexOrdinalsFieldData localGlobalDirect(DirectoryReader indexReader) throws Exception {
public IndexOrdinalsFieldData loadGlobalDirect(DirectoryReader indexReader) throws Exception {
return this;
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -115,7 +115,7 @@ private IndexOrdinalsFieldData loadGlobalInternal(DirectoryReader indexReader) {
}

@Override
public IndexOrdinalsFieldData localGlobalDirect(DirectoryReader indexReader) throws Exception {
public IndexOrdinalsFieldData loadGlobalDirect(DirectoryReader indexReader) throws Exception {
return GlobalOrdinalsBuilder.build(
indexReader,
this,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -176,7 +176,7 @@ public IndexOrdinalsFieldData loadGlobal(DirectoryReader indexReader) {
}

@Override
public IndexOrdinalsFieldData localGlobalDirect(DirectoryReader indexReader) throws Exception {
public IndexOrdinalsFieldData loadGlobalDirect(DirectoryReader indexReader) throws Exception {
return loadGlobal(indexReader);
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -191,7 +191,7 @@ private IndexOrdinalsFieldData loadGlobalInternal(DirectoryReader indexReader) {
}

@Override
public IndexOrdinalsFieldData localGlobalDirect(DirectoryReader indexReader) throws Exception {
public IndexOrdinalsFieldData loadGlobalDirect(DirectoryReader indexReader) throws Exception {
return GlobalOrdinalsBuilder.build(indexReader, this, breakerService, logger, scriptFunction);
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -171,7 +171,7 @@ public <FD extends LeafFieldData, IFD extends IndexFieldData.Global<FD>> IFD loa
final Accountable accountable = cache.computeIfAbsent(key, k -> {
ElasticsearchDirectoryReader.addReaderCloseListener(indexReader, IndexFieldCache.this);
Collections.addAll(k.listeners, this.listeners);
final Accountable ifd = (Accountable) indexFieldData.localGlobalDirect(indexReader);
final Accountable ifd = (Accountable) indexFieldData.loadGlobalDirect(indexReader);
for (Listener listener : k.listeners) {
try {
listener.onCache(shardId, fieldName, ifd);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -115,7 +115,7 @@ public <FD extends LeafFieldData, IFD extends IndexFieldData<FD>> FD load(LeafRe
public <FD extends LeafFieldData, IFD extends IndexFieldData.Global<FD>> IFD load(DirectoryReader indexReader,
IFD indexFieldData) throws Exception {
cachedGlobally++;
return (IFD) indexFieldData.localGlobalDirect(indexReader);
return (IFD) indexFieldData.loadGlobalDirect(indexReader);
}

@Override
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -393,8 +393,8 @@ public IndexOrdinalsFieldData loadGlobal(DirectoryReader indexReader) {
}

@Override
public IndexOrdinalsFieldData localGlobalDirect(DirectoryReader indexReader) throws Exception {
IndexOrdinalsFieldData fieldData = delegate.localGlobalDirect(indexReader);
public IndexOrdinalsFieldData loadGlobalDirect(DirectoryReader indexReader) throws Exception {
IndexOrdinalsFieldData fieldData = delegate.loadGlobalDirect(indexReader);
return new KeyedFlatObjectFieldData(key, fieldData);
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -164,7 +164,7 @@ public <FD extends LeafFieldData, IFD extends IndexFieldData<FD>> FD load(LeafRe
public <FD extends LeafFieldData, IFD extends IndexFieldData.Global<FD>> IFD load(DirectoryReader indexReader,
IFD indexFieldData) throws Exception {
topLevelBuilds++;
return (IFD) indexFieldData.localGlobalDirect(indexReader);
return (IFD) indexFieldData.loadGlobalDirect(indexReader);
}

@Override
Expand Down

0 comments on commit f1d4fd8

Please sign in to comment.