keith-turner commented on code in PR #4208:
URL: https://github.com/apache/accumulo/pull/4208#discussion_r1476779550
##########
server/manager/src/main/java/org/apache/accumulo/manager/tableOps/tableImport/PopulateMetadataTable.java:
##########
@@ -155,11 +166,7 @@ public Repo<Manager> call(long tid, Manager manager)
throws Exception {
if (m == null || !currentRow.equals(metadataRow)) {
if (m != null) {
- if (!sawTabletAvailability) {
- // add a default tablet availability
- TabletColumnFamily.AVAILABILITY_COLUMN.put(m,
-
TabletAvailabilityUtil.toValue(TabletAvailability.ONDEMAND));
- }
+ AVAILABILITY_COLUMN.put(m,
TabletAvailabilityUtil.toValue(initialAvailability));
Review Comment:
Reading back over the comments and thinking about out options, identified
the following four possible options.
1. On table import always set all tablets to ondemand. No API changes.
2. On table import use use availability from exported table if it exists,
otherwise use ondemand. No API changes.
3. Add a new API for table import that allows setting availability. The
impl of this API will ignore availability from exported table and only use what
was set in the API or ondemand if not set.
4. Add a new API for table import that allows setting availability. The
impl of this API will use availability from exported table if it exist,
otherwise it will use API setting, otherwise it will use ondemand.
I think I am leaning twoards options 1 because its the one where its easiest
to understand what will happen when a table is imported. If we went with
option 1 could do the following in this PR.
* Make this PR just always set ondemand for all new tablets it creates.
* Update table import javadoc to explain what happens with tablet
availability.
If there is a need in the future to maintain availability information, then
that could be added with a feature that preserves it on export.
--
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]