mirror of
https://github.com/overcuriousity/autopsy-flatpak.git
synced 2025-07-12 16:06:15 +00:00
Write imported hashes to the database in sets
This commit is contained in:
parent
b6ebe15da0
commit
f11b2aa334
@ -72,6 +72,7 @@ final class ImportHashDatabaseDialog extends javax.swing.JDialog {
|
|||||||
|
|
||||||
private final JFileChooser fileChooser = new JFileChooser();
|
private final JFileChooser fileChooser = new JFileChooser();
|
||||||
private final static String LAST_FILE_PATH_KEY = "CentralRepositoryImport_Path"; // NON-NLS
|
private final static String LAST_FILE_PATH_KEY = "CentralRepositoryImport_Path"; // NON-NLS
|
||||||
|
private final int HASH_IMPORT_THRESHOLD = 5000;
|
||||||
private EamOrganization selectedOrg = null;
|
private EamOrganization selectedOrg = null;
|
||||||
private List<EamOrganization> orgs = null;
|
private List<EamOrganization> orgs = null;
|
||||||
private final Collection<JTextField> textBoxes;
|
private final Collection<JTextField> textBoxes;
|
||||||
@ -646,6 +647,11 @@ final class ImportHashDatabaseDialog extends javax.swing.JDialog {
|
|||||||
"");
|
"");
|
||||||
|
|
||||||
globalInstances.add(eamGlobalFileInstance);
|
globalInstances.add(eamGlobalFileInstance);
|
||||||
|
|
||||||
|
if(numLines % HASH_IMPORT_THRESHOLD == 0){
|
||||||
|
dbManager.bulkInsertReferenceTypeEntries(globalInstances, contentType);
|
||||||
|
globalInstances.clear();
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
dbManager.bulkInsertReferenceTypeEntries(globalInstances, contentType);
|
dbManager.bulkInsertReferenceTypeEntries(globalInstances, contentType);
|
||||||
|
Loading…
x
Reference in New Issue
Block a user