Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add PublishingQueueCollectionDetails endpoint #370

Open
wants to merge 3 commits into
base: develop
Choose a base branch
from

Conversation

CarlHembrough
Copy link
Contributor

@CarlHembrough CarlHembrough commented Dec 16, 2020

What

A clone of the existing collection details endpoint, but without populating any lists of files that are in the collection. This is due to the issue of having too many files listed in the publish queue screen, which prevents it from loading.

Note: this PR removes all listing of files, including datasets. I thought it best to be consistent and either list all files or not.

How to review

Sanity check

Test that the publishing queue loads correctly if you have the publishing system running locally.

Who can review

Anyone

A clone of the existing collection details endpoint, but without populating any lists of files that are in the collection. This is due to the issue of having too many files listed in the publish queue screen, which prevents it from loading.
Copy link
Contributor

@rav-pradhan rav-pradhan left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I was able to test locally and could see the endpoint returning the relevant data in Florence. Left a minor comment but that wouldn't block approval.

Not sure if the policy is different for legacy systems but should we still add a test suite to cover the use case?

public CollectionDetail get(HttpServletRequest request, HttpServletResponse response)
throws IOException, ZebedeeException {

com.github.onsdigital.zebedee.model.Collection collection = Collections
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is there a reason we're not importing this like the statements at the top of the file?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think it has been done elsewhere due to name clashes, where the same class name is used in two different namespaces. I don't think it's required here though, so I will do the import 👍

- throw exceptions instead of directly setting API response codes as the framework handles this
- required some changes to the class to enable testing
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants