Allow to use CamelCatalog in cache mode
Project: http://git-wip-us.apache.org/repos/asf/camel/repo Commit: http://git-wip-us.apache.org/repos/asf/camel/commit/5c4f0087 Tree: http://git-wip-us.apache.org/repos/asf/camel/tree/5c4f0087 Diff: http://git-wip-us.apache.org/repos/asf/camel/diff/5c4f0087 Branch: refs/heads/camel-2.16.x Commit: 5c4f00876415d09962c15f0e851410dab2f25bc2 Parents: 5566003 Author: Claus Ibsen <davscl...@apache.org> Authored: Wed Dec 30 12:28:37 2015 +0100 Committer: Claus Ibsen <davscl...@apache.org> Committed: Wed Dec 30 12:29:07 2015 +0100 ---------------------------------------------------------------------- .../apache/camel/catalog/DefaultCamelCatalog.java | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/camel/blob/5c4f0087/platforms/catalog/src/main/java/org/apache/camel/catalog/DefaultCamelCatalog.java ---------------------------------------------------------------------- diff --git a/platforms/catalog/src/main/java/org/apache/camel/catalog/DefaultCamelCatalog.java b/platforms/catalog/src/main/java/org/apache/camel/catalog/DefaultCamelCatalog.java index dc23d3b..3cde7ba 100644 --- a/platforms/catalog/src/main/java/org/apache/camel/catalog/DefaultCamelCatalog.java +++ b/platforms/catalog/src/main/java/org/apache/camel/catalog/DefaultCamelCatalog.java @@ -380,7 +380,7 @@ public class DefaultCamelCatalog implements CamelCatalog { String answer = null; if (caching) { - answer = (String) cache.get(file); + answer = (String) cache.get("model-" + file); } if (answer == null) { @@ -393,7 +393,7 @@ public class DefaultCamelCatalog implements CamelCatalog { } } if (caching) { - cache.put(file, answer); + cache.put("model-" + file, answer); } } @@ -406,7 +406,7 @@ public class DefaultCamelCatalog implements CamelCatalog { String answer = null; if (caching) { - answer = (String) cache.get(file); + answer = (String) cache.get("component-" + file); } if (answer == null) { @@ -435,7 +435,7 @@ public class DefaultCamelCatalog implements CamelCatalog { } } if (caching) { - cache.put(file, answer); + cache.put("component-" + file, answer); } } @@ -448,7 +448,7 @@ public class DefaultCamelCatalog implements CamelCatalog { String answer = null; if (caching) { - answer = (String) cache.get(file); + answer = (String) cache.get("dataformat-" + file); } if (answer == null) { @@ -477,7 +477,7 @@ public class DefaultCamelCatalog implements CamelCatalog { } } if (caching) { - cache.put(file, answer); + cache.put("dataformat-" + file, answer); } } @@ -490,7 +490,7 @@ public class DefaultCamelCatalog implements CamelCatalog { String answer = null; if (caching) { - answer = (String) cache.get(file); + answer = (String) cache.get("language-" + file); } if (answer == null) { @@ -503,7 +503,7 @@ public class DefaultCamelCatalog implements CamelCatalog { } } if (caching) { - cache.put(file, answer); + cache.put("language-" + file, answer); } }