Hi,

So we'll continue this discussion on the developers list.

A little recap. So far, I've been making mockups, setting up my DBpedia mirror, 
researching and most recently playing around with AngularJS and how to get it 
to work with the DBpedia SPARQL interface. What is accomplished so far (on a 
toy Angular setup, not the DBpedia mirror):
fetching entities from the SPARQL endpoint using a descriptive SELECT query and 
using HTTP POST (to prevent any errors due to the 1900 char limit of URLs in 
Virtuoso) is donejust to test, fetching DBpedia Lookup results from its API 
also workshashless routing enabledno-JavaScript support tests:the first test 
was to test overlap of URL addresses (between static files on the webserver and 
Angular routes)
the second test on my toy setup was to get the Angular implementation to look 
for a JSON hidden in the loaded HTML page and use that to show triples. If 
there is no such JSON on the page, DBpedia SPARQL endpoint is queried. Also, 
when we want to view another entity from this initially loaded HTML page (with 
preloaded JSON description), the DBpedia SPARQL endpoint is queried (at least, 
if you have JavaScript enabled) to get us to the next entity (instead of a full 
page load from the server). Without JS, all queries just go to the DBpedia web 
server.
Conclusion:
AngularJS seems to work properly for our purposes
now I have a concrete idea how to support no-JS with AngularJS


Now, the question with respect to the noscript version is: is it better to put 
the JSON in HTML at the server or is it better to use RDFa scraping code at 
client side?
RDFa scraping at client will increase the load on their browsers, and you're 
reverse-engineering the source in a sense.
adding JSON at the server will add load on the server, but probably less (per 
request) than RDFa scraping at the client (here you're 
"forward"-engineering).it will also make the pages sent to the clients  much 
bigger (but I guess that's not really an issue)

My main worry is that it may take quite a while at the client to scrape a 10MB 
page (a big entity, e.g. <dbpedia:Sweden>) in JavaScript before showing the 
pretty version from the scraped data. Whereas including some 3 MB of JSON at 
the server would have just little computational overhead when building the page 
(although will increase traffic). But since I don't have as much insight in the 
VSP code as the one who wrote it (Dimitris?), I'm not completely sure about 
that last fact ("little computational overhead"). Is it correct?



Which one do you think is best (HTML+JSON or HTML->RDFa-scraper->JSON)?


Greetings,


Denis

                                          
------------------------------------------------------------------------------
See everything from the browser to the database with AppDynamics
Get end-to-end visibility with application monitoring from AppDynamics
Isolate bottlenecks and diagnose root cause in seconds.
Start your free trial of AppDynamics Pro today!
http://pubads.g.doubleclick.net/gampad/clk?id=48808831&iu=/4140/ostg.clktrk
_______________________________________________
Dbpedia-developers mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/dbpedia-developers

Reply via email to