feat: allow for subjects and samples to have attached gateways where files cannot be listed #79
Replies: 4 comments 8 replies
-
I think adding an optional gateway list to individual sample and subject objects (ie, identical to how the file endpoint does it) is a good idea and can be useful for, eg, a site that focuses more on data exploration than on serving files like UCSC Xena. Regarding the higher-level gateway in a sample or subject response, I'm having trouble seeing what this adds over using named gateways. For example, if I have a response that returns subject 1 with namespace A and subject 2 with namespace B, my assumption is that the root-level gateway with namespace A would only apply to subject 1, not subject 2. Is that correct? So the user would still have to refer back to each individual subject to know which root gateway applied. |
Beta Was this translation helpful? Give feedback.
-
I think everything here looks good. My only critique would be that I would advocate the top-level namespace not be forced to be tied to a namespace. For example, in the In other words, I don't think there is a benefit to restricting top-level gateways to only be organizable by namespaces. Instead, we should just let the implementing server choose how they want to organize their gateways. |
Beta Was this translation helpful? Give feedback.
-
Just to make sure it's clear, this is how the endpoint would work for two files that refer to the same top-level gateway: {
"data": {
...,
"files": [
{
"id": {
"namespace": {
"organization": "hello",
"name": "World"
},
"name": "File001.txt"
},
"samples": [ ... ],
"gateways": [
{
"gateway": "gateway-one",
"kind": "Reference"
}
],
"metadata": { ... }
},
{
"id": {
"namespace": {
"organization": "hello",
"name": "World"
},
"name": "File002.txt"
},
"samples": [ ... ],
"gateways": [
{
"gateway": "gateway-one",
"kind": "Reference"
}
],
"metadata": { ... }
}
],
"gateways": [
{
"link": {
"url": "https://hello.world/data",
"kind": "Direct"
},
"kind": "Controlled",
"name": "gateway-one"
},
]
}
} |
Beta Was this translation helpful? Give feedback.
-
/file endpoint response as it currently is:
I propose to extend the gateway functionality to subjects and samples.
In addition we should have a higher level gateway for the entire response object grouped by namespace. This way the user can have a fast way to request access where needed for all the subjects/samples/files in the same requests without the need to aggregate all the gateway from each single record.
For instance here is a proposed response for the /subject endpoint
Proposed subject endpoint:
So more in specific the gateway inside a single subject could have the
url
value likehttps://portal.kidsfirstdrc.org/participant/PT_Z34K1EM1#summary
and the root level onehttps://pecan.stjude.cloud/variants/oncoprint/BT
where BT is Brain tumor in this example URL I got from the St Jude Cloud but in the context of subject it could be Male/M.This structure would be the same for Sample and File.
Beta Was this translation helpful? Give feedback.
All reactions