diff --git a/imixs-archive-service/src/main/java/org/imixs/archive/service/cassandra/DataService.java b/imixs-archive-service/src/main/java/org/imixs/archive/service/cassandra/DataService.java index f40d475c..aa950184 100644 --- a/imixs-archive-service/src/main/java/org/imixs/archive/service/cassandra/DataService.java +++ b/imixs-archive-service/src/main/java/org/imixs/archive/service/cassandra/DataService.java @@ -116,13 +116,15 @@ public void saveSnapshot(ItemCollection snapshot) throws ArchiveException { String snapshotID = snapshot.getUniqueID(); if (!isSnapshotID(snapshotID)) { - throw new IllegalArgumentException("unexpected '$snapshotid' format: '" + snapshotID + "'"); + throw new ArchiveException(ArchiveException.INVALID_DOCUMENT_OBJECT, + "unexpected '$snapshotid' format: '" + snapshotID + "'"); } if (debug) { logger.finest("......save document" + snapshotID); } if (!snapshot.hasItem("$modified")) { - throw new IllegalArgumentException("missing item '$modified' for snapshot " + snapshotID); + throw new ArchiveException(ArchiveException.INVALID_DOCUMENT_OBJECT, + "missing item '$modified' for snapshot " + snapshotID); } // verify if this snapshot is already stored - if so, we do not overwrite