Search in sources :

Example 1 with ProjectionRepository

use of io.spine.server.projection.ProjectionRepository in project core-java by SpineEventEngine.

the class StandPostShould method projectionRepositoryDispatch.

private static BoundedContextAction projectionRepositoryDispatch() {
    return new BoundedContextAction() {

        @Override
        public void perform(BoundedContext context) {
            // Init repository
            final ProjectionRepository repository = Given.projectionRepo();
            repository.initStorage(storageFactory(context.isMultitenant()));
            // Dispatch an update from projection repo
            repository.dispatch(EventEnvelope.of(Given.validEvent()));
        }
    };
}
Also used : ProjectionRepository(io.spine.server.projection.ProjectionRepository) BoundedContext(io.spine.server.BoundedContext)

Aggregations

BoundedContext (io.spine.server.BoundedContext)1 ProjectionRepository (io.spine.server.projection.ProjectionRepository)1