docs: public void add(DbSession dbSession, String channel, String dispatcher, UserDto user, @Nullable ComponentDto project) {
      String key = String.join(".", PROP_NOTIFICATION_PREFIX, dispatcher, channel);
      Long projectId = project == null ? null : project.getId();
  
      List<PropertyDto> existingNotification = dbClient.propertiesDao().selectByQuery(
        PropertyQuery.builder()
          .setKey(key)
          .setComponentId(projectId)
          .setUserId(user.getId())
          .build(),
        dbSession).stream()
        .filter(notificationScope(project))
        .collect(MoreCollectors.toList());
      checkArgument(existingNotification.isEmpty()
        || !PROP_NOTIFICATION_VALUE.equals(existingNotification.get(0).getValue()), "Notification already added");
  
      dbClient.propertiesDao().saveProperty(dbSession, new PropertyDto()
        .setKey(key)
        .setUserId(user.getId())
        .setValue(PROP_NOTIFICATION_VALUE)
        .setResourceId(projectId));
    }