java.lang.IllegalStateException

There are no available Samebug tips for this exception. Do you have an idea how to solve this issue? A short tip would help users who saw this issue last week.

  • When restoring items with the AIP Backup and Restore process, the VersionedHandleIdentifierProvider always logs the following unnecessary (and ignorable) error message: 2015-01-09 09:56:51,075 ERROR org.dspace.identifier.VersionedHandleIdentifierProvider @ test@email.com::Error while resolving handle to item:handle\colon; 123456789/544 java.lang.IllegalStateException: No associated resource type at org.dspace.identifier.VersionedHandleIdentifierProvider.resolve(VersionedHandleIdentifierProvider.java:290) at org.dspace.identifier.VersionedHandleIdentifierProvider.getHistory(VersionedHandleIdentifierProvider.java:179) at org.dspace.identifier.VersionedHandleIdentifierProvider.register(VersionedHandleIdentifierProvider.java:132) at org.dspace.identifier.IdentifierServiceImpl.register(IdentifierServiceImpl.java:100) at org.dspace.content.InstallItem.restoreItem(InstallItem.java:109) at org.dspace.content.packager.PackageUtils.finishCreateItem(PackageUtils.java:511) at org.dspace.content.packager.AbstractMETSIngester.ingestObject(AbstractMETSIngester.java:516) at org.dspace.content.packager.AbstractMETSIngester.ingest(AbstractMETSIngester.java:234) at org.dspace.content.packager.AbstractPackageIngester.ingestAll(AbstractPackageIngester.java:143) at org.dspace.content.packager.AbstractPackageIngester.ingestAll(AbstractPackageIngester.java:193) at org.dspace.content.packager.AbstractPackageIngester.ingestAll(AbstractPackageIngester.java:193) at org.dspace.content.packager.AbstractPackageIngester.ingestAll(AbstractPackageIngester.java:193) at org.dspace.content.packager.AbstractPackageIngester.ingestAll(AbstractPackageIngester.java:193) The error is logged by a seemingly overzealous "resolve()" method which assumes that any Handle without a resource_id is an ERROR: https://github.com/DSpace/DSpace/blob/master/dspace-api/src/main/java/org/dspace/identifier/VersionedHandleIdentifierProvider.java#L287 However, in the situation where you are *restoring* content to DSpace, the content has been previously DELETED in DSpace. When content is Deleted, it's handle is "reserved" (so that it will not be used again), but it's "resource_id" is cleared out. See HandleManager.unbindHandle(): https://github.com/DSpace/DSpace/blob/master/dspace-api/src/main/java/org/dspace/handle/HandleManager.java#L276 If you look closely at the stacktrace above, this "Error while resolving handle" is reported during the process of attempting to *register()* a known handle after calling "InstallItem.restoreItem()" While these errors are essentially harmless, they are rather confusing as they seem to be a problem during the restoration process. However, the error is never actually *thrown* outside of the resolve() method, it is just logged. So the restoring the identifier on the Item actually DOES SUCCEED even though an error appears in the logs. Looking at the code a bit, there may be some refactoring work necessary to fix this problem. As it is likely too late in the game to fix for 5.0, I'm just logging this as a known issue. Again, this error can be ignored if you are simply performing an Item restore.
    via by Tim Donohue,
  • When restoring items with the AIP Backup and Restore process, the VersionedHandleIdentifierProvider always logs the following unnecessary (and ignorable) error message: 2015-01-09 09:56:51,075 ERROR org.dspace.identifier.VersionedHandleIdentifierProvider @ test@email.com::Error while resolving handle to item:handle\colon; 123456789/544 java.lang.IllegalStateException: No associated resource type at org.dspace.identifier.VersionedHandleIdentifierProvider.resolve(VersionedHandleIdentifierProvider.java:290) at org.dspace.identifier.VersionedHandleIdentifierProvider.getHistory(VersionedHandleIdentifierProvider.java:179) at org.dspace.identifier.VersionedHandleIdentifierProvider.register(VersionedHandleIdentifierProvider.java:132) at org.dspace.identifier.IdentifierServiceImpl.register(IdentifierServiceImpl.java:100) at org.dspace.content.InstallItem.restoreItem(InstallItem.java:109) at org.dspace.content.packager.PackageUtils.finishCreateItem(PackageUtils.java:511) at org.dspace.content.packager.AbstractMETSIngester.ingestObject(AbstractMETSIngester.java:516) at org.dspace.content.packager.AbstractMETSIngester.ingest(AbstractMETSIngester.java:234) at org.dspace.content.packager.AbstractPackageIngester.ingestAll(AbstractPackageIngester.java:143) at org.dspace.content.packager.AbstractPackageIngester.ingestAll(AbstractPackageIngester.java:193) at org.dspace.content.packager.AbstractPackageIngester.ingestAll(AbstractPackageIngester.java:193) at org.dspace.content.packager.AbstractPackageIngester.ingestAll(AbstractPackageIngester.java:193) at org.dspace.content.packager.AbstractPackageIngester.ingestAll(AbstractPackageIngester.java:193) The error is logged by a seemingly overzealous "resolve()" method which assumes that any Handle without a resource_id is an ERROR: https://github.com/DSpace/DSpace/blob/master/dspace-api/src/main/java/org/dspace/identifier/VersionedHandleIdentifierProvider.java#L287 However, in the situation where you are *restoring* content to DSpace, the content has been previously DELETED in DSpace. When content is Deleted, it's handle is "reserved" (so that it will not be used again), but it's "resource_id" is cleared out. See HandleManager.unbindHandle(): https://github.com/DSpace/DSpace/blob/master/dspace-api/src/main/java/org/dspace/handle/HandleManager.java#L276 If you look closely at the stacktrace above, this "Error while resolving handle" is reported during the process of attempting to *register()* a known handle after calling "InstallItem.restoreItem()" While these errors are essentially harmless, they are rather confusing as they seem to be a problem during the restoration process. However, the error is never actually *thrown* outside of the resolve() method, it is just logged. So the restoring the identifier on the Item actually DOES SUCCEED even though an error appears in the logs. Looking at the code a bit, there may be some refactoring work necessary to fix this problem. As it is likely too late in the game to fix for 5.0, I'm just logging this as a known issue. Again, this error can be ignored if you are simply performing an Item restore.
    via by Tim Donohue,
    • java.lang.IllegalStateException: No associated resource type at org.dspace.identifier.VersionedHandleIdentifierProvider.resolve(VersionedHandleIdentifierProvider.java:290) at org.dspace.identifier.VersionedHandleIdentifierProvider.getHistory(VersionedHandleIdentifierProvider.java:179) at org.dspace.identifier.VersionedHandleIdentifierProvider.register(VersionedHandleIdentifierProvider.java:132) at org.dspace.identifier.IdentifierServiceImpl.register(IdentifierServiceImpl.java:100) at org.dspace.content.InstallItem.restoreItem(InstallItem.java:109) at org.dspace.content.packager.PackageUtils.finishCreateItem(PackageUtils.java:511) at org.dspace.content.packager.AbstractMETSIngester.ingestObject(AbstractMETSIngester.java:516) at org.dspace.content.packager.AbstractMETSIngester.ingest(AbstractMETSIngester.java:234) at org.dspace.content.packager.AbstractPackageIngester.ingestAll(AbstractPackageIngester.java:143) at org.dspace.content.packager.AbstractPackageIngester.ingestAll(AbstractPackageIngester.java:193) at org.dspace.content.packager.AbstractPackageIngester.ingestAll(AbstractPackageIngester.java:193) at org.dspace.content.packager.AbstractPackageIngester.ingestAll(AbstractPackageIngester.java:193) at org.dspace.content.packager.AbstractPackageIngester.ingestAll(AbstractPackageIngester.java:193)
    No Bugmate found.