You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@ignite.apache.org by sb...@apache.org on 2015/03/01 13:40:05 UTC
[12/37] incubator-ignite git commit: #ignite-311: small fix.
#ignite-311: small fix.
Project: http://git-wip-us.apache.org/repos/asf/incubator-ignite/repo
Commit: http://git-wip-us.apache.org/repos/asf/incubator-ignite/commit/63c3f549
Tree: http://git-wip-us.apache.org/repos/asf/incubator-ignite/tree/63c3f549
Diff: http://git-wip-us.apache.org/repos/asf/incubator-ignite/diff/63c3f549
Branch: refs/heads/ignite-239
Commit: 63c3f5494cb973c8c034a3ebc15a20a95d59cb7e
Parents: 81613b9
Author: ivasilinets <iv...@gridgain.com>
Authored: Fri Feb 20 15:09:41 2015 +0300
Committer: ivasilinets <iv...@gridgain.com>
Committed: Fri Feb 20 15:09:41 2015 +0300
----------------------------------------------------------------------
.../main/java/org/apache/ignite/internal/GridProperties.java | 7 ++++---
1 file changed, 4 insertions(+), 3 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/incubator-ignite/blob/63c3f549/modules/core/src/main/java/org/apache/ignite/internal/GridProperties.java
----------------------------------------------------------------------
diff --git a/modules/core/src/main/java/org/apache/ignite/internal/GridProperties.java b/modules/core/src/main/java/org/apache/ignite/internal/GridProperties.java
index bf8f93e..89110af 100644
--- a/modules/core/src/main/java/org/apache/ignite/internal/GridProperties.java
+++ b/modules/core/src/main/java/org/apache/ignite/internal/GridProperties.java
@@ -36,14 +36,15 @@ public class GridProperties {
static {
PROPS = new Properties();
- readProperties(FILE_PATH, true);
+ readProperties(FILE_PATH, PROPS, true);
}
/**
* @param path Path.
+ * @param props Properties.
* @param throwExc Flag indicating whether to throw an exception or not.
*/
- public static void readProperties(String path, boolean throwExc) {
+ public static void readProperties(String path, Properties props, boolean throwExc) {
try (InputStream is = IgniteVersionUtils.class.getClassLoader().getResourceAsStream(path)) {
if (is == null) {
if (throwExc)
@@ -52,7 +53,7 @@ public class GridProperties {
return;
}
- PROPS.load(is);
+ props.load(is);
}
catch (IOException e) {
throw new RuntimeException("Failed to read properties file: " + path, e);