DOI - ufal/clarin-dspace GitHub Wiki
- Pull Request: dataquest-dev/DSpace#883
- Official Documentation: [DOI Digital Object Identifier – DSpace 7.x]
Note: The DATACITE_HOST
in /config/spring/api/identifier-service.xml
is supposed to be mds(.test).datacite.org
not api(.test).datacite.org
.
1. Enable DOI in Event Consumers
In your local.cfg
or equivalent config, ensure that doi is included in the event.dispatcher.default.consumers
property:
event.dispatcher.default.consumers = ... ,doi
2. Update XSL for Custom Metadata
If you're using custom metadata types (e.g., dc.type = corpus
), make sure DIM2DataCite.xsl
handles them appropriately.
Example from Lindat configuration:
<xsl:when test="$typeValue = 'corpus'">
<xsl:element name="resourceType">
<xsl:attribute name="resourceTypeGeneral">Other</xsl:attribute>
<xsl:value-of select="'corpus'"/>
</xsl:element>
</xsl:when>
3. Enable DOIIdentifierProvider in Spring Config
Edit [dspace]/config/spring/api/identifier-service.xml
and enable the necessary Spring beans:
<bean id="org.dspace.identifier.DOIIdentifierProvider"
class="org.dspace.identifier.DOIIdentifierProvider"
scope="singleton">
<property name="DOIConnector"
ref="org.dspace.identifier.doi.DOIConnector" />
</bean>
<bean id="org.dspace.identifier.doi.DOIConnector"
class="org.dspace.identifier.doi.DataCiteConnector"
scope="singleton">
<property name='DATACITE_SCHEME' value='https'/>
<property name='DATACITE_HOST' value='mds.test.datacite.org'/>
<property name='DATACITE_DOI_PATH' value='/doi/' />
<property name='DATACITE_METADATA_PATH' value='/metadata/' />
<property name='disseminationCrosswalkName' value="DataCite" />
</bean>
**Note: **If you want to support versioning, use:
class="org.dspace.identifier.VersionedDOIIdentifierProvider"
4. Configure DOI Credentials and Settings
In local.cfg
, add the following configuration with values appropriate to your DOI provider setup:
identifier.doi.user = your-username
identifier.doi.password = your-password
identifier.doi.prefix = 10.xxxx
identifier.doi.namespaceseparator = /
5. Set Up Cronjobs or Scheduled Tasks
To automate the DOI lifecycle, add the following to your crontab or scheduling tool:
[dspace]/bin/dspace doi-organiser -u -q # Update metadata
[dspace]/bin/dspace doi-organiser -s -q # Submit reservations
[dspace]/bin/dspace doi-organiser -r -q # Register DOIs
[dspace]/bin/dspace doi-organiser -d -q # Deactivate DOIs
-
Pre-registering DOIs (i.e., assigning a DOI before submission) is partially supported. The DOI can be preset, but reservation with the provider might not be triggered automatically.
-
If the DOI is properly registered, the pre-assigned DOI will be retained.
-
Only an administrator of the item can register its DOI.
-
DOI statuses are defined clearly in the official documentation and reflected in the DSpace source code.
-
You can monitor or modify DOI states directly in the
doi
database table.
1. Item Creation
When a new item is created, a DOI is generated with status TO_BE_RESERVED
.
2. Reservation Phase
doi-organiser -s
reserves DOIs with the registration agency. Status updates to TO_BE_REGISTERED
.
3. Registration Phase
doi-organiser -r
registers the DOI. Status updates to IS_REGISTERED
.
4. Finalization
Once registered, the DOI appears in the item’s metadata (e.g., under identifier.doi
).