@Test void cacheShouldNotPropagateFailures(CassandraCluster cassandra) { cassandra.getConf().registerScenario(fail() .forever() .whenQueryStartsWith("INSERT INTO blob_cache (id,data) VALUES (:id,:data) USING TTL :ttl;")); BlobId blobId = blobIdFactory().randomId(); assertThatCode(() -> Mono.from(testee.cache(blobId, EIGHT_KILOBYTES)).block()) .doesNotThrowAnyException(); }
@Override public Mono<Void> cache(BlobId blobId, byte[] bytes) { return save(blobId, toByteBuffer(bytes)); }
CassandraBlobStoreCache implements BlobStoreCache { @Override public Mono<Void> cache(BlobId blobId, byte[] bytes) { return save(blobId, toByteBuffer(bytes)); } }
CassandraBlobStoreCache implements BlobStoreCache { @Override public Mono<Void> cache(BlobId blobId, byte[] bytes) { return save(blobId, toByteBuffer(bytes)); } @Inject @VisibleForTesting  CassandraBlobStoreCache(@Named(InjectionNames.CACHE) Session session,
                            CassandraCacheConfiguration cacheConfiguration); }
CassandraBlobStoreCache implements BlobStoreCache { @Override public Mono<Void> cache(BlobId blobId, byte[] bytes) { return save(blobId, toByteBuffer(bytes)); } @Inject @VisibleForTesting  CassandraBlobStoreCache(@Named(InjectionNames.CACHE) Session session,
                            CassandraCacheConfiguration cacheConfiguration); @Override Mono<Void> cache(BlobId blobId, byte[] bytes); @Override Mono<byte[]> read(BlobId blobId); @Override Mono<Void> remove(BlobId blobId); }
CassandraBlobStoreCache implements BlobStoreCache { @Override public Mono<Void> cache(BlobId blobId, byte[] bytes) { return save(blobId, toByteBuffer(bytes)); } @Inject @VisibleForTesting  CassandraBlobStoreCache(@Named(InjectionNames.CACHE) Session session,
                            CassandraCacheConfiguration cacheConfiguration); @Override Mono<Void> cache(BlobId blobId, byte[] bytes); @Override Mono<byte[]> read(BlobId blobId); @Override Mono<Void> remove(BlobId blobId); static final Logger LOGGER; }