Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.
Comment: Additional required steps to enable the funcitonality + config changes

...

Code Block
languagexml
<step>
    <heading>submit.progressbar.liveimport</heading>
    <processing-class>org.dspace.submit.step.LiveImportStep</processing-class>
    <jspui-binding>org.dspace.app.webui.submit.step.JSPStartSubmissionLookupStep</jspui-binding>
    <xmlui-binding>org.dspace.app.xmlui.aspect.submission.submit.LiveImportStep</xmlui-binding>
    <workflow-editable>true</workflow-editable>
</step>

File permissions in the upload step

Enabling the metadata fields

The live import requires the following metadata field to The automatic suggestion of the file permissions should be enabled in the dspace/config/item-submissioninput-forms.xml . The step below should replace the default upload step:file. This field is disabled by default.

 

Code Block
languagexml

...

<field>
     

...

    

...

<dc-schema>elsevier</dc-schema>
         

...

<dc-element>identifier</dc-element>
         

...

<dc-

...

qualifier>pii</

...

dc-

...

qualifier>
         <repeatable>false</repeatable>
         <label>PII</label>
         <input-type>onebox</input-type>
         <hint>Enter the PII for this item.</hint>
         <required></required>
</field>

 

Enabling the required aspect

The aspect that allows for the metadata to be imported from ScienceDirect needs to be enabled in dspace/config/xmlui.xconf as it is commented out by default

Link to the ScienceDirect page

The display of the link to the ScienceDirect page can be enabled in the theme. The automatic verification whether the user is entitled to download the file can be enabled in dspace/config/modules/elsevier-sciencedirect.cfg using the parameter:

Code Block
entitlement.check.enabled

Embedding the article PDF

The display of the embedded article PDF can be enabled in dspace/config/modules/elsevier-sciencedirect.cfg using the parameter:

Code Block
embed.display

Plugin for the Search API

Configuration

The basic API configuration can be found in file dspace/config/modules/elsevier-sciencedirect.cfg. This file contains the API key and the API urls.

 

Code Block
language

...

xml

...

<aspect name=

...

"ScienceDirect" path="resource://aspects/ScienceDirect/" />

 

File permissions in the upload step

The automatic suggestion of the file permissions should be enabled in the dspace/config/item-submission.xml. The step below should replace the default upload step:

Code Block
languagexml
<step>
    <heading>submit.progressbar.upload</heading>
    <processing-class>org.dspace.submit.step.ElsevierUploadStep</processing-class>
    <xmlui-binding>org.dspace.app.xmlui.aspect.submission.submit.ElsevierUploadStep</xmlui-binding>
    <workflow-editable>true</workflow-editable>
</step>

Link to the ScienceDirect page

The display of the link to the ScienceDirect page can be enabled in the theme. The automatic verification whether the user is entitled to download the file can be enabled in dspace/config/modules/elsevier-sciencedirect.cfg using the parameter:

Code Block
entitlement.check.enabled

Embedding the article PDF

The display of the embedded article PDF can be enabled in dspace/config/modules/elsevier-sciencedirect.cfg using the parameter:

Code Block
embed.display

Plugin for the Search API

Configuration

The basic API configuration can be found in file dspace/config/modules/elsevier-sciencedirect.cfg. This file contains the API key (this key will need to be added through the maven profile) and the API urls as well as the extra config for the entitlements check and embedding of the pdf which will be discussed later on

 

Code Block
languagetext
# Api key to be able to make the calls to retrieve the articles, this will need to be requested by the appropriate instance
api.key = ${elsevier.api.key}

# This represents the base url to use for the retrieval of an article
api.article.url=http://api.elsevier.com/content/article
# The base of rest endpoints to represent identifiers and entitlement status associated with requested full text articles
api.entitlement.url=http://api.elsevier.com/content/article/entitlement
# This represents retrieval of a full text article by PII (Publication Item Identifier).
api.pii.url=//api.elsevier.com/content/article/pii/
# The search interfaces associated with ScienceDirect
api.scidir.url=http://api.elsevier.com/content/search/scidir
# Url to base later rest calls on, such as retrieval based on PII etc
ui.article.url=http://www.sciencedirect.com/science/article

Mapping

The file dspace/config/spring/api/scidir-service.xml contains the spring configuration for the beans used by the Elsevier service.

Part of this configuration is the mapping of Science Direct fields to dspace metadata fields.

Configuring the mapping

Each DSpace metadata field that will be used for the mapping must first be configured as a spring bean of class org.dspace.importer.external.metadatamapping.MetadataFieldConfig.

Code Block
languagexml
<bean id="dc.title

Mapping

The file dspace/config/spring/api/scidir-service.xml contains the spring configuration for the beans used by the Elsevier service.

