diff options
author | Marek Gradzki <mgradzki@cisco.com> | 2017-03-21 13:38:21 +0100 |
---|---|---|
committer | Marek Gradzki <mgradzki@cisco.com> | 2017-03-22 08:58:00 +0100 |
commit | 3bd0a6a0bcd1cec006500c60de20eb0904697263 (patch) | |
tree | 847fedb3a20a63eac6cc20830d22c1d84f767564 /infra/translate-utils/src/main/java/io/fd/honeycomb/translate/util/read/cache/DumpCacheManager.java | |
parent | 9297f70f8a75fae4c3b5ad8fe7324a5420895352 (diff) |
HONEYCOMB-348: include dump params in entity key
Change-Id: I18b2ea3c897c467740f19bf346d13240aac458ac
Signed-off-by: Marek Gradzki <mgradzki@cisco.com>
Diffstat (limited to 'infra/translate-utils/src/main/java/io/fd/honeycomb/translate/util/read/cache/DumpCacheManager.java')
-rw-r--r-- | infra/translate-utils/src/main/java/io/fd/honeycomb/translate/util/read/cache/DumpCacheManager.java | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/infra/translate-utils/src/main/java/io/fd/honeycomb/translate/util/read/cache/DumpCacheManager.java b/infra/translate-utils/src/main/java/io/fd/honeycomb/translate/util/read/cache/DumpCacheManager.java index adcd32e0c..d3cfd415a 100644 --- a/infra/translate-utils/src/main/java/io/fd/honeycomb/translate/util/read/cache/DumpCacheManager.java +++ b/infra/translate-utils/src/main/java/io/fd/honeycomb/translate/util/read/cache/DumpCacheManager.java @@ -42,7 +42,7 @@ public final class DumpCacheManager<T, U> { private final EntityDumpExecutor<T, U> dumpExecutor; private final EntityDumpPostProcessingFunction<T> postProcessor; - private final CacheKeyFactory cacheKeyFactory; + private final CacheKeyFactory<U> cacheKeyFactory; private final Class<?> acceptOnly; private DumpCacheManager(DumpCacheManagerBuilder<T, U> builder) { @@ -66,7 +66,7 @@ public final class DumpCacheManager<T, U> { @Nonnull final ModificationCache cache, final U dumpParams) throws ReadFailedException { - final String entityKey = this.cacheKeyFactory.createKey(identifier); + final String entityKey = this.cacheKeyFactory.createKey(identifier, dumpParams); // this key binding to every log has its logic ,because every customizer have its own cache manager and if // there is need for debugging/fixing some complex call with a lot of data,you can get lost in those logs LOG.debug("Loading dump for KEY[{}]", entityKey); @@ -120,7 +120,7 @@ public final class DumpCacheManager<T, U> { /** * Key providing unique(type-aware) keys. */ - public DumpCacheManagerBuilder<T, U> withCacheKeyFactory(@Nonnull final CacheKeyFactory cacheKeyFactory) { + public DumpCacheManagerBuilder<T, U> withCacheKeyFactory(@Nonnull final CacheKeyFactory<U> cacheKeyFactory) { this.cacheKeyFactory = cacheKeyFactory; return this; } |