cshannon commented on code in PR #3332:
URL: https://github.com/apache/accumulo/pull/3332#discussion_r1181086657


##########
core/src/main/java/org/apache/accumulo/core/file/FileOperations.java:
##########
@@ -267,6 +271,10 @@ public Set<ByteSequence> getColumnFamilies() {
     public boolean isRangeInclusive() {
       return inclusive;
     }
+
+    public Range getFence() {

Review Comment:
   So the next problem is all the validation done by TabletFile. I was trying 
to just replace filename with TabletFile everywhere and require those objects 
but that breaks quite a bit of things. The reason is TabletFile does a lot of 
validation in the constructor to ensure the correct directory structure and 
lots of places (mostly tests) are not passing in rfiles that pass validation 
because they are temp files.  For example 
https://github.com/apache/accumulo/blob/ba472d6e24daa8f0014a22cabace3061f5d46413/core/src/test/java/org/apache/accumulo/core/client/rfile/RFileClientTest.java#L230
   
   I also don't know if any of the Map file stuff would pass validation either 
(I doubt it) but there are no tests for that to even try it unless I write some.
   
   So not sure the past approach. I think the end goal would be to only support 
TabletFile to prevent errors so we'd need to create another implementation of 
TabletFile that doesn't do validation checks (maybe just for testing). But for 
the short term for now maybe we just could have FileOperations support passing 
either a TabletFile or a filename and then we can track both and make sure only 
1 type is set. 
   
   But I'm good with doing whatever, it really just depends how much code we 
want to preemptively change right now for places that are actually using 
FileOperations vs waiting until we are storing the new ranges in metadata and 
can actually use the data and make the change then.



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to