@@ -646,7 +646,7 @@ private String generateSessionName(String database) {
646646 }
647647
648648 private ByteString generateTransactionName (
649- String session , com . google . spanner . v1 . Mutation mutation ) {
649+ String session , String mutation ) {
650650 AtomicLong counter = transactionCounters .get (session );
651651 if (counter == null ) {
652652 counter = new AtomicLong ();
@@ -655,7 +655,7 @@ private ByteString generateTransactionName(
655655 transactionToTrace .put (
656656 session ,
657657 String .format (
658- "%s %s" , mutation . toString () , Arrays .toString (Thread .currentThread ().getStackTrace ())));
658+ "%s %s" , mutation , Arrays .toString (Thread .currentThread ().getStackTrace ())));
659659 return ByteString .copyFromUtf8 (
660660 String .format ("%s/transactions/%d" , session , counter .incrementAndGet ()));
661661 }
@@ -1914,7 +1914,7 @@ public void beginTransaction(
19141914
19151915 private Transaction beginTransaction (
19161916 Session session , TransactionOptions options , com .google .spanner .v1 .Mutation mutationKey ) {
1917- ByteString transactionId = generateTransactionName (session .getName (), mutationKey );
1917+ ByteString transactionId = generateTransactionName (session .getName (), mutationKey . toString () );
19181918 Transaction .Builder builder = Transaction .newBuilder ().setId (transactionId );
19191919 if (options != null && options .getModeCase () == ModeCase .READ_ONLY ) {
19201920 setReadTimestamp (options , builder );
0 commit comments