Skip to content

POST /pub/validate method crashes with 500 error if datastore-services is down #559

@simon-20

Description

@simon-20

Brief Description
If Solr goes down, then POST requests to /pub/validate fail/crash with a 500 error, and without returning any useful information.

Severity
Medium-High

Issue Location

Steps to Reproduce
Easiest:
Run locally, with datastore-services also running locally, and point it to a non-existent Solr URL.

Expected Results/Behaviour
At a minimum it seems the validation call should succeed and produce a useful validation report.

There is a question of how to handle advisories, if the Datastore is down, and so cannot be queried.

We can't simply leave the advisory information out completely, because there are counts of advisories that are included, and tooling now expects them to be there.

If we report it as 0, that may falsely suggest there are no advisories. But that may be the best option. Introducing a flag, indicating whether advisories were fully tested for, would introduce a lot of complexity for all the tools downstream.

@robredpath, what do you think?

Actual Results/Behaviour
If the Solr is down, the Datastore API to check existence of identifiers gives 500, and this crashes the /pub/validate request.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions