diff options
author | Thomas Lenz <tlenz@iaik.tugraz.at> | 2016-03-31 14:36:38 +0200 |
---|---|---|
committer | Thomas Lenz <tlenz@iaik.tugraz.at> | 2016-03-31 14:36:38 +0200 |
commit | 4a347b1c7784e2c756c2bcae973d3b6da0ba8e62 (patch) | |
tree | 10d41265dc42d36606b24abc072da11874134ec6 /id/server/idserverlib/src/main/java/at/gv/egovernment/moa/id/storage/DBTransactionStorage.java | |
parent | c07d9264db58c1746009d358d91362568d5a9ccf (diff) | |
download | moa-id-spss-4a347b1c7784e2c756c2bcae973d3b6da0ba8e62.tar.gz moa-id-spss-4a347b1c7784e2c756c2bcae973d3b6da0ba8e62.tar.bz2 moa-id-spss-4a347b1c7784e2c756c2bcae973d3b6da0ba8e62.zip |
fix missing implementation in ExceptionContainer
Diffstat (limited to 'id/server/idserverlib/src/main/java/at/gv/egovernment/moa/id/storage/DBTransactionStorage.java')
-rw-r--r-- | id/server/idserverlib/src/main/java/at/gv/egovernment/moa/id/storage/DBTransactionStorage.java | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/id/server/idserverlib/src/main/java/at/gv/egovernment/moa/id/storage/DBTransactionStorage.java b/id/server/idserverlib/src/main/java/at/gv/egovernment/moa/id/storage/DBTransactionStorage.java index 6778dc32e..c2b3b0fc5 100644 --- a/id/server/idserverlib/src/main/java/at/gv/egovernment/moa/id/storage/DBTransactionStorage.java +++ b/id/server/idserverlib/src/main/java/at/gv/egovernment/moa/id/storage/DBTransactionStorage.java @@ -242,6 +242,12 @@ public class DBTransactionStorage implements ITransactionStorage { element.setType(value.getClass().getName()); element.setDatatime(new Date()); + if (!Serializable.class.isInstance(value)) { + Logger.warn("Transaction-Storage can only store objects which implements the 'Seralizable' interface"); + throw new MOADatabaseException("Transaction-Storage can only store objects which implements the 'Seralizable' interface", null); + + } + //serialize the Assertion for Database storage byte[] data = SerializationUtils.serialize((Serializable) value); element.setAssertion(data); |