.../java/org/apache/hadoop/hbase/HColumnDescriptor.java | 6 ++++++ .../main/java/org/apache/hadoop/hbase/client/Mutation.java | 7 +++++++ .../src/main/java/org/apache/hadoop/hbase/client/Query.java | 5 +++++ .../hbase/security/access/AccessControlConstants.java | 4 ++++ .../hadoop/hbase/security/visibility/Authorizations.java | 2 +- .../hadoop/hbase/security/visibility/CellVisibility.java | 2 +- .../hadoop/hbase/security/visibility/VisibilityClient.java | 2 +- .../src/main/java/org/apache/hadoop/hbase/Cell.java | 4 ++++ .../src/main/java/org/apache/hadoop/hbase/CellUtil.java | 4 ++++ .../src/main/java/org/apache/hadoop/hbase/HConstants.java | 7 +++++++ .../org/apache/hadoop/hbase/codec/CellCodecWithTags.java | 2 ++ .../apache/hadoop/hbase/codec/KeyValueCodecWithTags.java | 2 ++ .../main/java/org/apache/hadoop/hbase/io/crypto/Cipher.java | 2 +- .../org/apache/hadoop/hbase/io/crypto/CipherProvider.java | 2 +- .../java/org/apache/hadoop/hbase/io/crypto/Context.java | 2 +- .../java/org/apache/hadoop/hbase/io/crypto/Decryptor.java | 2 +- .../hadoop/hbase/io/crypto/DefaultCipherProvider.java | 2 +- .../java/org/apache/hadoop/hbase/io/crypto/Encryption.java | 2 +- .../java/org/apache/hadoop/hbase/io/crypto/Encryptor.java | 2 +- .../java/org/apache/hadoop/hbase/io/crypto/KeyProvider.java | 2 +- .../apache/hadoop/hbase/io/crypto/KeyStoreKeyProvider.java | 2 +- .../java/org/apache/hadoop/hbase/mapreduce/CellCreator.java | 2 ++ .../java/org/apache/hadoop/hbase/mapreduce/ImportTsv.java | 13 ++++++++----- .../apache/hadoop/hbase/mapreduce/TsvImporterMapper.java | 3 ++- .../hbase/mapreduce/VisibilityExpressionResolver.java | 2 +- .../hbase/security/visibility/VisibilityExpEvaluator.java | 2 +- .../hbase/security/visibility/VisibilityLabelService.java | 2 +- .../java/org/apache/hadoop/hbase/util/EncryptionTest.java | 2 +- .../java/org/apache/hadoop/hbase/io/hfile/TagUsage.java | 4 ++++ 29 files changed, 73 insertions(+), 22 deletions(-) diff --git a/hbase-client/src/main/java/org/apache/hadoop/hbase/HColumnDescriptor.java b/hbase-client/src/main/java/org/apache/hadoop/hbase/HColumnDescriptor.java index d84022b..2c9ad98 100644 --- a/hbase-client/src/main/java/org/apache/hadoop/hbase/HColumnDescriptor.java +++ b/hbase-client/src/main/java/org/apache/hadoop/hbase/HColumnDescriptor.java @@ -107,7 +107,9 @@ public class HColumnDescriptor implements WritableComparable public static final String KEEP_DELETED_CELLS = "KEEP_DELETED_CELLS"; public static final String COMPRESS_TAGS = "COMPRESS_TAGS"; + @InterfaceStability.Unstable public static final String ENCRYPTION = "ENCRYPTION"; + @InterfaceStability.Unstable public static final String ENCRYPTION_KEY = "ENCRYPTION_KEY"; /** @@ -1339,6 +1341,7 @@ public class HColumnDescriptor implements WritableComparable /** * Return the encryption algorithm in use by this family */ + @InterfaceStability.Unstable public String getEncryptionType() { return getValue(ENCRYPTION); } @@ -1347,17 +1350,20 @@ public class HColumnDescriptor implements WritableComparable * Set the encryption algorithm for use with this family * @param algorithm */ + @InterfaceStability.Unstable public HColumnDescriptor setEncryptionType(String algorithm) { setValue(ENCRYPTION, algorithm); return this; } /** Return the raw crypto key attribute for the family, or null if not set */ + @InterfaceStability.Unstable public byte[] getEncryptionKey() { return getValue(Bytes.toBytes(ENCRYPTION_KEY)); } /** Set the raw crypto key attribute for the family */ + @InterfaceStability.Unstable public HColumnDescriptor setEncryptionKey(byte[] keyBytes) { setValue(Bytes.toBytes(ENCRYPTION_KEY), keyBytes); return this; diff --git a/hbase-client/src/main/java/org/apache/hadoop/hbase/client/Mutation.java b/hbase-client/src/main/java/org/apache/hadoop/hbase/client/Mutation.java index ec41568..5b28eda 100644 --- a/hbase-client/src/main/java/org/apache/hadoop/hbase/client/Mutation.java +++ b/hbase-client/src/main/java/org/apache/hadoop/hbase/client/Mutation.java @@ -368,6 +368,7 @@ public abstract class Mutation extends OperationWithAttributes implements Row, C * It is illegal to set CellVisibility on Delete mutation. * @param expression */ + @InterfaceStability.Unstable public void setCellVisibility(CellVisibility expression) { this.setAttribute(VisibilityConstants.VISIBILITY_LABELS_ATTR_KEY, ProtobufUtil .toCellVisibility(expression).toByteArray()); @@ -377,6 +378,7 @@ public abstract class Mutation extends OperationWithAttributes implements Row, C * @return CellVisibility associated with cells in this Mutation. * @throws DeserializationException */ + @InterfaceStability.Unstable public CellVisibility getCellVisibility() throws DeserializationException { byte[] cellVisibilityBytes = this.getAttribute(VisibilityConstants.VISIBILITY_LABELS_ATTR_KEY); if (cellVisibilityBytes == null) return null; @@ -440,6 +442,7 @@ public abstract class Mutation extends OperationWithAttributes implements Row, C /** * @return The serialized ACL for this operation, or null if none */ + @InterfaceStability.Unstable public byte[] getACL() { return getAttribute(AccessControlConstants.OP_ATTRIBUTE_ACL); } @@ -448,6 +451,7 @@ public abstract class Mutation extends OperationWithAttributes implements Row, C * @param user User short name * @param perms Permissions for the user */ + @InterfaceStability.Unstable public void setACL(String user, Permission perms) { setAttribute(AccessControlConstants.OP_ATTRIBUTE_ACL, ProtobufUtil.toUsersAndPermissions(user, perms).toByteArray()); @@ -456,6 +460,7 @@ public abstract class Mutation extends OperationWithAttributes implements Row, C /** * @param perms A map of permissions for a user or users */ + @InterfaceStability.Unstable public void setACL(Map perms) { ListMultimap permMap = ArrayListMultimap.create(); for (Map.Entry entry : perms.entrySet()) { @@ -485,6 +490,7 @@ public abstract class Mutation extends OperationWithAttributes implements Row, C * @return the TTL requested for the result of the mutation, in milliseconds, * or Long.MAX_VALUE if unset */ + @InterfaceStability.Unstable public long getTTL() { byte[] ttlBytes = getAttribute(OP_ATTRIBUTE_TTL); if (ttlBytes != null) { @@ -498,6 +504,7 @@ public abstract class Mutation extends OperationWithAttributes implements Row, C * @param ttl the TTL desired for the result of the mutation, in milliseconds * @return this */ + @InterfaceStability.Unstable public Mutation setTTL(long ttl) { setAttribute(OP_ATTRIBUTE_TTL, Bytes.toBytes(ttl)); return this; diff --git a/hbase-client/src/main/java/org/apache/hadoop/hbase/client/Query.java b/hbase-client/src/main/java/org/apache/hadoop/hbase/client/Query.java index 93a9393..423e401 100644 --- a/hbase-client/src/main/java/org/apache/hadoop/hbase/client/Query.java +++ b/hbase-client/src/main/java/org/apache/hadoop/hbase/client/Query.java @@ -61,6 +61,7 @@ public abstract class Query extends OperationWithAttributes { * Sets the authorizations to be used by this Query * @param authorizations */ + @InterfaceStability.Unstable public void setAuthorizations(Authorizations authorizations) { this.setAttribute(VisibilityConstants.VISIBILITY_LABELS_ATTR_KEY, ProtobufUtil .toAuthorizations(authorizations).toByteArray()); @@ -70,6 +71,7 @@ public abstract class Query extends OperationWithAttributes { * @return The authorizations this Query is associated with. * @throws DeserializationException */ + @InterfaceStability.Unstable public Authorizations getAuthorizations() throws DeserializationException { byte[] authorizationsBytes = this.getAttribute(VisibilityConstants.VISIBILITY_LABELS_ATTR_KEY); if (authorizationsBytes == null) return null; @@ -79,6 +81,7 @@ public abstract class Query extends OperationWithAttributes { /** * @return The serialized ACL for this operation, or null if none */ + @InterfaceStability.Unstable public byte[] getACL() { return getAttribute(AccessControlConstants.OP_ATTRIBUTE_ACL); } @@ -87,6 +90,7 @@ public abstract class Query extends OperationWithAttributes { * @param user User short name * @param perms Permissions for the user */ + @InterfaceStability.Unstable public void setACL(String user, Permission perms) { setAttribute(AccessControlConstants.OP_ATTRIBUTE_ACL, ProtobufUtil.toUsersAndPermissions(user, perms).toByteArray()); @@ -95,6 +99,7 @@ public abstract class Query extends OperationWithAttributes { /** * @param perms A map of permissions for a user or users */ + @InterfaceStability.Unstable public void setACL(Map perms) { ListMultimap permMap = ArrayListMultimap.create(); for (Map.Entry entry : perms.entrySet()) { diff --git a/hbase-client/src/main/java/org/apache/hadoop/hbase/security/access/AccessControlConstants.java b/hbase-client/src/main/java/org/apache/hadoop/hbase/security/access/AccessControlConstants.java index 7bf441a..6200652 100644 --- a/hbase-client/src/main/java/org/apache/hadoop/hbase/security/access/AccessControlConstants.java +++ b/hbase-client/src/main/java/org/apache/hadoop/hbase/security/access/AccessControlConstants.java @@ -44,12 +44,16 @@ public interface AccessControlConstants { // Operation attributes for cell level security /** Cell level ACL */ + @InterfaceStability.Unstable public static final String OP_ATTRIBUTE_ACL = "acl"; /** Cell level ACL evaluation strategy */ + @InterfaceStability.Unstable public static final String OP_ATTRIBUTE_ACL_STRATEGY = "acl.strategy"; /** Default cell ACL evaluation strategy: Table and CF first, then ACL */ + @InterfaceStability.Unstable public static final byte[] OP_ATTRIBUTE_ACL_STRATEGY_DEFAULT = new byte[] { 0 }; /** Alternate cell ACL evaluation strategy: Cell ACL first, then table and CF */ + @InterfaceStability.Unstable public static final byte[] OP_ATTRIBUTE_ACL_STRATEGY_CELL_FIRST = new byte[] { 1 }; } diff --git a/hbase-client/src/main/java/org/apache/hadoop/hbase/security/visibility/Authorizations.java b/hbase-client/src/main/java/org/apache/hadoop/hbase/security/visibility/Authorizations.java index 4b3ed54..c820151 100644 --- a/hbase-client/src/main/java/org/apache/hadoop/hbase/security/visibility/Authorizations.java +++ b/hbase-client/src/main/java/org/apache/hadoop/hbase/security/visibility/Authorizations.java @@ -29,7 +29,7 @@ import org.apache.hadoop.hbase.classification.InterfaceStability; * current scan/get can access. */ @InterfaceAudience.Public -@InterfaceStability.Evolving +@InterfaceStability.Unstable public class Authorizations { private List labels; diff --git a/hbase-client/src/main/java/org/apache/hadoop/hbase/security/visibility/CellVisibility.java b/hbase-client/src/main/java/org/apache/hadoop/hbase/security/visibility/CellVisibility.java index 4968548..519a6c9 100644 --- a/hbase-client/src/main/java/org/apache/hadoop/hbase/security/visibility/CellVisibility.java +++ b/hbase-client/src/main/java/org/apache/hadoop/hbase/security/visibility/CellVisibility.java @@ -27,7 +27,7 @@ import org.apache.hadoop.hbase.util.Bytes; * expression can contain visibility labels combined with logical operators AND(&), OR(|) and NOT(!) */ @InterfaceAudience.Public -@InterfaceStability.Evolving +@InterfaceStability.Unstable public class CellVisibility { private String expression; diff --git a/hbase-client/src/main/java/org/apache/hadoop/hbase/security/visibility/VisibilityClient.java b/hbase-client/src/main/java/org/apache/hadoop/hbase/security/visibility/VisibilityClient.java index 4b39061..81400f0 100644 --- a/hbase-client/src/main/java/org/apache/hadoop/hbase/security/visibility/VisibilityClient.java +++ b/hbase-client/src/main/java/org/apache/hadoop/hbase/security/visibility/VisibilityClient.java @@ -49,7 +49,7 @@ import com.google.protobuf.ServiceException; * Utility client for doing visibility labels admin operations. */ @InterfaceAudience.Public -@InterfaceStability.Evolving +@InterfaceStability.Unstable public class VisibilityClient { /** diff --git a/hbase-common/src/main/java/org/apache/hadoop/hbase/Cell.java b/hbase-common/src/main/java/org/apache/hadoop/hbase/Cell.java index 4aafe7c..b14dd2a 100644 --- a/hbase-common/src/main/java/org/apache/hadoop/hbase/Cell.java +++ b/hbase-common/src/main/java/org/apache/hadoop/hbase/Cell.java @@ -173,11 +173,13 @@ public interface Cell { /** * @return the tags byte array */ + @InterfaceStability.Unstable byte[] getTagsArray(); /** * @return the first offset where the tags start in the Cell */ + @InterfaceStability.Unstable int getTagsOffset(); /** @@ -185,6 +187,7 @@ public interface Cell { * @deprecated use {@link #getTagsLengthUnsigned()} which can handle tags length upto 65535. */ @Deprecated + @InterfaceStability.Unstable short getTagsLength(); /** @@ -192,6 +195,7 @@ public interface Cell { * @deprecated From next major version this will be renamed to getTagsLength() which returns int. */ @Deprecated + @InterfaceStability.Unstable int getTagsLengthUnsigned(); /** diff --git a/hbase-common/src/main/java/org/apache/hadoop/hbase/CellUtil.java b/hbase-common/src/main/java/org/apache/hadoop/hbase/CellUtil.java index 71e3dba..7c82c6c 100644 --- a/hbase-common/src/main/java/org/apache/hadoop/hbase/CellUtil.java +++ b/hbase-common/src/main/java/org/apache/hadoop/hbase/CellUtil.java @@ -53,6 +53,7 @@ public final class CellUtil { cell.getQualifierLength()); } + @InterfaceStability.Unstable public static ByteRange fillTagRange(Cell cell, ByteRange range) { return range.set(cell.getTagsArray(), cell.getTagsOffset(), cell.getTagsLengthUnsigned()); } @@ -90,6 +91,7 @@ public final class CellUtil { * @param cell * @return tag value in a new byte array. */ + @InterfaceStability.Unstable public static byte[] getTagArray(Cell cell){ byte[] output = new byte[cell.getTagsLengthUnsigned()]; copyTagTo(cell, output, 0); @@ -130,6 +132,7 @@ public final class CellUtil { * @param destinationOffset * @return position after tags */ + @InterfaceStability.Unstable public static int copyTagTo(Cell cell, byte[] destination, int destinationOffset) { System.arraycopy(cell.getTagsArray(), cell.getTagsOffset(), destination, destinationOffset, cell.getTagsLengthUnsigned()); @@ -405,6 +408,7 @@ public final class CellUtil { * @param length * @return iterator for the tags */ + @InterfaceStability.Unstable public static Iterator tagsIterator(final byte[] tags, final int offset, final int length) { return new Iterator() { private int pos = offset; diff --git a/hbase-common/src/main/java/org/apache/hadoop/hbase/HConstants.java b/hbase-common/src/main/java/org/apache/hadoop/hbase/HConstants.java index b1508cc..eea520d 100644 --- a/hbase-common/src/main/java/org/apache/hadoop/hbase/HConstants.java +++ b/hbase-common/src/main/java/org/apache/hadoop/hbase/HConstants.java @@ -1006,26 +1006,33 @@ public final class HConstants { public static final long NO_NONCE = 0; /** Configuration key for the crypto algorithm provider, a class name */ + @InterfaceStability.Unstable public static final String CRYPTO_CIPHERPROVIDER_CONF_KEY = "hbase.crypto.cipherprovider"; /** Configuration key for the crypto key provider, a class name */ + @InterfaceStability.Unstable public static final String CRYPTO_KEYPROVIDER_CONF_KEY = "hbase.crypto.keyprovider"; /** Configuration key for the crypto key provider parameters */ + @InterfaceStability.Unstable public static final String CRYPTO_KEYPROVIDER_PARAMETERS_KEY = "hbase.crypto.keyprovider.parameters"; /** Configuration key for the name of the master key for the cluster, a string */ + @InterfaceStability.Unstable public static final String CRYPTO_MASTERKEY_NAME_CONF_KEY = "hbase.crypto.master.key.name"; /** Configuration key for the name of the alternate master key for the cluster, a string */ + @InterfaceStability.Unstable public static final String CRYPTO_MASTERKEY_ALTERNATE_NAME_CONF_KEY = "hbase.crypto.master.alternate.key.name"; /** Configuration key for the algorithm to use when encrypting the WAL, a string */ + @InterfaceStability.Unstable public static final String CRYPTO_WAL_ALGORITHM_CONF_KEY = "hbase.crypto.wal.algorithm"; /** Configuration key for the name of the master WAL encryption key for the cluster, a string */ + @InterfaceStability.Unstable public static final String CRYPTO_WAL_KEY_NAME_CONF_KEY = "hbase.crypto.wal.key.name"; /** Configuration key for enabling HLog encryption, a boolean */ diff --git a/hbase-common/src/main/java/org/apache/hadoop/hbase/codec/CellCodecWithTags.java b/hbase-common/src/main/java/org/apache/hadoop/hbase/codec/CellCodecWithTags.java index abf9564..4fb925c 100644 --- a/hbase-common/src/main/java/org/apache/hadoop/hbase/codec/CellCodecWithTags.java +++ b/hbase-common/src/main/java/org/apache/hadoop/hbase/codec/CellCodecWithTags.java @@ -23,6 +23,7 @@ import java.io.OutputStream; import org.apache.commons.io.IOUtils; import org.apache.hadoop.hbase.classification.InterfaceAudience; +import org.apache.hadoop.hbase.classification.InterfaceStability; import org.apache.hadoop.hbase.Cell; import org.apache.hadoop.hbase.CellUtil; import org.apache.hadoop.hbase.HBaseInterfaceAudience; @@ -34,6 +35,7 @@ import org.apache.hadoop.hbase.util.Bytes; * Use this Codec only at server side. */ @InterfaceAudience.LimitedPrivate(HBaseInterfaceAudience.CONFIG) +@InterfaceStability.Unstable public class CellCodecWithTags implements Codec { static class CellEncoder extends BaseEncoder { CellEncoder(final OutputStream out) { diff --git a/hbase-common/src/main/java/org/apache/hadoop/hbase/codec/KeyValueCodecWithTags.java b/hbase-common/src/main/java/org/apache/hadoop/hbase/codec/KeyValueCodecWithTags.java index 8bc1137..614f9cf 100644 --- a/hbase-common/src/main/java/org/apache/hadoop/hbase/codec/KeyValueCodecWithTags.java +++ b/hbase-common/src/main/java/org/apache/hadoop/hbase/codec/KeyValueCodecWithTags.java @@ -22,6 +22,7 @@ import java.io.InputStream; import java.io.OutputStream; import org.apache.hadoop.hbase.classification.InterfaceAudience; +import org.apache.hadoop.hbase.classification.InterfaceStability; import org.apache.hadoop.hbase.Cell; import org.apache.hadoop.hbase.HBaseInterfaceAudience; import org.apache.hadoop.hbase.KeyValue; @@ -51,6 +52,7 @@ import org.apache.hadoop.hbase.KeyValueUtil; * Use this Codec only at server side. */ @InterfaceAudience.LimitedPrivate(HBaseInterfaceAudience.CONFIG) +@InterfaceStability.Unstable public class KeyValueCodecWithTags implements Codec { public static class KeyValueEncoder extends BaseEncoder { public KeyValueEncoder(final OutputStream out) { diff --git a/hbase-common/src/main/java/org/apache/hadoop/hbase/io/crypto/Cipher.java b/hbase-common/src/main/java/org/apache/hadoop/hbase/io/crypto/Cipher.java index beda267..b199e22 100644 --- a/hbase-common/src/main/java/org/apache/hadoop/hbase/io/crypto/Cipher.java +++ b/hbase-common/src/main/java/org/apache/hadoop/hbase/io/crypto/Cipher.java @@ -28,7 +28,7 @@ import org.apache.hadoop.hbase.classification.InterfaceStability; * A common interface for a cryptographic algorithm. */ @InterfaceAudience.Public -@InterfaceStability.Evolving +@InterfaceStability.Unstable public abstract class Cipher { private final CipherProvider provider; diff --git a/hbase-common/src/main/java/org/apache/hadoop/hbase/io/crypto/CipherProvider.java b/hbase-common/src/main/java/org/apache/hadoop/hbase/io/crypto/CipherProvider.java index 6deb365..10d419a 100644 --- a/hbase-common/src/main/java/org/apache/hadoop/hbase/io/crypto/CipherProvider.java +++ b/hbase-common/src/main/java/org/apache/hadoop/hbase/io/crypto/CipherProvider.java @@ -25,7 +25,7 @@ import org.apache.hadoop.conf.Configurable; * Ciphers. */ @InterfaceAudience.Public -@InterfaceStability.Evolving +@InterfaceStability.Unstable public interface CipherProvider extends Configurable { /** diff --git a/hbase-common/src/main/java/org/apache/hadoop/hbase/io/crypto/Context.java b/hbase-common/src/main/java/org/apache/hadoop/hbase/io/crypto/Context.java index 31cca0e..223498c 100644 --- a/hbase-common/src/main/java/org/apache/hadoop/hbase/io/crypto/Context.java +++ b/hbase-common/src/main/java/org/apache/hadoop/hbase/io/crypto/Context.java @@ -31,7 +31,7 @@ import com.google.common.base.Preconditions; * Crypto context. Encapsulates an encryption algorithm and its key material. */ @InterfaceAudience.Public -@InterfaceStability.Evolving +@InterfaceStability.Unstable public class Context implements Configurable { private Configuration conf; private Cipher cipher; diff --git a/hbase-common/src/main/java/org/apache/hadoop/hbase/io/crypto/Decryptor.java b/hbase-common/src/main/java/org/apache/hadoop/hbase/io/crypto/Decryptor.java index d3029db..6dca315 100644 --- a/hbase-common/src/main/java/org/apache/hadoop/hbase/io/crypto/Decryptor.java +++ b/hbase-common/src/main/java/org/apache/hadoop/hbase/io/crypto/Decryptor.java @@ -27,7 +27,7 @@ import org.apache.hadoop.hbase.classification.InterfaceStability; * Decryptors apply a cipher to an InputStream to recover plaintext. */ @InterfaceAudience.Public -@InterfaceStability.Evolving +@InterfaceStability.Unstable public interface Decryptor { /** diff --git a/hbase-common/src/main/java/org/apache/hadoop/hbase/io/crypto/DefaultCipherProvider.java b/hbase-common/src/main/java/org/apache/hadoop/hbase/io/crypto/DefaultCipherProvider.java index 961fbae..08970b2 100644 --- a/hbase-common/src/main/java/org/apache/hadoop/hbase/io/crypto/DefaultCipherProvider.java +++ b/hbase-common/src/main/java/org/apache/hadoop/hbase/io/crypto/DefaultCipherProvider.java @@ -26,7 +26,7 @@ import org.apache.hadoop.hbase.io.crypto.aes.AES; * The default cipher provider. Supports AES via the JCE. */ @InterfaceAudience.Public -@InterfaceStability.Evolving +@InterfaceStability.Unstable public final class DefaultCipherProvider implements CipherProvider { private static DefaultCipherProvider instance; diff --git a/hbase-common/src/main/java/org/apache/hadoop/hbase/io/crypto/Encryption.java b/hbase-common/src/main/java/org/apache/hadoop/hbase/io/crypto/Encryption.java index 608c4b1..8c37ba2 100644 --- a/hbase-common/src/main/java/org/apache/hadoop/hbase/io/crypto/Encryption.java +++ b/hbase-common/src/main/java/org/apache/hadoop/hbase/io/crypto/Encryption.java @@ -47,7 +47,7 @@ import org.apache.hadoop.util.ReflectionUtils; * A facade for encryption algorithms and related support. */ @InterfaceAudience.Public -@InterfaceStability.Evolving +@InterfaceStability.Unstable public final class Encryption { private static final Log LOG = LogFactory.getLog(Encryption.class); diff --git a/hbase-common/src/main/java/org/apache/hadoop/hbase/io/crypto/Encryptor.java b/hbase-common/src/main/java/org/apache/hadoop/hbase/io/crypto/Encryptor.java index cda703d..b600f63 100644 --- a/hbase-common/src/main/java/org/apache/hadoop/hbase/io/crypto/Encryptor.java +++ b/hbase-common/src/main/java/org/apache/hadoop/hbase/io/crypto/Encryptor.java @@ -27,7 +27,7 @@ import org.apache.hadoop.hbase.classification.InterfaceStability; * Encryptors apply a cipher to an OutputStream to produce ciphertext. */ @InterfaceAudience.Public -@InterfaceStability.Evolving +@InterfaceStability.Unstable public interface Encryptor { /** diff --git a/hbase-common/src/main/java/org/apache/hadoop/hbase/io/crypto/KeyProvider.java b/hbase-common/src/main/java/org/apache/hadoop/hbase/io/crypto/KeyProvider.java index 515a664..2613c7e 100644 --- a/hbase-common/src/main/java/org/apache/hadoop/hbase/io/crypto/KeyProvider.java +++ b/hbase-common/src/main/java/org/apache/hadoop/hbase/io/crypto/KeyProvider.java @@ -27,7 +27,7 @@ import org.apache.hadoop.hbase.classification.InterfaceStability; * */ @InterfaceAudience.Public -@InterfaceStability.Evolving +@InterfaceStability.Unstable public interface KeyProvider { public static final String PASSWORD = "password"; diff --git a/hbase-common/src/main/java/org/apache/hadoop/hbase/io/crypto/KeyStoreKeyProvider.java b/hbase-common/src/main/java/org/apache/hadoop/hbase/io/crypto/KeyStoreKeyProvider.java index 0e5f36e..24e03c0 100644 --- a/hbase-common/src/main/java/org/apache/hadoop/hbase/io/crypto/KeyStoreKeyProvider.java +++ b/hbase-common/src/main/java/org/apache/hadoop/hbase/io/crypto/KeyStoreKeyProvider.java @@ -70,7 +70,7 @@ import org.apache.hadoop.hbase.classification.InterfaceStability; * LoadStoreParameters. */ @InterfaceAudience.Public -@InterfaceStability.Evolving +@InterfaceStability.Unstable public class KeyStoreKeyProvider implements KeyProvider { protected KeyStore store; diff --git a/hbase-server/src/main/java/org/apache/hadoop/hbase/mapreduce/CellCreator.java b/hbase-server/src/main/java/org/apache/hadoop/hbase/mapreduce/CellCreator.java index 001f64d..b5d8ed3 100644 --- a/hbase-server/src/main/java/org/apache/hadoop/hbase/mapreduce/CellCreator.java +++ b/hbase-server/src/main/java/org/apache/hadoop/hbase/mapreduce/CellCreator.java @@ -35,6 +35,7 @@ import org.apache.hadoop.util.ReflectionUtils; @InterfaceStability.Evolving public class CellCreator { + @InterfaceStability.Unstable public static final String VISIBILITY_EXP_RESOLVER_CLASS = "hbase.mapreduce.visibility.expression.resolver.class"; @@ -130,6 +131,7 @@ public class CellCreator { /** * @return Visibility expression resolver */ + @InterfaceStability.Unstable public VisibilityExpressionResolver getVisibilityExpressionResolver() { return this.visExpResolver; } diff --git a/hbase-server/src/main/java/org/apache/hadoop/hbase/mapreduce/ImportTsv.java b/hbase-server/src/main/java/org/apache/hadoop/hbase/mapreduce/ImportTsv.java index 6c154f5..96be181 100644 --- a/hbase-server/src/main/java/org/apache/hadoop/hbase/mapreduce/ImportTsv.java +++ b/hbase-server/src/main/java/org/apache/hadoop/hbase/mapreduce/ImportTsv.java @@ -119,16 +119,18 @@ public class ImportTsv extends Configured implements Tool { public static final String ATTRIBUTES_COLUMN_SPEC = "HBASE_ATTRIBUTES_KEY"; + @InterfaceStability.Unstable public static final String CELL_VISIBILITY_COLUMN_SPEC = "HBASE_CELL_VISIBILITY"; - + @InterfaceStability.Unstable public static final String CELL_TTL_COLUMN_SPEC = "HBASE_CELL_TTL"; private int attrKeyColumnIndex = DEFAULT_ATTRIBUTES_COLUMN_INDEX; public static final int DEFAULT_ATTRIBUTES_COLUMN_INDEX = -1; + @InterfaceStability.Unstable public static final int DEFAULT_CELL_VISIBILITY_COLUMN_INDEX = -1; - + @InterfaceStability.Unstable public static final int DEFAULT_CELL_TTL_COLUMN_INDEX = -1; private int cellVisibilityColumnIndex = DEFAULT_CELL_VISIBILITY_COLUMN_INDEX; @@ -200,10 +202,11 @@ public class ImportTsv extends Configured implements Tool { return attrKeyColumnIndex != DEFAULT_ATTRIBUTES_COLUMN_INDEX; } + @InterfaceStability.Unstable public boolean hasCellVisibility() { return cellVisibilityColumnIndex != DEFAULT_CELL_VISIBILITY_COLUMN_INDEX; } - + @InterfaceStability.Unstable public boolean hasCellTTL() { return cellTTLColumnIndex != DEFAULT_CELL_VISIBILITY_COLUMN_INDEX; } @@ -211,11 +214,11 @@ public class ImportTsv extends Configured implements Tool { public int getAttributesKeyColumnIndex() { return attrKeyColumnIndex; } - + @InterfaceStability.Unstable public int getCellVisibilityColumnIndex() { return cellVisibilityColumnIndex; } - + @InterfaceStability.Unstable public int getCellTTLColumnIndex() { return cellTTLColumnIndex; } diff --git a/hbase-server/src/main/java/org/apache/hadoop/hbase/mapreduce/TsvImporterMapper.java b/hbase-server/src/main/java/org/apache/hadoop/hbase/mapreduce/TsvImporterMapper.java index 270de75..031efa0 100644 --- a/hbase-server/src/main/java/org/apache/hadoop/hbase/mapreduce/TsvImporterMapper.java +++ b/hbase-server/src/main/java/org/apache/hadoop/hbase/mapreduce/TsvImporterMapper.java @@ -62,8 +62,9 @@ extends Mapper protected Configuration conf; + @InterfaceStability.Unstable protected String cellVisibilityExpr; - + @InterfaceStability.Unstable protected long ttl; protected CellCreator kvCreator; diff --git a/hbase-server/src/main/java/org/apache/hadoop/hbase/mapreduce/VisibilityExpressionResolver.java b/hbase-server/src/main/java/org/apache/hadoop/hbase/mapreduce/VisibilityExpressionResolver.java index 48d7708..b7a02c7 100644 --- a/hbase-server/src/main/java/org/apache/hadoop/hbase/mapreduce/VisibilityExpressionResolver.java +++ b/hbase-server/src/main/java/org/apache/hadoop/hbase/mapreduce/VisibilityExpressionResolver.java @@ -29,7 +29,7 @@ import org.apache.hadoop.hbase.Tag; * Interface to convert visibility expressions into Tags for storing along with Cells in HFiles. */ @InterfaceAudience.Public -@InterfaceStability.Evolving +@InterfaceStability.Unstable public interface VisibilityExpressionResolver extends Configurable { /** diff --git a/hbase-server/src/main/java/org/apache/hadoop/hbase/security/visibility/VisibilityExpEvaluator.java b/hbase-server/src/main/java/org/apache/hadoop/hbase/security/visibility/VisibilityExpEvaluator.java index a720127..8fcffa9 100644 --- a/hbase-server/src/main/java/org/apache/hadoop/hbase/security/visibility/VisibilityExpEvaluator.java +++ b/hbase-server/src/main/java/org/apache/hadoop/hbase/security/visibility/VisibilityExpEvaluator.java @@ -30,7 +30,7 @@ import org.apache.hadoop.hbase.Cell; * read results. */ @InterfaceAudience.Public -@InterfaceStability.Evolving +@InterfaceStability.Unstable public interface VisibilityExpEvaluator { /** diff --git a/hbase-server/src/main/java/org/apache/hadoop/hbase/security/visibility/VisibilityLabelService.java b/hbase-server/src/main/java/org/apache/hadoop/hbase/security/visibility/VisibilityLabelService.java index e01f986..3a1d036 100644 --- a/hbase-server/src/main/java/org/apache/hadoop/hbase/security/visibility/VisibilityLabelService.java +++ b/hbase-server/src/main/java/org/apache/hadoop/hbase/security/visibility/VisibilityLabelService.java @@ -34,7 +34,7 @@ import org.apache.hadoop.hbase.security.User; * visibility expression storage part and read time evaluation. */ @InterfaceAudience.Public -@InterfaceStability.Evolving +@InterfaceStability.Unstable public interface VisibilityLabelService extends Configurable { /** diff --git a/hbase-server/src/main/java/org/apache/hadoop/hbase/util/EncryptionTest.java b/hbase-server/src/main/java/org/apache/hadoop/hbase/util/EncryptionTest.java index 1cd6ead..ce047c6 100644 --- a/hbase-server/src/main/java/org/apache/hadoop/hbase/util/EncryptionTest.java +++ b/hbase-server/src/main/java/org/apache/hadoop/hbase/util/EncryptionTest.java @@ -36,7 +36,7 @@ import org.apache.hadoop.hbase.io.crypto.KeyStoreKeyProvider; import org.apache.hadoop.hbase.security.EncryptionUtil; @InterfaceAudience.Public -@InterfaceStability.Evolving +@InterfaceStability.Unstable public class EncryptionTest { static final Log LOG = LogFactory.getLog(EncryptionTest.class); diff --git a/hbase-server/src/test/java/org/apache/hadoop/hbase/io/hfile/TagUsage.java b/hbase-server/src/test/java/org/apache/hadoop/hbase/io/hfile/TagUsage.java index 747d640..d26fd4c 100644 --- a/hbase-server/src/test/java/org/apache/hadoop/hbase/io/hfile/TagUsage.java +++ b/hbase-server/src/test/java/org/apache/hadoop/hbase/io/hfile/TagUsage.java @@ -17,9 +17,13 @@ * limitations under the License. */ package org.apache.hadoop.hbase.io.hfile; + +import org.apache.hadoop.hbase.classification.InterfaceStability; + /** * Used in testcases only. */ +@InterfaceStability.Unstable public enum TagUsage { // No tags would be added NO_TAG,