jeantil commented on a change in pull request #474: URL: https://github.com/apache/james-project/pull/474#discussion_r646357441
########## File path: server/blob/blob-cassandra/src/main/java/org/apache/james/blob/cassandra/cache/CachedBlobStore.java ########## @@ -138,17 +138,19 @@ public InputStream read(BucketName bucketName, BlobId blobId, StoragePolicy stor if (storagePolicy == LOW_COST) { return backend.read(bucketName, blobId); } - return Mono.just(bucketName) - .filter(getDefaultBucketName()::equals) - .flatMap(defaultBucket -> readInDefaultBucket(bucketName, blobId)) - .switchIfEmpty(readFromBackend(bucketName, blobId)) + if (bucketName.equals(getDefaultBucketName())) { Review comment: I don't know if it improves performance but I find the updated code harder to read :/ ########## File path: server/protocols/jwt/src/main/java/org/apache/james/jwt/JwtTokenVerifier.java ########## @@ -60,6 +62,19 @@ public boolean verify(String token) { } } + public Optional<String> verifyAndExtractLogin(String token) { + try { Review comment: just curious but is [verify](https://github.com/apache/james-project/pull/474/commits/7fa7f7d10e70d70427e61c6eb2bdc0c6471dc3e0#diff-873db7c453d2864562c7bcb918d1ecea44a765268b48c079353e4144c18f1f6aR52) still useful ? it seems it could be implemented as `verifyAndExtractLogin().isPresent()` -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. For queries about this service, please contact Infrastructure at: us...@infra.apache.org --------------------------------------------------------------------- To unsubscribe, e-mail: notifications-unsubscr...@james.apache.org For additional commands, e-mail: notifications-h...@james.apache.org