Esempio n. 1
0
 @Override
 public Set<Change.Id> getStarredChanges() {
   if (starredChanges == null) {
     checkRequestScope();
     try {
       starredChanges = starredChangeIds(starredQuery != null ? starredQuery : starredQuery());
     } catch (OrmException | RuntimeException e) {
       log.warn("Cannot query starred changes", e);
       starredChanges = Collections.emptySet();
     } finally {
       starredQuery = null;
     }
   }
   return starredChanges;
 }
Esempio n. 2
0
 @Override
 public Collection<AccountProjectWatch> getNotificationFilters() {
   if (notificationFilters == null) {
     checkRequestScope();
     List<AccountProjectWatch> r;
     try {
       r =
           dbProvider
               .get()
               .accountProjectWatches() //
               .byAccount(getAccountId())
               .toList();
     } catch (OrmException e) {
       log.warn("Cannot query notification filters of a user", e);
       r = Collections.emptyList();
     }
     notificationFilters = Collections.unmodifiableList(r);
   }
   return notificationFilters;
 }