Skip to content

Commit

Permalink
remove deprecated RealTimeGetComponent methods (apache#1018)
Browse files Browse the repository at this point in the history
  • Loading branch information
cpoerschke authored Sep 20, 2022
1 parent b35ccf8 commit 500c74c
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 23 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -630,21 +630,6 @@ private static void removeCopyFieldTargets(SolrDocument solrDoc, IndexSchema sch

public static SolrInputDocument DELETED = new SolrInputDocument();

@Deprecated // need Resolution
public static SolrInputDocument getInputDocumentFromTlog(
SolrCore core,
BytesRef idBytes,
AtomicLong versionReturned,
Set<String> onlyTheseNonStoredDVs,
boolean resolveFullDocument) {
return getInputDocumentFromTlog(
core,
idBytes,
versionReturned,
onlyTheseNonStoredDVs,
resolveFullDocument ? Resolution.DOC : Resolution.PARTIAL);
}

/**
* Specialized to pick out a child doc from a nested doc from the TLog.
*
Expand Down Expand Up @@ -747,12 +732,6 @@ public static SolrInputDocument getInputDocumentFromTlog(
return null;
}

@Deprecated // easy to use wrong
public static SolrInputDocument getInputDocument(
SolrCore core, BytesRef idBytes, Resolution lookupStrategy) throws IOException {
return getInputDocument(core, idBytes, idBytes, null, null, lookupStrategy);
}

/**
* Obtains the latest document for a given id from the tlog or through the realtime searcher (if
* not found in the tlog). Fields that are targets of copy-fields are excluded.
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -192,7 +192,8 @@ private void validateUserVersions(
private DocFoundAndOldUserAndSolrVersions getOldUserVersionsFromFieldCache(
BytesRef indexedDocId) {
SolrInputDocument oldDoc =
RealTimeGetComponent.getInputDocumentFromTlog(core, indexedDocId, null, null, true);
RealTimeGetComponent.getInputDocumentFromTlog(
core, indexedDocId, null, null, RealTimeGetComponent.Resolution.DOC);
if (oldDoc == RealTimeGetComponent.DELETED) {
return DocFoundAndOldUserAndSolrVersions.NOT_FOUND;
}
Expand Down Expand Up @@ -233,7 +234,7 @@ private DocFoundAndOldUserAndSolrVersions getOldUserVersionsFromStored(BytesRef
// stored fields only...
SolrInputDocument oldDoc =
RealTimeGetComponent.getInputDocument(
core, indexedDocId, RealTimeGetComponent.Resolution.DOC);
core, indexedDocId, indexedDocId, null, null, RealTimeGetComponent.Resolution.DOC);
if (null == oldDoc) {
return DocFoundAndOldUserAndSolrVersions.NOT_FOUND;
} else {
Expand Down

0 comments on commit 500c74c

Please sign in to comment.