DSpace icon indicating copy to clipboard operation
DSpace copied to clipboard

ORCID search should work out of the box

Open paulo-graca opened this issue 2 years ago • 1 comments

Describe the bug Out of the box, ORCID search doesn't work. This means that in order to do a person search, the user should change ORCID configurations to have it working. Mainly, out of the box, a search task is performed from:

https://api.sandbox.orcid.org/v3.0/search?q=paulo&start=0&rows=10

instead of

https://pub.sandbox.orcid.org/v3.0/search?q=paulo&start=0&rows=10

The installer must specify the orcid.api-url setting to use pub.sandbox.orcid.org address (the public address). The public address is currently not considered. Having api.sandbox.orcid.org as the default, you are required to specify ORCID's settings like client's id an secret. And that forces you to change default ORCID settings. Only then it makes sense to change DSpace ORCID's settings, otherwise (IMHO) the system should work without changes.

To Reproduce Steps to reproduce the behavior:

  1. Install DSpace 7.5
  2. Create a collection for persons
  3. On my "MyDspace" import a person from external source
  4. Use Orcid and search for a person
  5. You will have an Unmarshall exception for trying to parse a Forbidden HTML page
2023-05-08 16:20:01,373 ERROR 64ed10cd-017d-4207-a5fa-90e47c106514 bcf5c650-544a-4d20-88fb-77963c0db75d org.dspace.app.rest.exception.DSpaceApiExceptionControllerAdvice @ An exception has occurred (status:500)
java.lang.RuntimeException: Unable to unmarshall orcid messagejavax.xml.bind.UnmarshalException
 - with linked exception:
[org.xml.sax.SAXParseException; lineNumber: 1; columnNumber: 1; Content is not allowed in prolog.]

Expected behavior Without specifying any ORCID's setting, the user should be able to use ORCID public search.

paulo-graca avatar May 09 '23 09:05 paulo-graca

Very similar/likely the same issue as https://github.com/DSpace/DSpace/issues/9333

TL;DR I think the problem is that the DSpace code uses the property where the member API link is expected(orcid.api-url), to make calls that can also be serviced by the public API.

bram-atmire avatar Feb 23 '24 09:02 bram-atmire

This seems like a very tiny configuration change. If anyone wants to submit a PR we can consider it a bug fix for 7.6.x and 8.0.

tdonohue avatar Feb 26 '24 15:02 tdonohue