Closed rrchai closed 1 month ago
I only make it work for filtering EDAM concepts by Ids, but negative on organizations and platforms.
GET {{basePath}}/edamConcepts?ids=1,100
HTTP/1.1 200
X-Content-Type-Options: nosniff
X-XSS-Protection: 1; mode=block
Cache-Control: no-cache, no-store, max-age=0, must-revalidate
Pragma: no-cache
Expires: 0
X-Frame-Options: DENY
Content-Type: application/json
Transfer-Encoding: chunked
Date: Tue, 14 May 2024 13:27:31 GMT
Connection: close
{
"number": 0,
"size": 100,
"totalElements": 2,
"totalPages": 1,
"hasNext": false,
"hasPrevious": false,
"edamConcepts": [
{
"id": 100,
"classId": "http://edamontology.org/data_0941",
"preferredLabel": "Electron microscopy model"
},
{
"id": 1,
"classId": "http://edamontology.org/data_0005",
"preferredLabel": "Resource type"
}
]
}
Errors for failed attempts
GET {{basePath}}/challengePlatforms?slugs=synapse,kaggle
2024-05-14 13:21:29 INFO [http-nio-8085-exec-1] o.s.o.c.s.service.ChallengeService - challengeEntitiesPage Page 1 of 6 containing org.sagebionetworks.openchallenges.challenge.service.model.entity.ChallengeEntity instances
2024-05-14 13:21:43 INFO [http-nio-8085-exec-2] o.s.o.c.s.s.ChallengePlatformService - query class ChallengePlatformSearchQueryDto {
pageNumber: 0
pageSize: 100
sort: relevance
direction: null
slugs: [synapse, kaggle]
searchTerms: null
}
2024-05-14 13:21:43 WARN [http-nio-8085-exec-2] o.s.w.s.m.m.a.ExceptionHandlerExceptionResolver - Resolved [org.hibernate.search.util.common.SearchException: HSEARCH000610: Unknown field 'slug'.<EOL>Context: indexes [openchallenges-challenge-platform]]
# no error, or results
GET {{basePath}}/organizations?ids=1,100
HTTP/1.1 200
X-Content-Type-Options: nosniff
X-XSS-Protection: 1; mode=block
Cache-Control: no-cache, no-store, max-age=0, must-revalidate
Pragma: no-cache
Expires: 0
X-Frame-Options: DENY
Content-Type: application/json
Transfer-Encoding: chunked
Date: Tue, 14 May 2024 13:30:24 GMT
Connection: close
{
"number": 0,
"size": 100,
"totalElements": 0,
"totalPages": 0,
"hasNext": false,
"hasPrevious": false,
"organizations": []
}
The errors are resolved by adding index either by KeywordField
for slug
(exact matched on string) or GenericField
for id
.
Issues
0 New issues
0 Accepted issues
Measures
0 Security Hotspots
No data about Coverage
No data about Duplication
Issues
0 New issues
0 Accepted issues
Measures
0 Security Hotspots
0.0% Coverage on New Code
0.0% Duplication on New Code
Issues
0 New issues
0 Accepted issues
Measures
0 Security Hotspots
No data about Coverage
No data about Duplication
Issues
0 New issues
0 Accepted issues
Measures
0 Security Hotspots
0.0% Coverage on New Code
0.0% Duplication on New Code
Preview
Filter EDAM by Ids
Filter Platforms by slugs
Filter organizations by Ids