Problem
Turtle handling is broken for a long time (see #995). It's complicated to deal with several formats on the LdpService and TripleStoreService. Plus it's annoying to have to declare a contentType or accept param for every calls (see #542)
Proposal
We should make it a rule that Moleculer services only handle JSON-LD data, because JSON is a first-class citizen on Moleculer, and more generally on javascript.
This means it is the responsibility of API services (we have a new, very functional LdpApiService) or actions to transform data from/to Turtle, before handing it to Moleculer services as JSON-LD. This means the TripleStoreService will not need to worry about content negociation anymore.
This way we can clean up the LdpService and TripeStoreService while fixing the Turtle handling.
We will need to add tests for the Turtle format, as none exist at the moment.
Problem
Turtle handling is broken for a long time (see #995). It's complicated to deal with several formats on the LdpService and TripleStoreService. Plus it's annoying to have to declare a
contentTypeoracceptparam for every calls (see #542)Proposal
We should make it a rule that Moleculer services only handle JSON-LD data, because JSON is a first-class citizen on Moleculer, and more generally on javascript.
This means it is the responsibility of API services (we have a new, very functional LdpApiService) or actions to transform data from/to Turtle, before handing it to Moleculer services as JSON-LD. This means the TripleStoreService will not need to worry about content negociation anymore.
This way we can clean up the LdpService and TripeStoreService while fixing the Turtle handling.
We will need to add tests for the Turtle format, as none exist at the moment.