Skip to content

Commit

Permalink
Better progress messages
Browse files Browse the repository at this point in the history
  • Loading branch information
matthiasblum committed Sep 7, 2024
1 parent 369f74a commit e007506
Showing 1 changed file with 6 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,8 @@ void buildDatabase(String url, String password, int fetchSize, File outputDirect
Environment env = null;
EntityStore store = null;

System.out.println(Utilities.getTimeAlt() + ": starting");

try (Connection connection = DriverManager.getConnection(url, USER, password)) {
// Set up the environment
EnvironmentConfig envConfig = new EnvironmentConfig();
Expand Down Expand Up @@ -57,11 +59,11 @@ void buildDatabase(String url, String password, int fetchSize, File outputDirect

proteinCount++;
if (proteinCount % 10000000 == 0) {
System.out.println(Utilities.getTimeNow() + " Stored " + proteinCount + " items.");
System.out.println(Utilities.getTimeAlt() + ": " + String.format("%,d", proteinCount) + " sequences processed");
}
}

System.out.println(Utilities.getTimeNow() + " Stored " + proteinCount + " items.");
System.out.println(Utilities.getTimeAlt() + ": " + String.format("%,d", proteinCount) + " sequences processed");
}
}
} catch (DatabaseException dbe) {
Expand All @@ -85,5 +87,7 @@ void buildDatabase(String url, String password, int fetchSize, File outputDirect
}
}
}

System.out.println(Utilities.getTimeAlt() + ": done");
}
}

0 comments on commit e007506

Please sign in to comment.