Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
18 changes: 13 additions & 5 deletions core/src/main/java/org/apache/accumulo/core/conf/Property.java
Original file line number Diff line number Diff line change
Expand Up @@ -577,7 +577,9 @@ public enum Property {
TSERV_COMPACTION_SERVICE_ROOT_RATE_LIMIT("tserver.compaction.major.service.root.rate.limit", "0B",
PropertyType.BYTES,
"Maximum number of bytes to read or write per second over all major"
+ " compactions in this compaction service, or 0B for unlimited.",
+ " compactions in this compaction service, or 0B for unlimited. This property has"
+ " been deprecated in anticipation of it being removed in a future release that"
+ " removes the rate limiting feature.",
"2.1.0"),
TSERV_COMPACTION_SERVICE_ROOT_MAX_OPEN(
"tserver.compaction.major.service.root.planner.opts.maxOpen", "30", PropertyType.COUNT,
Expand All @@ -596,7 +598,9 @@ public enum Property {
TSERV_COMPACTION_SERVICE_META_RATE_LIMIT("tserver.compaction.major.service.meta.rate.limit", "0B",
PropertyType.BYTES,
"Maximum number of bytes to read or write per second over all major"
+ " compactions in this compaction service, or 0B for unlimited.",
+ " compactions in this compaction service, or 0B for unlimited. This property has"
+ " been deprecated in anticipation of it being removed in a future release that"
+ " removes the rate limiting feature.",
"2.1.0"),
TSERV_COMPACTION_SERVICE_META_MAX_OPEN(
"tserver.compaction.major.service.meta.planner.opts.maxOpen", "30", PropertyType.COUNT,
Expand All @@ -615,7 +619,9 @@ public enum Property {
TSERV_COMPACTION_SERVICE_DEFAULT_RATE_LIMIT("tserver.compaction.major.service.default.rate.limit",
"0B", PropertyType.BYTES,
"Maximum number of bytes to read or write per second over all major"
+ " compactions in this compaction service, or 0B for unlimited.",
+ " compactions in this compaction service, or 0B for unlimited. This property has"
+ " been deprecated in anticipation of it being removed in a future release that"
+ " removes the rate limiting feature.",
"2.1.0"),
TSERV_COMPACTION_SERVICE_DEFAULT_MAX_OPEN(
"tserver.compaction.major.service.default.planner.opts.maxOpen", "10", PropertyType.COUNT,
Expand Down Expand Up @@ -726,6 +732,7 @@ public enum Property {
"The number of threads on each tablet server available to retrieve"
+ " summary data, that is not currently in cache, from RFiles.",
"2.0.0"),
@Deprecated(since = "3.1", forRemoval = true)
TSERV_LAST_LOCATION_MODE("tserver.last.location.mode", "compaction",
PropertyType.LAST_LOCATION_MODE,
"Describes how the system will record the 'last' location for tablets, which can be used for"
Expand All @@ -734,9 +741,10 @@ public enum Property {
+ " 'assignment' is the mode, then the most recently assigned location will be recorded."
+ " The manager.startup.tserver properties might also need to be set to ensure the"
+ " tserver is available before tablets are initially assigned if the 'last' location is"
+ " to be used.",
+ " to be used. This property has been deprecated in anticipation of it being removed in"
+ " a future release that removes major compactions from the TabletServer, rendering this"
+ " feature moot.",
"2.1.1"),

// accumulo garbage collector properties
GC_PREFIX("gc.", null, PropertyType.PREFIX,
"Properties in this category affect the behavior of the accumulo garbage collector.",
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -65,6 +65,9 @@
public class ManagerMetadataUtil {

private static final Logger log = LoggerFactory.getLogger(ManagerMetadataUtil.class);
@SuppressWarnings("removal")
private static final Property DEPRECATED_TSERV_LAST_LOCATION_MODE_PROPERTY =
Property.TSERV_LAST_LOCATION_MODE;

public static void addNewTablet(ServerContext context, KeyExtent extent, String dirName,
TServerInstance tServerInstance, Map<StoredTabletFile,DataFileValue> datafileSizes,
Expand Down Expand Up @@ -257,7 +260,8 @@ public static void updateLastForAssignmentMode(ClientContext context,

// if the location mode is assignment, then preserve the current location in the last
// location value
if ("assignment".equals(context.getConfiguration().get(Property.TSERV_LAST_LOCATION_MODE))) {
if ("assignment"
.equals(context.getConfiguration().get(DEPRECATED_TSERV_LAST_LOCATION_MODE_PROPERTY))) {
ManagerMetadataUtil.updateLocation(tabletMutator, lastLocation, Location.last(location));
}
}
Expand All @@ -275,7 +279,8 @@ public static void updateLastForCompactionMode(ClientContext context, TabletMuta
Location lastLocation, TServerInstance tServerInstance) {
// if the location mode is 'compaction', then preserve the current compaction location in the
// last location value
if ("compaction".equals(context.getConfiguration().get(Property.TSERV_LAST_LOCATION_MODE))) {
if ("compaction"
.equals(context.getConfiguration().get(DEPRECATED_TSERV_LAST_LOCATION_MODE_PROPERTY))) {
Location newLocation = Location.last(tServerInstance);
updateLocation(tabletMutator, lastLocation, newLocation);
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,9 @@ public class ManagerMetadataUtilTest {
@BeforeEach
public void before() {
conf = EasyMock.createMock(AccumuloConfiguration.class);
EasyMock.expect(conf.get(Property.TSERV_LAST_LOCATION_MODE)).andReturn("assignment");
@SuppressWarnings("removal")
Property DEPRECATED_TSERV_LAST_LOCATION_MODE_PROPERTY = Property.TSERV_LAST_LOCATION_MODE;
EasyMock.expect(conf.get(DEPRECATED_TSERV_LAST_LOCATION_MODE_PROPERTY)).andReturn("assignment");
context = EasyMock.createMock(ClientContext.class);
EasyMock.expect(context.getConfiguration()).andReturn(conf).once();
tabletMutator = EasyMock.createMock(Ample.TabletMutator.class);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -43,14 +43,18 @@

public class AssignLocationModeIT extends ConfigurableMacBase {

@SuppressWarnings("removal")
private static final Property DEPRECATED_TSERV_LAST_LOCATION_MODE_PROPERTY =
Property.TSERV_LAST_LOCATION_MODE;

@Override
protected Duration defaultTimeout() {
return Duration.ofMinutes(2);
}

@Override
public void configure(MiniAccumuloConfigImpl cfg, Configuration fsConf) {
cfg.setProperty(Property.TSERV_LAST_LOCATION_MODE, "assignment");
cfg.setProperty(DEPRECATED_TSERV_LAST_LOCATION_MODE_PROPERTY, "assignment");
}

@Test
Expand Down Expand Up @@ -78,7 +82,7 @@ public void test() throws Exception {
}
// assert that the default mode is "assign"
assertEquals("assignment", c.instanceOperations().getSystemConfiguration()
.get(Property.TSERV_LAST_LOCATION_MODE.getKey()));
.get(DEPRECATED_TSERV_LAST_LOCATION_MODE_PROPERTY.getKey()));

// last location should not be set yet
TabletLocationState unflushed = getTabletLocationState(c, tableId);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -43,14 +43,18 @@

public class CompactLocationModeIT extends ConfigurableMacBase {

@SuppressWarnings("removal")
private static final Property DEPRECATED_TSERV_LAST_LOCATION_MODE_PROPERTY =
Property.TSERV_LAST_LOCATION_MODE;

@Override
protected Duration defaultTimeout() {
return Duration.ofMinutes(2);
}

@Override
public void configure(MiniAccumuloConfigImpl cfg, Configuration fsConf) {
cfg.setProperty(Property.TSERV_LAST_LOCATION_MODE, "compaction");
cfg.setProperty(DEPRECATED_TSERV_LAST_LOCATION_MODE_PROPERTY, "compaction");
}

@Test
Expand All @@ -77,7 +81,7 @@ public void test() throws Exception {
}
// assert that the default mode is "compact"
assertEquals("compaction", c.instanceOperations().getSystemConfiguration()
.get(Property.TSERV_LAST_LOCATION_MODE.getKey()));
.get(DEPRECATED_TSERV_LAST_LOCATION_MODE_PROPERTY.getKey()));

// no last location should be set yet
TabletLocationState unflushed = getTabletLocationState(c, tableId);
Expand Down