@Test void fixMailboxInconsistenciesShouldUpdateContextWhenOrphanPathData() { Context context = new Context(); mailboxPathV2DAO.save(MAILBOX_PATH, CASSANDRA_ID_1).block(); testee.fixMailboxInconsistencies(context).block(); assertThat(context.snapshot()) .isEqualTo(Context.builder() .processedMailboxPathEntries(1) .addFixedInconsistencies(CASSANDRA_ID_1) .build() .snapshot()); }
public Mono<Result> fixMailboxInconsistencies(Context context) { assertValidVersion(); return Flux.concat( processMailboxDaoInconsistencies(context), processMailboxPathDaoInconsistencies(context)) .reduce(Result.COMPLETED, Task::combine); }
SolveMailboxInconsistenciesService { public Mono<Result> fixMailboxInconsistencies(Context context) { assertValidVersion(); return Flux.concat( processMailboxDaoInconsistencies(context), processMailboxPathDaoInconsistencies(context)) .reduce(Result.COMPLETED, Task::combine); } }
SolveMailboxInconsistenciesService { public Mono<Result> fixMailboxInconsistencies(Context context) { assertValidVersion(); return Flux.concat( processMailboxDaoInconsistencies(context), processMailboxPathDaoInconsistencies(context)) .reduce(Result.COMPLETED, Task::combine); } @Inject  SolveMailboxInconsistenciesService(CassandraMailboxDAO mailboxDAO, CassandraMailboxPathV2DAO mailboxPathV2DAO, CassandraSchemaVersionManager versionManager); }
SolveMailboxInconsistenciesService { public Mono<Result> fixMailboxInconsistencies(Context context) { assertValidVersion(); return Flux.concat( processMailboxDaoInconsistencies(context), processMailboxPathDaoInconsistencies(context)) .reduce(Result.COMPLETED, Task::combine); } @Inject  SolveMailboxInconsistenciesService(CassandraMailboxDAO mailboxDAO, CassandraMailboxPathV2DAO mailboxPathV2DAO, CassandraSchemaVersionManager versionManager); Mono<Result> fixMailboxInconsistencies(Context context); }
SolveMailboxInconsistenciesService { public Mono<Result> fixMailboxInconsistencies(Context context) { assertValidVersion(); return Flux.concat( processMailboxDaoInconsistencies(context), processMailboxPathDaoInconsistencies(context)) .reduce(Result.COMPLETED, Task::combine); } @Inject  SolveMailboxInconsistenciesService(CassandraMailboxDAO mailboxDAO, CassandraMailboxPathV2DAO mailboxPathV2DAO, CassandraSchemaVersionManager versionManager); Mono<Result> fixMailboxInconsistencies(Context context); static final Logger LOGGER; }