private FriendRepository friendRepository;
@CacheEvict(value = "group-user-cache", allEntries = true)
public void createGroup(String name, String description, boolean publicGroup) {
log.debug("Creating group : {}", name);
User currentUser = authenticationService.getCurrentUser();
String domain = DomainUtil.getDomainFromLogin(currentUser.getLogin());
String groupId = groupRepository.createGroup(domain);
groupDetailsRepository.createGroupDetails(groupId, name, description, publicGroup);
groupMembersRepository.addAdmin(groupId, currentUser.getLogin());
groupCounterRepository.incrementGroupCounter(domain, groupId);
userGroupRepository.addGroupAsAdmin(currentUser.getLogin(), groupId);
Group group = getGroupById(domain, groupId);
searchService.addGroup(group);
}