googleapis / googleapis/google-cloud-java

[java-spanner] AsyncTransactionManager.CommitTimestampFuture violates Future.get contract

Ouverte
#12,251 1 commentaire 0 réactions 1 personne assignée Assignée à @sakthivelmanii Voir sur GitHub
api: spanner
Langage dominant
Java
Étoiles
2.1k
Forks
1.2k
Merge moyen
1 j 23 h
PR mergées (30 j)
154

Description

`CommitTimestampFuture` violates the `Future` contract by overriding `get()` to throw any caught exception other than `ExecutionException`. Namely, it unwraps any `AbortedException` and throws that directly.

This breaks any downstream code that operates on that `CommitTimestampFuture` via the `Future` interface. For example, transforming it to a Guava `ListenableFuture` and then calling the `kotlinx.coroutines.guava.await` extension function on it.

Guide de contribution

Ouvrir le guide de contribution

Évaluation

Cette issue n'a pas encore été évaluée.

Recevez les nouvelles issues par e-mail

Un résumé court des issues GitHub adaptées aux débutants.