@Override @HasPermission(action = UGC_READ, type = SocialPermission.class) public long countChildren(final String ugcId, final String contextId) throws UGCException { try { return ugcRepository.countChildrenOf(contextId, ugcId); } catch (MongoDataException ex) { log.error("logging.ugc.unableToCount", ex); throw new UGCException("Unable to count children of Ugc"); } }