>From Murtadha Hubail <[email protected]>:

Attention is currently required from: Ritik Raj.
Murtadha Hubail has posted comments on this change. ( 
https://asterix-gerrit.ics.uci.edu/c/asterixdb/+/19443 )

Change subject: [ASTERIXDB-3563][STO] Delay activation of dataset until accessed
......................................................................


Patch Set 2:

(18 comments)

File 
asterixdb/asterix-app/src/main/java/org/apache/asterix/app/nc/NCAppRuntimeContext.java:

https://asterix-gerrit.ics.uci.edu/c/asterixdb/+/19443/comment/0121caf1_c821bd0f
PS2, Line 373: createDatasetLifecycleManager
we might not need this after addressing the comments


File 
asterixdb/asterix-app/src/main/java/org/apache/asterix/app/nc/RecoveryManager.java:

https://asterix-gerrit.ics.uci.edu/c/asterixdb/+/19443/comment/cba01724_5afa9e17
PS2, Line 905: recoverIndexes
we probably don't need to add this to the interface


File 
asterixdb/asterix-common/src/main/java/org/apache/asterix/common/context/DatasetLifecycleManager.java:

https://asterix-gerrit.ics.uci.edu/c/asterixdb/+/19443/comment/5e8b8ccf_6943aed9
PS2, Line 74: ILocalResourceRepository
You can downcast here and just use it after


https://asterix-gerrit.ics.uci.edu/c/asterixdb/+/19443/comment/da4bd105_73bd10b4
PS2, Line 209: , boolean resetStatsOnActivatio
we don't need this. Make the open call checks if it needs to recover the index 
or not. Based on the flow, decide if you need to reset the stats of the very 
first time or not.


https://asterix-gerrit.ics.uci.edu/c/asterixdb/+/19443/comment/24718730_b6504243
PS2, Line 389:     protected void validateDatasetLifecycleManagerState() throws 
HyracksDataException {
shouldn't need t his


File 
asterixdb/asterix-common/src/main/java/org/apache/asterix/common/context/DatasetResource.java:

https://asterix-gerrit.ics.uci.edu/c/asterixdb/+/19443/comment/c61da0ef_26eda8bf
PS2, Line 51: Map<Integer, Boolean> indexRecovered
Maybe use a set instead (recoveredPartitions)


https://asterix-gerrit.ics.uci.edu/c/asterixdb/+/19443/comment/340bb1ea_75b5b079
PS2, Line 132: areIndexesRecovered
isRecovered


https://asterix-gerrit.ics.uci.edu/c/asterixdb/+/19443/comment/a707d660_64bf92cf
PS2, Line 148: setIndexRecovered
markRecovered or recovered


File 
asterixdb/asterix-common/src/main/java/org/apache/asterix/common/transactions/IRecoveryManager.java:

https://asterix-gerrit.ics.uci.edu/c/asterixdb/+/19443/comment/61b70aa5_c9c5314a
PS2, Line 138: recoverIndexes
shouldn't need this


File 
asterixdb/asterix-common/src/main/java/org/apache/asterix/common/utils/StoragePathUtil.java:

https://asterix-gerrit.ics.uci.edu/c/asterixdb/+/19443/comment/e0d625b8_4a21a6da
PS2, Line 144: rootSepIndex
better name?


File 
hyracks-fullstack/hyracks/hyracks-storage-am-common/src/main/java/org/apache/hyracks/storage/am/common/dataflow/IndexDataflowHelper.java:

https://asterix-gerrit.ics.uci.edu/c/asterixdb/+/19443/comment/a8c987b7_29c37682
PS2, Line 69:  if (lcManager.resourceRecovered(resourceRef.getRelativePath())) {
            :                 lcManager.open(resourceRef.getRelativePath(), 
false);
            :             } else {
            :                 // This will recover old index and also activated 
any new indexes.
            :                 
lcManager.ensureIndexOpenAndConsistent(resourceRef.getRelativePath());
            :             }
revert this and do the recovery in open(.) if it's needed


File 
hyracks-fullstack/hyracks/hyracks-storage-am-common/src/main/java/org/apache/hyracks/storage/am/common/dataflow/IndexLifecycleManager.java:

https://asterix-gerrit.ics.uci.edu/c/asterixdb/+/19443/comment/e69e6fbb_14b84f6a
PS2, Line 127: public boolean resourceRecovered(String resourcePath) throws 
HyracksDataException {
             :         return true;
             :     }
remove


https://asterix-gerrit.ics.uci.edu/c/asterixdb/+/19443/comment/2e177cc2_04255183
PS2, Line 175: ensureIndexOpenAndConsistent
remove


File 
hyracks-fullstack/hyracks/hyracks-storage-am-lsm-common/src/main/java/org/apache/hyracks/storage/am/lsm/common/impls/AbstractLSMIndex.java:

https://asterix-gerrit.ics.uci.edu/c/asterixdb/+/19443/comment/587d820a_8954a873
PS2, Line 196: // The only caller is LifeCycleManager.open(), so it seems 
nothing to worry about isActive check and fail.
make proper comment or remove


File 
hyracks-fullstack/hyracks/hyracks-storage-common/src/main/java/org/apache/hyracks/storage/common/ILocalResourceRepository.java:

https://asterix-gerrit.ics.uci.edu/c/asterixdb/+/19443/comment/3734b673_c42036ed
PS2, Line 37: getResources
You can cast this on asterixdb and remove it from the interface


https://asterix-gerrit.ics.uci.edu/c/asterixdb/+/19443/comment/78fc494a_28e2193e
PS2, Line 42: IIOManager getIOManager();
remove


File 
hyracks-fullstack/hyracks/hyracks-storage-common/src/main/java/org/apache/hyracks/storage/common/IResourceLifecycleManager.java:

https://asterix-gerrit.ics.uci.edu/c/asterixdb/+/19443/comment/eb9f1ddc_9b6e266a
PS2, Line 51: ensureIndexOpenAndConsistent
remove and just use open


https://asterix-gerrit.ics.uci.edu/c/asterixdb/+/19443/comment/d4312e1f_9768b824
 
PS2, Line 60: resetStatsOnActivation
remove



--
To view, visit https://asterix-gerrit.ics.uci.edu/c/asterixdb/+/19443
To unsubscribe, or for help writing mail filters, visit 
https://asterix-gerrit.ics.uci.edu/settings

Gerrit-Project: asterixdb
Gerrit-Branch: ionic
Gerrit-Change-Id: If64a7fbd9701772ffa42761d1557223a3eea95be
Gerrit-Change-Number: 19443
Gerrit-PatchSet: 2
Gerrit-Owner: Ritik Raj <[email protected]>
Gerrit-Reviewer: Anon. E. Moose #1000171
Gerrit-Reviewer: Jenkins <[email protected]>
Gerrit-Reviewer: Ritik Raj <[email protected]>
Gerrit-CC: Murtadha Hubail <[email protected]>
Gerrit-Attention: Ritik Raj <[email protected]>
Gerrit-Comment-Date: Thu, 27 Feb 2025 13:06:36 +0000
Gerrit-HasComments: Yes
Gerrit-Has-Labels: No
Gerrit-MessageType: comment

Reply via email to