Live data from Hacker News

SPARQL Protocol for RDF

w3.org

1–10 of 53 posts

Re: SPARQL Protocol for RDF

#2
SPARQL is what happens when you try to define an API for doing everything, from abstract principles, and end up with an API that does nothing.

It wraps your database in a worse database with a worse query language. It makes simple queries into kilobyte-long GET query strings that get morasses of XML-namespace nonsense as a response, or more likely, a server timeout.

While the W3C was screwing around with SPARQL, everyone else came up with JSON-based REST APIs. They work well. Not even the core W3C people use SPARQL anymore.

Re: SPARQL Protocol for RDF

#3
post #2

SPARQL is what happens when you try to define an API for doing everything, from abstract principles, and end up with an API that does nothing. It wraps your database in a worse database with a worse query language. It makes simple queries into kilobyte-long GET query strings that get morasses of XML-namespace nonsense as a response, or more likely, a server timeout. While the W3C was screwing around with SPARQL, ever…

You just keep thinking that until you see the god awful mess of REST apis that happens when you need to make an endpoint for every single slightly different query.

Re: SPARQL Protocol for RDF

#4
post #2

SPARQL is what happens when you try to define an API for doing everything, from abstract principles, and end up with an API that does nothing. It wraps your database in a worse database with a worse query language. It makes simple queries into kilobyte-long GET query strings that get morasses of XML-namespace nonsense as a response, or more likely, a server timeout. While the W3C was screwing around with SPARQL, ever…

You just keep thinking that until you see the god awful mess of REST apis that happens when you need to make an endpoint for every single slightly different query.

Yeah REST... it's for the truly patient and perseverant. Not to mention the pedantic. "REST principles"—heh. Also: JSON :(.

Thank God GraphQL is changing this paradigm and has useable and even powerful clients already. Only bad thing about GraphQL is that it targets JSON but at least it's typed and schematic.

But I guess we all benefited from REST, in the sense that it killed the whole 900-page XML book scene which was maybe the worst thing ever.

Re: SPARQL Protocol for RDF

#6
Are there queries that SPARQL can perform over a triplestore that cannot be done with SQL over normalized data? Perhaps not.

But data normalization to that end is a moving target, while a bag of subject-predicate-object statements are quite doable. This, I believe, is a uniquely powerful characteristic of linked data / graph query languages and protocols.

To that end, agree with the comment above that GraphQL is mighty exciting.

Re: SPARQL Protocol for RDF

#7
post #2

SPARQL is what happens when you try to define an API for doing everything, from abstract principles, and end up with an API that does nothing. It wraps your database in a worse database with a worse query language. It makes simple queries into kilobyte-long GET query strings that get morasses of XML-namespace nonsense as a response, or more likely, a server timeout. While the W3C was screwing around with SPARQL, ever…

I'm confused. Isn't SPARQL a query language for RDF? I've used SPARQL extensively against triple stores. It's quite handy and pretty easy to pick up once you grok how RDF is structured. I wouldn't even compare it with the concept of RESTful APIs--they're attacking two different problems.

Re: SPARQL Protocol for RDF

#9
post #6

Are there queries that SPARQL can perform over a triplestore that cannot be done with SQL over normalized data? Perhaps not. But data normalization to that end is a moving target, while a bag of subject-predicate-object statements are quite doable. This, I believe, is a uniquely powerful characteristic of linked data / graph query languages and protocols. To that end, agree with the comment above that GraphQL is migh…

GraphQL, though, is a bit of a lie nomenclature-wise. As I've experienced it, it's got nothing much to do with graphs, at least not in the sense that SPARQL deals with triples that form a graph. In this department I am really interested in TinkerPop [0].

I would love, some day, to spend some more time with triple stores, RDF and semantic technologies.

[0] http://tinkerpop.apache.org/docs/current/reference/

Re: SPARQL Protocol for RDF

#10
post #7
post #2

SPARQL is what happens when you try to define an API for doing everything, from abstract principles, and end up with an API that does nothing. It wraps your database in a worse database with a worse query language. It makes simple queries into kilobyte-long GET query strings that get morasses of XML-namespace nonsense as a response, or more likely, a server timeout. While the W3C was screwing around with SPARQL, ever…

I'm confused. Isn't SPARQL a query language for RDF? I've used SPARQL extensively against triple stores. It's quite handy and pretty easy to pick up once you grok how RDF is structured. I wouldn't even compare it with the concept of RESTful APIs--they're attacking two different problems.

What were your triple stores running on? A database, right?

Do your SPARQL queries turn into anything within orders of magnitude of an efficiently indexed SQL query when they get to the database?

Post reply on HN