Part of this configuration is the mapping of Science Direct fields to dspace metadata fields.

Configuring the mapping

Each DSpace metadata field that will be used for the mapping must first be configured as a spring bean of class org.dspace.importer.external.metadatamapping.MetadataFieldConfig.

Code Block
languagexml
<bean id="dc.title" class="org.dspace.importer.external.metadatamapping.MetadataFieldConfig">
    <constructor-arg value="dc.title"/>
</bean>

Hereafter this metadata field can be used to create a mapping. To add a mapping for the "dc.title" field declared above, a new spring bean configuration of class org.dspace.importer.external.metadatamapping.contributor.SimpleXpathMetadatumContributor needs to be added. This bean expects 2 property values:

 

  • field: A reference to the configured spring bean of the DSpace metadata field. e.g. the "dc.title" bean declared above.
  • query: The xpath expression used to select the Elsevier value from the XML returned by the Elsevier API. The root for the xpath query is the "entry" element.

 

Code Block
languagexml
<bean id="titleContrib" class="org.dspace.importer.external.metadatamapping.contributor.SimpleXpathMetadatumContributor">
    <property name="field" ref="dc.title"/>
    <property name="query" value="dc:title"/>
</bean>

This is a (shortened) example of the XML of an entry returned by the elsevier API:

Code Block
languagexml
<entry>
    <dc:title>
        Integrating phenotypic small-molecule profiling and human genetics: the next phase in drug discovery
    </dc:title>
    <authors>
        <author>
            <given-name>Cory M.</given-name>
            <surname>Johannessen</surname>
        </author>
    </authors>
</entry>

Because the given-name and surname of an author are contained in one metadata field value in DSpace, multiple Elsevier fields can also be combined into one value. To implement a combined mapping first create a "SimpleXpathMetadatumContributor" as explained above for each part of the field.

Code Block
languagexml
<bean id="lastNameContrib" class="org.dspace.importer.external.metadatamapping.contributor.SimpleXpathMetadatumContributorMetadataFieldConfig">
    <property name="field" ref<constructor-arg value="dc.contributor.authortitle"/>
    <property name="query" value="x:authors/x:author/x:surname"/>
</bean>
<bean id="firstNameContrib" class="</bean>

Hereafter this metadata field can be used to create a mapping. To add a mapping for the "dc.title" field declared above, a new spring bean configuration of class org.dspace.importer.external.metadatamapping.contributor.SimpleXpathMetadatumContributor

...

needs to be added. This bean expects 2 property values:

 

  • field: A reference to the configured spring bean of the DSpace metadata field. e.g. the "dc.title" bean declared above.
  • query: The xpath expression used to select the Elsevier value from the XML returned by the Elsevier API. The root for the xpath query is the "entry" element.

 

Code Block
languagexml
<bean id="titleContrib" class="org.dspace.importer.external.metadatamapping.contributor.SimpleXpathMetadatumContributor">
    <property name="field" ref="dc.title"/>
    <property name="query" value="dc:title"/>
</bean>

This is a (shortened) example of the XML of an entry returned by the elsevier API:

Code Block
languagexml
<entry>
    <dc:title>
        Integrating phenotypic small-molecule profiling and human genetics: the next phase in drug discovery
    </dc:title>
    <authors>
        <author>
            <given-name>Cory M.</given-name>
            <surname>Johannessen</surname>
        </author>
    </authors>
</entry>

Because the given-name and surname of an author are contained in one metadata field value in DSpace, multiple Elsevier fields can also be combined into one value. To implement a combined mapping first create a "SimpleXpathMetadatumContributor" as explained above for each part of the field.

Note that for elements without namespace, namespace "x" is appended. This is the default namespace. The namespace configuration can be found in map "FullprefixMapping" in the same spring configuration file.

Then create a new list in the spring configuration containing references to all "SimpleXpathMetadatumContributor" beans that need to be combined.

Code Block
languagexml
<util:list id="combinedauthorList" value-type="org.dspace.importer.external.metadatamapping.contributor.org.dspace.importer.external.metadatamapping.contributor.MetadataContributor" list-class="java.util.LinkedList">
    <ref bean="lastNameContrib"/>
    <ref bean="firstNameContrib"/>
</util:list>

Finally create a spring bean configuration of class org.dspace.importer.external.metadatamapping.contributor.CombinedMetadatumContributor. This bean expects 3 values:

  • field: A reference to the configured spring bean of the DSpace metadata field. e.g. the "dc.title" bean declared above.
  • metadatumContributors: A reference to the list containing all the single Elsevier field mappings that need to be combined. 
  • separator: These characters will be added between each Elsevier field value when they are combined into one field.

 

