Modified: accumulo/branches/ACCUMULO-259/core/src/main/java/org/apache/accumulo/core/security/thrift/AuthInfo.java URL: http://svn.apache.org/viewvc/accumulo/branches/ACCUMULO-259/core/src/main/java/org/apache/accumulo/core/security/thrift/AuthInfo.java?rev=1437605&r1=1437604&r2=1437605&view=diff ============================================================================== --- accumulo/branches/ACCUMULO-259/core/src/main/java/org/apache/accumulo/core/security/thrift/AuthInfo.java (original) +++ accumulo/branches/ACCUMULO-259/core/src/main/java/org/apache/accumulo/core/security/thrift/AuthInfo.java Wed Jan 23 18:05:10 2013 @@ -22,37 +22,32 @@ */ package org.apache.accumulo.core.security.thrift; +import java.nio.ByteBuffer; +import java.util.BitSet; +import java.util.Collections; +import java.util.EnumMap; +import java.util.EnumSet; +import java.util.HashMap; +import java.util.Map; + +import org.apache.thrift.protocol.TTupleProtocol; import org.apache.thrift.scheme.IScheme; import org.apache.thrift.scheme.SchemeFactory; import org.apache.thrift.scheme.StandardScheme; - import org.apache.thrift.scheme.TupleScheme; -import org.apache.thrift.protocol.TTupleProtocol; -import org.apache.thrift.protocol.TProtocolException; -import org.apache.thrift.EncodingUtils; -import org.apache.thrift.TException; -import java.util.List; -import java.util.ArrayList; -import java.util.Map; -import java.util.HashMap; -import java.util.EnumMap; -import java.util.Set; -import java.util.HashSet; -import java.util.EnumSet; -import java.util.Collections; -import java.util.BitSet; -import java.nio.ByteBuffer; -import java.util.Arrays; -import org.slf4j.Logger; -import org.slf4j.LoggerFactory; -@SuppressWarnings("all") public class AuthInfo implements org.apache.thrift.TBase<AuthInfo, AuthInfo._Fields>, java.io.Serializable, Cloneable { +/** + * @deprecated since 1.5, use {@link#UserPassToken} instead + */ +@SuppressWarnings("serial") +public class AuthInfo implements org.apache.thrift.TBase<AuthInfo, AuthInfo._Fields>, java.io.Serializable, Cloneable { private static final org.apache.thrift.protocol.TStruct STRUCT_DESC = new org.apache.thrift.protocol.TStruct("AuthInfo"); private static final org.apache.thrift.protocol.TField USER_FIELD_DESC = new org.apache.thrift.protocol.TField("user", org.apache.thrift.protocol.TType.STRING, (short)1); private static final org.apache.thrift.protocol.TField PASSWORD_FIELD_DESC = new org.apache.thrift.protocol.TField("password", org.apache.thrift.protocol.TType.STRING, (short)2); private static final org.apache.thrift.protocol.TField INSTANCE_ID_FIELD_DESC = new org.apache.thrift.protocol.TField("instanceId", org.apache.thrift.protocol.TType.STRING, (short)3); + @SuppressWarnings("rawtypes") private static final Map<Class<? extends IScheme>, SchemeFactory> schemes = new HashMap<Class<? extends IScheme>, SchemeFactory>(); static { schemes.put(StandardScheme.class, new AuthInfoStandardSchemeFactory()); @@ -418,10 +413,12 @@ import org.slf4j.LoggerFactory; return _Fields.findByThriftId(fieldId); } + @SuppressWarnings("unchecked") public void read(org.apache.thrift.protocol.TProtocol iprot) throws org.apache.thrift.TException { schemes.get(iprot.getScheme()).getScheme().read(iprot, this); } + @SuppressWarnings("unchecked") public void write(org.apache.thrift.protocol.TProtocol oprot) throws org.apache.thrift.TException { schemes.get(oprot.getScheme()).getScheme().write(oprot, this); } @@ -480,6 +477,7 @@ import org.slf4j.LoggerFactory; } private static class AuthInfoStandardSchemeFactory implements SchemeFactory { + @SuppressWarnings("unchecked") public AuthInfoStandardScheme getScheme() { return new AuthInfoStandardScheme(); } @@ -558,6 +556,7 @@ import org.slf4j.LoggerFactory; } private static class AuthInfoTupleSchemeFactory implements SchemeFactory { + @SuppressWarnings("unchecked") public AuthInfoTupleScheme getScheme() { return new AuthInfoTupleScheme(); }
Modified: accumulo/branches/ACCUMULO-259/core/src/main/java/org/apache/accumulo/core/security/thrift/SecurityErrorCode.java URL: http://svn.apache.org/viewvc/accumulo/branches/ACCUMULO-259/core/src/main/java/org/apache/accumulo/core/security/thrift/SecurityErrorCode.java?rev=1437605&r1=1437604&r2=1437605&view=diff ============================================================================== --- accumulo/branches/ACCUMULO-259/core/src/main/java/org/apache/accumulo/core/security/thrift/SecurityErrorCode.java (original) +++ accumulo/branches/ACCUMULO-259/core/src/main/java/org/apache/accumulo/core/security/thrift/SecurityErrorCode.java Wed Jan 23 18:05:10 2013 @@ -38,7 +38,8 @@ import org.apache.thrift.TEnum; BAD_AUTHORIZATIONS(7), INVALID_INSTANCEID(8), TABLE_DOESNT_EXIST(9), - UNSUPPORTED_OPERATION(10); + UNSUPPORTED_OPERATION(10), + INVALID_TOKEN(11); private final int value; @@ -81,6 +82,8 @@ import org.apache.thrift.TEnum; return TABLE_DOESNT_EXIST; case 10: return UNSUPPORTED_OPERATION; + case 11: + return INVALID_TOKEN; default: return null; }
