October 2018
Intermediate to advanced
590 pages
15h 5m
English
In our application core, we will need to create two application services, TeamService and BoardService, to provide the abilities that Controller requires. As mentioned earlier, application services need to be kept as thin as possible; they should try not to involve any business logic because business logic should be kept inside domain models and domain services.
The following is the implementation of com.taskagile.domain.application.TeamService:
@Service@Transactionalpublic class TeamServiceImpl implements TeamService { ... @Override public List<Team> findTeamsByUserId(UserId userId) { return teamRepository.findTeamsByUserId(userId); } @Override public Team createTeam(CreateTeamCommand command) { Team team = Team.create(command.getName(), ...Read now
Unlock full access