class BlobStoreConfigurationValidationStartUpCheck implements StartUpCheck {

    @Override
    public CheckResult check() {
        try {
            eventsourcingStorageStrategy.registerStorageStrategy(blobStoreConfiguration.storageStrategy());
            return CheckResult.builder()
                .checkName(BLOB_STORE_CONFIGURATION_VALIDATION)
                .resultType(ResultType.GOOD)
                .build();
        } catch (IllegalStateException e) {
            return CheckResult.builder()
                .checkName(BLOB_STORE_CONFIGURATION_VALIDATION)
                .resultType(ResultType.BAD)
                .description(e.getMessage())
                .build();
        }
    }

    @VisibleForTesting @Inject  BlobStoreConfigurationValidationStartUpCheck(BlobStoreConfiguration blobStoreConfiguration, EventsourcingStorageStrategy eventsourcingStorageStrategy);

}