lhotari commented on code in PR #23298:
URL: https://github.com/apache/pulsar/pull/23298#discussion_r1757281311
##########
pulsar-metadata/src/main/java/org/apache/pulsar/metadata/cache/impl/MetadataCacheImpl.java:
##########
@@ -243,6 +243,17 @@ public CompletableFuture<Void> create(String path, T
value) {
return future;
}
+ @Override
+ public CompletableFuture<Void> put(String path, T value) {
+ final byte[] bytes;
+ try {
+ bytes = serde.serialize(path, value);
+ } catch (IOException e) {
+ return CompletableFuture.failedFuture(e);
+ }
+ return store.put(path, bytes, Optional.empty()).thenAccept(__ -> {});
Review Comment:
`.thenAccept(__ -> refresh(path))` would be aligned how the other operations
handle cache invalidation and refreshing.
--
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.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]