-
Notifications
You must be signed in to change notification settings - Fork 22
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
Invalid CollectionsResponse in the OpenAPI #116
Comments
True. And the "ResultsOKResponse" should also only have this value, right?
|
This would be an improvement because neither "CollectionsResponse" nor "ResultsOKResponse" defines the entryType. ---edit--- ResultsOKResponse:
description: Successful operation.
content:
application/json:
schema:
$ref: https://raw.githubusercontent.com/ga4gh-beacon/beacon-v2/main/framework/json/responses/beaconCollectionsResponse.json |
Let me disagree, a query to a collection could return a boolean or count response, telling he number of collections (datasets or cohorts in the Bv2 Model) that fulfill the query. |
@jordi That is all fine and I agree that this could be a use case; and also that there is IMO a need for having a general response granularity and overall the boolean/count response options. The response still we have to be fixed from But then in the long run IMO response granularity should be per resultSet to allow especially different granularities in aggregators, but also for Beacons w/ multiple datasets. (AND collections responses could also be resultSets since we're having this construct - e.g. datasets have cohorts. Same for filteringTerms which are per dataset etc - we have to deal with this already!). Just not sure if this would make things more simple (only one response type with different granularities) or more complex ... |
... so in the short run |
... I see no way for boolean response for "collections" in the beaconCollectionsResponse. The items in the "collections" are entryType(s) beaconCollectionsResponse.json I also wonder, how could I know if the response is the beaconCollectionsResponse or beaconResultsetsResponse from the configuration/map ? |
That is true but if you drop the requirement on
... you can use boolean or count granularity.
Yes, not possible righty now; only defined in the OpenAPI endpoints. We actually save such info min our configs:
|
TODO: Rewrite this into 2 issues:
|
@jordi @redmitry @costero-e Well, I guess issue 1 is different from what I mentioned very excitedly in the discussion & my claim was probably influenced by my re-thinking of the general "how are response types" are being defined (since we'll need responses with mixed boolean/count/record ... granularity). Here,
... would result in a summary response (boolean or count). And the same is true for But when using OpenAPI to retrieve the allowed responses the missing option of Boolean ... responses for datasets and cohorts had been fixed at some point already; so issue 1. disappears. This leaves 2; the only place where response schemas are associated with entry types are the OpenAPI endpoints; there is no definition of associated response types in the model itself. So for 1. we're back to a simple bug fix for
|
I'm retiring this, to be continued in #123. I'll also clean out the PR etc. Was helpful; for the discussions, though ¯_(ツ)_/¯ |
Hi all,
cohorts/endpoints.json and datasets/endpoints.json have CollectionsResponse response object derfined as a
choice of beaconBooleanResponse, beaconCountResponse and beaconCollectionsResponse which is wrong.
Should be defined as beaconCollectionsResponse precising the type according the endpoint cohorts/defaultSchema.json or cohorts/defaultSchema.json.
Best,
Dmitry
The text was updated successfully, but these errors were encountered: