Repository: incubator-ignite Updated Branches: refs/heads/ignite-648 b40aba162 -> dd813e704
ignite-648: set grid logger to null Project: http://git-wip-us.apache.org/repos/asf/incubator-ignite/repo Commit: http://git-wip-us.apache.org/repos/asf/incubator-ignite/commit/dd813e70 Tree: http://git-wip-us.apache.org/repos/asf/incubator-ignite/tree/dd813e70 Diff: http://git-wip-us.apache.org/repos/asf/incubator-ignite/diff/dd813e70 Branch: refs/heads/ignite-648 Commit: dd813e704b09f6ec144da828facd63f68690ad00 Parents: b40aba1 Author: Artem Shutak <ashu...@gridgain.com> Authored: Wed May 13 16:46:55 2015 +0300 Committer: Artem Shutak <ashu...@gridgain.com> Committed: Wed May 13 16:46:55 2015 +0300 ---------------------------------------------------------------------- .../cache/multijvm/framework/IgniteNodeRunner.java | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/dd813e70/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/multijvm/framework/IgniteNodeRunner.java ---------------------------------------------------------------------- diff --git a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/multijvm/framework/IgniteNodeRunner.java b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/multijvm/framework/IgniteNodeRunner.java index f5b2f31..b591202 100644 --- a/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/multijvm/framework/IgniteNodeRunner.java +++ b/modules/core/src/test/java/org/apache/ignite/internal/processors/cache/multijvm/framework/IgniteNodeRunner.java @@ -61,6 +61,14 @@ public class IgniteNodeRunner { } } + /** + * Stores {@link IgniteConfiguration} to file as xml. + * + * @param cfg Ignite Configuration. + * @return A name of file where the configuration was stored. + * @throws IOException If failed. + * @see #readCfgFromFileAndDeleteFile(String) + */ public static String storeToFile(IgniteConfiguration cfg) throws IOException { String fileName = IGNITE_CONFIGURATION_FILE + cfg.getNodeId(); @@ -68,6 +76,7 @@ public class IgniteNodeRunner { cfg.setMBeanServer(null); cfg.setMarshaller(null); cfg.setDiscoverySpi(null); + cfg.setGridLogger(null); new XStream().toXML(cfg, out); } @@ -75,6 +84,14 @@ public class IgniteNodeRunner { return fileName; } + /** + * Reads configuration from given file and delete the file after. + * + * @param fileName File name. + * @return Readed configuration. + * @throws IOException If failed. + * @see #storeToFile(IgniteConfiguration) + */ private static IgniteConfiguration readCfgFromFileAndDeleteFile(String fileName) throws IOException { try(BufferedReader cfgReader = new BufferedReader(new FileReader(fileName))) { IgniteConfiguration cfg = (IgniteConfiguration)new XStream().fromXML(cfgReader);