Code Block
languagexml
<bean id="authorContriblastNameContrib" class="org.dspace.importer.external.metadatamapping.contributor.CombinedMetadatumContributorSimpleXpathMetadatumContributor">
    <property name="separatorfield" valueref=", dc.contributor.author"/>
    <property name="metadatumContributorsquery" refvalue="combinedauthorList"/x:authors/x:author/x:surname"/>
</bean>
<bean id="firstNameContrib" class="org.dspace.importer.external.metadatamapping.contributor.SimpleXpathMetadatumContributor">
    <property name="field" ref="dc.contributor.author"/>
</bean>    <property name="query" value="x:authors/x:author/x:given-name"/>
</bean>

Note that for elements without namespace, namespace "x" is appended. This is the default namespace. The namespace configuration can be found in map "FullprefixMapping" in the same spring configuration file.

Then create a new list in the spring configuration containing references to all "SimpleXpathMetadatumContributor" beans that need to be combined.Each contributor must also be added to the "scidirMetadataFieldMap" map in the same spring configuration file. Each entry of this map maps a metadata field bean to a contributor. For the contributors created above this results in the following configuration:

Code Block
languagexml
<util:maplist id="scidirMetadataFieldMapcombinedauthorList" keyvalue-type="org.dspace.importer.external.metadatamapping.MetadataFieldConfig"
          value-type=".contributor.org.dspace.importer.external.metadatamapping.contributor.MetadataContributor" list-class="java.util.LinkedList">
    <entry<ref key-refbean="dc.title" value-ref="titleContrib"lastNameContrib"/>
    <entry key-ref="dc.contributor.author" value-ref="authorContrib<ref bean="firstNameContrib"/>
</util:map>

Note that the single field mappings used for the combined author mapping are not added to this list.

Live import

The first submission step is the Elsevier import step. This step allows the user to import a publication from Elsevier.

This step can be skipped by clicking on "Next" at the bottom of the page without importing a publication.

Image Removed

:list>

Finally create a spring bean configuration of class org.dspace.importer.external.metadatamapping.contributor.CombinedMetadatumContributor. This bean expects 3 values:

  • field: A reference to the configured spring bean of the DSpace metadata field. e.g. the "dc.title" bean declared above.
  • metadatumContributors: A reference to the list containing all the single Elsevier field mappings that need to be combined. 
  • separator: These characters will be added between each Elsevier field value when they are combined into one field.

 

Code Block
languagexml
<bean id="authorContrib" class="org.dspace.importer.external.metadatamapping.contributor.CombinedMetadatumContributor">
    <property name="separator" value=", "/>
    <property name="metadatumContributors" ref="combinedauthorList"/>
    <property name="field" ref="dc.contributor.author"/>
</bean>

Each contributor must also be added to the "scidirMetadataFieldMap" map in the same spring configuration file. Each entry of this map maps a metadata field bean to a contributor. For the contributors created above this results in the following configuration:

Code Block
languagexml
<util:map id="scidirMetadataFieldMap" key-type="org.dspace.importer.external.metadatamapping.MetadataFieldConfig"
          value-type="org.dspace.importer.external.metadatamapping.contributor.MetadataContributor">
    <entry key-ref="dc.title" value-ref="titleContrib"/>
    <entry key-ref="dc.contributor.author" value-ref="authorContrib"/>
</util:map>

Note that the single field mappings used for the combined author mapping are not added to this list.

Live import

The first submission step is the Elsevier import step. This step allows the user to import a publication from Elsevier.

This step can be skipped by clicking on "Next" at the bottom of the page without importing a publication.

Image Added

To search for a publication to import fill in at least one of the 4 search fields and click on "Search". A new window will appear containing the search results. To import a publication click on the "Import" button next to it.To search for a publication to import fill in at least one of the 4 search fields and click on "Search". A new window will appear containing the search results. To import a publication click on the "Import" button next to it.

Publications that are already imported are shown with a gray background.

...

To enable the Elsevier import step add the step to the submission-process in dspace/config/item-submission.xml.

Code Block
languagexml
<step>
    <heading>submit.progressbar.liveimport</heading>
    <processing-class>org.dspace.submit.step.LiveImportStep</processing-class>
    <jspui-binding>org.dspace.app.webui.submit.step.JSPStartSubmissionLookupStep</jspui-binding>
    <xmlui-binding>org.dspace.app.xmlui.aspect.submission.submit.LiveImportStep</xmlui-binding>
    <workflow-editable>true</workflow-editable>
</step>

Batch import

Import multiple publications from Elsevier using the batch import.

The batch import page can be found by clicking on "Elsevier Import" in the administrative menu, or by browsing to {dspace-url}/liveimport.

Start by filling in at least one of the 4 search fields to query the Elsevier API for publications, then click on "Search".

Image Removed

