@@ -632,7 +632,7 @@ public void setDatabaseClient(DatabaseClient client) {
632
632
dbClient = client ;
633
633
}
634
634
635
- /** Return a list of serviceKeyFile column types of the given table. */
635
+ /** Return a list of key column types of the given table. */
636
636
public List <com .google .spanner .v1 .Type > getKeyColumnTypes (String tableName )
637
637
throws SpannerException {
638
638
Preconditions .checkNotNull (metadata );
@@ -2381,7 +2381,7 @@ private Status executeRead(
2381
2381
String .format ("Executing read %s\n %s\n " , executionContext .getTransactionSeed (), action ));
2382
2382
List <com .google .spanner .v1 .Type > typeList = new ArrayList <>();
2383
2383
if (action .hasIndex ()) {
2384
- // For index read, we assume the serviceKeyFile columns are listed at the front of the read
2384
+ // For index read, we assume the key columns are listed at the front of the read
2385
2385
// column
2386
2386
// list.
2387
2387
for (int i = 0 ; i < action .getColumnCount (); ++i ) {
@@ -2900,19 +2900,19 @@ private static com.google.cloud.spanner.KeyRange keyRangeProtoToCloudKeyRange(
2900
2900
// Unreachable.
2901
2901
default :
2902
2902
throw SpannerExceptionFactory .newSpannerException (
2903
- ErrorCode .INVALID_ARGUMENT , "Unrecognized serviceKeyFile range type" );
2903
+ ErrorCode .INVALID_ARGUMENT , "Unrecognized key range type" );
2904
2904
}
2905
2905
}
2906
2906
2907
- /** Convert a serviceKeyFile proto(value list) to a cloud Key. */
2907
+ /** Convert a key proto(value list) to a cloud Key. */
2908
2908
private static com .google .cloud .spanner .Key keyProtoToCloudKey (
2909
2909
com .google .spanner .executor .v1 .ValueList keyProto , List <com .google .spanner .v1 .Type > typeList )
2910
2910
throws SpannerException {
2911
2911
com .google .cloud .spanner .Key .Builder cloudKey = com .google .cloud .spanner .Key .newBuilder ();
2912
2912
if (typeList .size () < keyProto .getValueCount ()) {
2913
2913
throw SpannerExceptionFactory .newSpannerException (
2914
2914
ErrorCode .INVALID_ARGUMENT ,
2915
- "There's more serviceKeyFile parts in " + keyProto + " than column types in " + typeList );
2915
+ "There's more key parts in " + keyProto + " than column types in " + typeList );
2916
2916
}
2917
2917
2918
2918
for (int i = 0 ; i < keyProto .getValueCount (); ++i ) {
@@ -2934,7 +2934,7 @@ private static com.google.cloud.spanner.Key keyProtoToCloudKey(
2934
2934
default :
2935
2935
throw SpannerExceptionFactory .newSpannerException (
2936
2936
ErrorCode .INVALID_ARGUMENT ,
2937
- "Unsupported null serviceKeyFile part type: " + type .getCode ().name ());
2937
+ "Unsupported null key part type: " + type .getCode ().name ());
2938
2938
}
2939
2939
} else if (part .hasIntValue ()) {
2940
2940
cloudKey .append (part .getIntValue ());
@@ -2953,8 +2953,7 @@ private static com.google.cloud.spanner.Key keyProtoToCloudKey(
2953
2953
// Unreachable
2954
2954
default :
2955
2955
throw SpannerExceptionFactory .newSpannerException (
2956
- ErrorCode .INVALID_ARGUMENT ,
2957
- "Unsupported serviceKeyFile part type: " + type .getCode ().name ());
2956
+ ErrorCode .INVALID_ARGUMENT , "Unsupported key part type: " + type .getCode ().name ());
2958
2957
}
2959
2958
} else if (part .hasStringValue ()) {
2960
2959
if (type .getCode () == TypeCode .NUMERIC ) {
@@ -2969,7 +2968,7 @@ private static com.google.cloud.spanner.Key keyProtoToCloudKey(
2969
2968
cloudKey .append (dateFromDays (part .getDateDaysValue ()));
2970
2969
} else {
2971
2970
throw SpannerExceptionFactory .newSpannerException (
2972
- ErrorCode .INVALID_ARGUMENT , "Unsupported serviceKeyFile part: " + part );
2971
+ ErrorCode .INVALID_ARGUMENT , "Unsupported key part: " + part );
2973
2972
}
2974
2973
}
2975
2974
return cloudKey .build ();
0 commit comments