From a160cd7ea83f1a17ef822012f52226ae8d3c0e06 Mon Sep 17 00:00:00 2001 From: jmaxwell Date: Tue, 13 Feb 2018 10:14:09 -0600 Subject: [PATCH] 1215 CachingCachingRegistryClient stores data by wrong keys resulting in fetch operations always missing. Resolves #1216 --- .../cloud/stream/schema/client/CachingRegistryClient.java | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/spring-cloud-stream-schema/src/main/java/org/springframework/cloud/stream/schema/client/CachingRegistryClient.java b/spring-cloud-stream-schema/src/main/java/org/springframework/cloud/stream/schema/client/CachingRegistryClient.java index e661b3f17..304c06fc0 100644 --- a/spring-cloud-stream-schema/src/main/java/org/springframework/cloud/stream/schema/client/CachingRegistryClient.java +++ b/spring-cloud-stream-schema/src/main/java/org/springframework/cloud/stream/schema/client/CachingRegistryClient.java @@ -47,8 +47,8 @@ public class CachingRegistryClient implements SchemaRegistryClient { @Override public SchemaRegistrationResponse register(String subject, String format, String schema) { SchemaRegistrationResponse response = delegate.register(subject, format, schema); - cacheManager.getCache(ID_CACHE).put(response.getSchemaReference(), schema); - cacheManager.getCache(REF_CACHE).put(response.getId(), schema); + cacheManager.getCache(ID_CACHE).put(response.getId(), schema); + cacheManager.getCache(REF_CACHE).put(response.getSchemaReference(), schema); return response; }