Luo Chen has posted comments on this change.

Change subject: [ASTERIXDB-2162][STO] Ensure backward compatibility of 
component id
......................................................................


Patch Set 5:

(2 comments)

> This got tested manually against 23761dd78f01a3bff0ccd25d3ceb3602a1d2cc1c
 > by starting with that commit then moving the data and trying to
 > start with this commit, right?

Oh, I haven't done this...Are you suggesting we do this using 
asterix-verify-storage?

https://asterix-gerrit.ics.uci.edu/#/c/2147/2/asterixdb/asterix-common/src/main/java/org/apache/asterix/common/ioopcallbacks/AbstractLSMIndexIOOperationCallbackFactory.java
File 
asterixdb/asterix-common/src/main/java/org/apache/asterix/common/ioopcallbacks/AbstractLSMIndexIOOperationCallbackFactory.java:

PS2, Line 48: 
            :     protected ILSMComponentIdGenerator getComponentIdGenerator() {
            :         assert ncCtx != null;
            :         return idGeneratorFactory.getComponentIdGenerator(ncCtx);
            :     }
            : 
            :     private void readObject(ObjectInputStream stream) throws 
IOException, ClassNotFoundException {
            :         stream.defaultReadObject();
            :         if (idGeneratorFactory == null) {
            :             idGeneratorFactory = new 
ILSMComponentIdGeneratorFactory() {
            :                 private static final long serialVersionUID = 1L;
            : 
            :                 @Override
            :                 public ILSMComponentIdGenerator 
getComponentIdGenerator(INCServiceContext serviceCtx) {
            :                     // used for backward compatibility
            :                     // if idGeneratorFactory is not set for 
legacy lsm indexes, we return a default
            :                     // component id generator which always 
generates the missing component id.
            :          
> can we make idGeneratorFactory non-final, and do this in something we assig
This seems better. Done.


https://asterix-gerrit.ics.uci.edu/#/c/2147/2/hyracks-fullstack/hyracks/hyracks-storage-am-lsm-common/src/main/java/org/apache/hyracks/storage/am/lsm/common/impls/LSMComponentIdGeneratorFactory.java
File 
hyracks-fullstack/hyracks/hyracks-storage-am-lsm-common/src/main/java/org/apache/hyracks/storage/am/lsm/common/impls/LSMComponentIdGeneratorFactory.java:

PS2, Line 35:     public ILSMComponentIdGenerator getComponentIdGe
> seems there's no usage of this class, otherwise I would ask that this seria
Hmm, not sure I completely follow...In this case, do we need a default UID like 
this, i.e., 1L?


-- 
To view, visit https://asterix-gerrit.ics.uci.edu/2147
To unsubscribe, visit https://asterix-gerrit.ics.uci.edu/settings

Gerrit-MessageType: comment
Gerrit-Change-Id: Ie61103b640c37729d43023b92b1245b8e2f4a264
Gerrit-PatchSet: 5
Gerrit-Project: asterixdb
Gerrit-Branch: master
Gerrit-Owner: Luo Chen <[email protected]>
Gerrit-Reviewer: Anon. E. Moose #1000171
Gerrit-Reviewer: Ian Maxon <[email protected]>
Gerrit-Reviewer: Jenkins <[email protected]>
Gerrit-Reviewer: Luo Chen <[email protected]>
Gerrit-Reviewer: Michael Blow <[email protected]>
Gerrit-Reviewer: abdullah alamoudi <[email protected]>
Gerrit-HasComments: Yes

Reply via email to