/serverapi/vocab should allow reaching fragments
See original GitHub issueI’m submitting a
- bug report.
Two different related issues here:
Current Behaviour:
/serverapi/vocab#Area
returns the full vocabulary.- at
http://localhost:8080/serverapi/contexts/EntryPoint.jsonld
see:
"@context": {
"Area": {
"@id": "http://localhost:8080/serverapi/vocab**#EntryPoint/Area**", <<<<<
"@type": "@id"
},
Expected Behaviour:
/serverapi/vocab#Area
should return theArea
object (with context) only, not the full vocabulary, i.e.:
{
"@context": { ... },
"@id": "http://localhost:8080/serverapi/vocab#Area",
"@type": "hydra:Class",
"description": "Class for Area of Interest of the server",
"supportedOperation": [
....
- ids in
http://localhost:8080/serverapi/contexts/EntryPoint.jsonld
should link toserverapi/vocab#
fragments like@id": "http://localhost:8080/serverapi/**vocab#Area**"
Issue Analytics
- State:
- Created 3 years ago
- Comments:5 (5 by maintainers)
Top Results From Across the Web
Dislocated Lens Fragments Should Be Referred to a Specialist
Dislocated Lens Fragments Should Be Referred to a Specialist ... While such techniques have allowed the phaco surgeon to remove harder nuclei more...
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
Sorry I forgot about this part of RFC. we need to take a look into how RDF servers implement this feature.
@chrizandr @sameshl any observation?
UPDATE: I think it would be ok to implement it as a GET parameter
the idea is to provide for the JSON-LD a feature that is availalble in HTML pages. For example if you write this link into you browser
https://en.wikipedia.org/wiki/Representational_state_transfer#Layered_system
you are redirected to the paragraph “Layered_system” inside the linked page. The same should happen for the JSON-LD, if a fragment is specified, the server should return only the object requested.Here it is a way you can implement this:
Request
object,from flask import request
); if a fragment name is present in the request (you can use a regular expression to match the fragment name or simply read the URI backward up to the#
; first one would be more solid) tell the handler to return only the context plus the object specified by the fragment name[UPDATED] as a plus, you can provide appropriate caching settings for this URI/handler as its content is basically immutable for every server instance