code: CompletableFuture<Collection<Xid>> fetchPreparedTransactions() {
        try {
           TransactionOperationFactory factory = assertStartedAndReturnFactory();
           return factory.newRecoveryOperation().execute();
        } catch (Exception e) {
           if (isTraceLogEnabled()) {
              getLog().trace("Exception while fetching prepared transactions", e);
           }
           return CompletableFuture.completedFuture(Collections.emptyList());
        }
     }
docs: It requests the server for all in-doubt prepared transactions, to be handled by the recovery process.
  
  @return A {@link CompletableFuture} which is completed with a collections of transaction {@link Xid}.