This is an automated email from the ASF dual-hosted git repository. btellier pushed a commit to branch fix-build in repository https://gitbox.apache.org/repos/asf/james-project.git
commit 3a7de34198594a00674000ef37ce574108d5214c Author: Benoit TELLIER <[email protected]> AuthorDate: Fri Dec 6 22:06:26 2024 +0100 Revert "[FIX] Run blobIdProvider out of driver threads (#2544)" This reverts commit c5750468c2b352118d8e13f4355a49b95e25f018. --- .../server/blob/deduplication/DeDuplicationBlobStore.scala | 11 +++++------ 1 file changed, 5 insertions(+), 6 deletions(-) diff --git a/server/blob/blob-storage-strategy/src/main/scala/org/apache/james/server/blob/deduplication/DeDuplicationBlobStore.scala b/server/blob/blob-storage-strategy/src/main/scala/org/apache/james/server/blob/deduplication/DeDuplicationBlobStore.scala index dda70bf4c3..ace4cd5510 100644 --- a/server/blob/blob-storage-strategy/src/main/scala/org/apache/james/server/blob/deduplication/DeDuplicationBlobStore.scala +++ b/server/blob/blob-storage-strategy/src/main/scala/org/apache/james/server/blob/deduplication/DeDuplicationBlobStore.scala @@ -124,12 +124,11 @@ class DeDuplicationBlobStore @Inject()(blobStoreDAO: BlobStoreDAO, .map(blobIdFactory.of) .map(blobId => Tuples.of(blobId, data)) - private def withBlobIdFromArray: BlobIdProvider[Array[Byte]] = data => - SMono.fromCallable(() => { - val code = Hashing.sha256.hashBytes(data) - val blobId = blobIdFactory.of(base64(code)) - Tuples.of(blobId, data) - }).subscribeOn(Schedulers.parallel()) + private def withBlobIdFromArray: BlobIdProvider[Array[Byte]] = data => { + val code = Hashing.sha256.hashBytes(data) + val blobId = blobIdFactory.of(base64(code)) + Mono.just(Tuples.of(blobId, data)) + } private def base64(hashCode: HashCode) = { val bytes = hashCode.asBytes --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