A list of the publications returned by the Elsevier API will be shown. Next to each publication is a checkbox which can be clicked to select the publication for import. Under the publications list a counter shows how many publications are already selected for import. This counter is updated each time the user browses through the publications.

Image Removed

When "Next" is clicked the user is taken to the import page. At the top of this page all publications that are selected for import are listed.

One of the "Select action" options must be chosen to specify what will happen to the imported items:

  • Send imported items to workspace: The items are added to the users "Unfinished submissions" on the submission page.
  • Send imported items to workflow: The items are added to the workflow to be reviewed by the reviewers of the collection the item is added to. 
  • Archive imported items: The items are archived immediately.

A collection to which the items are added must be selected from the "Select collection" dropdown. Click on "Import" to start the import.

Image Removed

File Upload Step

The file upload step has been altered to allow people to select the accessibility of files, it can be restricted from users, placed under embargo so it's not available until a specified date, or simply be made regularly available.

Image Removed

Plugin for the Entitlements check

The check for entitlement can be configured in the ${dspace.dir}/config/modules/elsevier-sciencedirect.cfg.

 

submission-process in dspace/config/item-submission.xml.

Code Block
languagexml
<step>
    <heading>submit.progressbar.liveimport</heading>
    <processing-class>org.dspace.submit.step.LiveImportStep</processing-class>
    <jspui-binding>org.dspace.app.webui.submit.step.JSPStartSubmissionLookupStep</jspui-binding>
    <xmlui-binding>org.dspace.app.xmlui.aspect.submission.submit.LiveImportStep</xmlui-binding>
    <workflow-editable>true</workflow-editable>
</step>

Batch import

Import multiple publications from Elsevier using the batch import.

The batch import page can be found by clicking on "Elsevier Import" in the administrative menu, or by browsing to {dspace-url}/liveimport.

Start by filling in at least one of the 4 search fields to query the Elsevier API for publications, then click on "Search".

Image Added

A list of the publications returned by the Elsevier API will be shown. Next to each publication is a checkbox which can be clicked to select the publication for import. Under the publications list a counter shows how many publications are already selected for import. This counter is updated each time the user browses through the publications.

Image Added

When "Next" is clicked the user is taken to the import page. At the top of this page all publications that are selected for import are listed.

One of the "Select action" options must be chosen to specify what will happen to the imported items:

  • Send imported items to workspace: The items are added to the users "Unfinished submissions" on the submission page.
  • Send imported items to workflow: The items are added to the workflow to be reviewed by the reviewers of the collection the item is added to. 
  • Archive imported items: The items are archived immediately.

A collection to which the items are added must be selected from the "Select collection" dropdown. Click on "Import" to start the import.

Image Added

File Upload Step

The file upload step has been altered to allow people to select the accessibility of files, it can be restricted from users, placed under embargo so it's not available until a specified date, or simply be made regularly available.

Image Added

Plugin for the Entitlements check

The check for entitlement can be configured in the ${dspace.dir}/config/modules/elsevier-sciencedirect.cfg.

 

Code Block
# Api key to be able to make the calls to retrieve the articles, this will need to be requested by the appropriate instance
api.key = ${elsevier.api.key}

# This represents the base url to use for the retrieval of an article
api.article.url=http://api.elsevier.com/content/article
# The base of rest endpoints to represent identifiers and entitlement status associated with requested full text articles
api.entitlement.url=http://api.elsevier.com/content/article/entitlement
# This represents retrieval of a full text article by PII (Publication Item Identifier).
api.pii.url=
Code Block
api.key = 7f8c0…
api.article.url=http://api.elsevier.com/content/article/article/pii/
# The search interfaces associated with ScienceDirect
api.entitlementscidir.url=http://api.elsevier.com/content/article/entitlement
api.scidirsearch/scidir
# Url to base later rest calls on, such as retrieval based on PII etc
ui.article.url=http://apiwww.elsevier.com/content/search/scidirsciencedirect.com/science/article
# Check statuses associated with the requested articles
entitlement.check.enabled=truefalse

# Mapping between retrieved and saved metadata
metadata.field.pii = elsevier.identifier.pii
metadata.field.doi = dc.identifier

This check is used to determine if the user should be allowed to view the published version of the document.

...

Can be defined in the ${dspace.dir}/config/modules/elsevier-sciencedirect.cfg:/elsevier-sciencedirect.cfg:

Code Block
# Whether or not to embed the display + its respective width and height
Code Block
embed.display=true
embed.display.width=700
embed.display.height=500

...

Set "embed.link.position" to "top" to render the link above the file section, or set it to "bottom" to render the link above the file section, or set it to "bottom" to render the link under the file section.the link under the file section.

Code Block
# Define if the link to the embed display should be rendered above (top) or under (bottom) the file section on the item page.
# Only supported by theme Mirage
Code Block
embed.link.position = top

...