Skip to content

Commit

Permalink
Add system info to logs
Browse files Browse the repository at this point in the history
  • Loading branch information
ManfredKarrer committed Apr 22, 2016
1 parent cf46a5d commit f700c42
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 3 deletions.
2 changes: 0 additions & 2 deletions common/src/main/java/io/bitsquare/app/Version.java
Original file line number Diff line number Diff line change
Expand Up @@ -81,6 +81,4 @@ public static void printVersion() {
", getP2PNetworkId()=" + getP2PMessageVersion() +
'}');
}


}
10 changes: 10 additions & 0 deletions common/src/main/java/io/bitsquare/common/util/Utilities.java
Original file line number Diff line number Diff line change
Expand Up @@ -140,6 +140,16 @@ public static String getOSArchitecture() {
}
}

public static void printSysInfo() {
log.info("os.name: " + System.getProperty("os.name"));
log.info("os.version: " + System.getProperty("os.version"));
log.info("os.arch: " + System.getProperty("os.arch"));
log.info("os.name: " + System.getProperty("os.name"));
log.info("sun.arch.data.model: " + getJVMArchitecture());
log.info("JRE: " + System.getProperty("java.runtime.version", "-") + " (" + System.getProperty("java.vendor", "-") + ")");
log.info("JVM: " + System.getProperty("java.vm.version", "-") + " (" + System.getProperty("java.vm.name", "-") + ")");
}

public static String getJVMArchitecture() {
return System.getProperty("sun.arch.data.model");
}
Expand Down
2 changes: 1 addition & 1 deletion gui/src/main/java/io/bitsquare/app/BitsquareApp.java
Original file line number Diff line number Diff line change
Expand Up @@ -101,8 +101,8 @@ public void start(Stage primaryStage) throws IOException {
String logPath = Paths.get(env.getProperty(BitsquareEnvironment.APP_DATA_DIR_KEY), "bitsquare").toString();
Log.setup(logPath, !IS_RELEASE_VERSION);
log.info("Log files under: " + logPath);

Version.printVersion();
Utilities.printSysInfo();

UserThread.setExecutor(Platform::runLater);
UserThread.setTimerClass(UITimer.class);
Expand Down

0 comments on commit f700c42

Please sign in to comment.