f (order.total == 0.0) {
             // lookups require application component namespace:
             try (Connection con = ((DataSource)
                     InitialContext.doLookup(
                             "java:comp/env/jdbc/ds1"))
                     .getConnection()) {
                 order.total = ...
             } catch (NamingException | SQLException x) {
                 throw new CompletionException(x);
             }
         }
         return order.total;
      })
     .reduce(0.0, Doub