Details
-
Improvement
-
Status: Closed
-
Major
-
Resolution: Fixed
-
None
-
None
-
None
-
Reviewed
Description
This is a refactor to move more of the code towards using interfaces for proper encapsulation of logic.
The amount of code touched is large, but it should be fairly easy to review. It changes variable declarations from HTable to HTableInterface where the following holds:
- The declaration being updated won't break assignment
- The declaration change does not break the compile (eg trying to access non-interface methods)
The two main situations are to change something like this:
HTable h = new HTable(c, tn);
to
HTableInterface h = new HTable(c, tn);
and this:
public void doSomething(HTable h) { ... }
to this:
public void doSomething(HTableInterface h) { ... }
This gets most of the obvious cases out of the way and prepares for more complicated interface refactors in the future. In method signatures, I changed parameters, but did not change any public or protected method return values, since that would violate criteria #1 above and break compatibility.
Attachments
Attachments
Issue Links
- depends upon
-
HBASE-11797 Create Table interface to replace HTableInterface
- Closed
- is part of
-
HBASE-10856 Prep for 1.0
- Closed