lhotari commented on code in PR #23354:
URL: https://github.com/apache/pulsar/pull/23354#discussion_r1793331624


##########
pulsar-broker/src/main/java/org/apache/pulsar/broker/service/schema/SchemaRegistryServiceImpl.java:
##########
@@ -133,7 +133,17 @@ public CompletableFuture<SchemaAndMetadata> 
getSchema(String schemaId, SchemaVer
                     } else {
                         return Functions.bytesToSchemaInfo(stored.data)
                                 .thenApply(Functions::schemaInfoToSchema)
-                                .thenApply(schema -> new 
SchemaAndMetadata(schemaId, schema, stored.version));
+                                .thenApply(schema -> new 
SchemaAndMetadata(schemaId, schema, stored.version))
+                                .thenApply((schema) -> {
+                                    if (version == SchemaVersion.Latest) {

Review Comment:
   > changes are covered in `SchemaServiceTest.java`
   
   @nikam14 Please add a test that shows that this change was needed. I don't 
see any test changes in this PR, so that is missing.



-- 
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]

Reply via email to