Feature Request/Idea: Add more informative message to MDC API when it is not set up
Nobody has claimed this yet.
- Dominant language
- Java
- Stars
- 1.1k
- Forks
- 564
- Avg merge
- 2d 2h
- Merged PRs (30d)
- 29
Description
Overview of the Feature Request
The MDC API responds to requests with a zero response even when the DV administrator has not set up MDC. It would be useful to provide a different response when that is the case, to avoid any confusion.
What kind of user is the feature intended for?
API User
What inspired the request?
My confusion in trying to get the API to spit out responses, and all example cases appear to have been cases that do not implement it.
What existing behavior do you want changed?
API request should provide a text answer that says something like
Make Data Count hasn't been set up, please try the Metrics API
Bonus: Add expected output both with and without MDC enabled to the Documentation.
Any brand new behavior do you want to add to Dataverse?
Nope.
Any open or closed issues related to this feature request?
Not sure.
Details
Current response is
{"status":"OK","data":{"message":"No metrics available for dataset 8939107 for null for country code null."}}
which can mean two things: Metrics have not been set up, and nobody has downloaded this dataset. I have no idea what the message would look like if it were for a server running MDC.
Proposed response would be
{"status":"FALSE","data":{"message":"Make Data Count hasn't been set up, please try the Metrics API ."}}
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
No source file or test is named. Start by locating the MDC API entry point and checking how it distinguishes an unconfigured server from a dataset with no metrics. Done means returning the proposed response for an unconfigured MDC server, preserving the existing behavior otherwise, and documenting expected output with MDC enabled and disabled.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- java
- Domain
- api, backend-api-design
- Issue type
- Feature
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100