Code Monkey home page Code Monkey logo

4store-api's People

Contributors

mhgrove avatar peshkira avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar

4store-api's Issues

Import is very slow

Hello!

I created a fork for this issue: https://github.com/szarnyasg/4Store-API
I installed 4store on a Debian 6 virtual machine with the install-4s.sh script in the scripts directory.
The sample RDF file from http://www.govtrack.us/data/rdf/bills.099.rdf.gz in the test directory.

I compared the import times using different tools.

Import from console:

~/4Store-API/scripts$ ./httpd-start.sh && time ./curl-bills.sh 
...
201 imported successfully
This is a 4store SPARQL server v1.1.5

real    0m0.665s
user    0m0.020s
sys 0m0.004s

Import from Java with the Sail API: TestSail.java contains a JUnit test function. The import takes about 12 seconds.

Import from Java with the Store class: TestStore.java contains a JUnit test function. The import takes about 344 seconds.

Are these times normal? If not, how can I reduce the import time from Java?

Thanks,
Gabor

Current Raptor version (2.0.8) doesn't work with 4Store-API

Hello!

I installed 4store with the https://github.com/szarnyasg/4Store-API/blob/master/scripts/install-4s.sh script.

It works fine with the older versions of the Raptor/Rasqal libraries:

raptor_version=2.0.6
rasqal_version=0.9.28

But with the current versions,

raptor_version=2.0.8
rasqal_version=0.9.29

4Store-API throws an exception.

com.clarkparsia.fourstore.api.StoreException: (400) RDF parser reported errors

null
    at com.clarkparsia.fourstore.impl.StoreImpl.responseToStoreException(StoreImpl.java:789)
    at com.clarkparsia.fourstore.impl.StoreImpl.dataOperation(StoreImpl.java:708)
    at com.clarkparsia.fourstore.impl.StoreImpl.dataOperation(StoreImpl.java:668)
    at com.clarkparsia.fourstore.impl.StoreImpl.add(StoreImpl.java:486)
    at com.clarkparsia.fourstore.impl.StoreImpl.add(StoreImpl.java:498)
    at com.clarkparsia.fourstore.test.APITests.testAdd(APITests.java:320)
    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
    at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
    at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
    at java.lang.reflect.Method.invoke(Unknown Source)
    at org.junit.internal.runners.TestMethod.invoke(TestMethod.java:59)
    at org.junit.internal.runners.MethodRoadie.runTestMethod(MethodRoadie.java:98)
    at org.junit.internal.runners.MethodRoadie$2.run(MethodRoadie.java:79)
    at org.junit.internal.runners.MethodRoadie.runBeforesThenTestThenAfters(MethodRoadie.java:87)
    at org.junit.internal.runners.MethodRoadie.runTest(MethodRoadie.java:77)
    at org.junit.internal.runners.MethodRoadie.run(MethodRoadie.java:42)
    at org.junit.internal.runners.JUnit4ClassRunner.invokeTestMethod(JUnit4ClassRunner.java:88)
    at org.junit.internal.runners.JUnit4ClassRunner.runMethods(JUnit4ClassRunner.java:51)
    at org.junit.internal.runners.JUnit4ClassRunner$1.run(JUnit4ClassRunner.java:44)
    at org.junit.internal.runners.ClassRoadie.runUnprotected(ClassRoadie.java:27)
    at org.junit.internal.runners.ClassRoadie.runProtected(ClassRoadie.java:37)
    at org.junit.internal.runners.JUnit4ClassRunner.run(JUnit4ClassRunner.java:42)
    at org.eclipse.jdt.internal.junit4.runner.JUnit4TestReference.run(JUnit4TestReference.java:50)
    at org.eclipse.jdt.internal.junit.runner.TestExecution.run(TestExecution.java:38)
    at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:467)
    at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.runTests(RemoteTestRunner.java:683)
    at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.run(RemoteTestRunner.java:390)
    at org.eclipse.jdt.internal.junit.runner.RemoteTestRunner.main(RemoteTestRunner.java:197)

4s-httpd's log is the following:

$ cat /var/log/messages

Nov 17 16:29:39 debian1 4store[4969]: httpd.c:520 starting import http://4store.clarkparsia.com/test/ (683061 bytes)
Nov 17 16:29:39 debian1 4store[4969]: import.c:162 Error: The namespace prefix in "UnitOfAssessment:16:HESAInst:H-0076:Group:A" was not declared. at -1
Nov 17 16:29:39 debian1 4store[4969]: import.c:157 Warning: Using node element '16:HESAInst:H-0076:Group:A' without a namespace is forbidden. at 1
Nov 17 16:29:39 debian1 4store[4969]: import.c:162 Error: XML parser error: error parsing attribute name at -1
Nov 17 16:29:39 debian1 4store[4969]: import.c:162 Error: XML parser error: attributes construct error at -1
Nov 17 16:29:39 debian1 4store[4969]: import.c:162 Error: XML parser error: xmlParseStartTag: problem parsing attributes at -1
Nov 17 16:29:39 debian1 4store[4969]: import.c:162 Error: XML parser error: Couldn't find end of Start Tag http: at -1
Nov 17 16:29:39 debian1 4store[4969]: httpd.c:642 finished import http://4store.clarkparsia.com/test/
Nov 17 16:29:39 debian1 4store[4969]: httpd.c:303 HTTP error, returning status 400 RDF parser reported errors
Nov 17 16:29:39 debian1 4store[4969]: httpd.c:799 deleted model <http://4store.clarkparsia.com/test/>
Nov 17 16:29:39 debian1 4store[4969]: httpd.c:303 HTTP error, returning status 200 deleted successfully

I couldn't find any issues or documentation for this. I suspect it might be connected with the support for SPARQL 1.1, but I'm not sure.

Thanks,
Gabor

migrate stub rdf api

i didnt want to get us stuck with a particular API, so i just did a simple implementation of the basics, (literals, resources, statements, etc.) -- though I ended up using rio for parsing, so we end up on sesame anyway.

so may as well just migrate to using the sesame graph api and rio by default. its at least more lightweight than jena's api, and either is far preferable to that rdf2go nonsense.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.