Jena 3.2.0 tdbload2 riotException: Failed to determine the content type - jena

I used tdbload2 (in jena3.2.0) to build database from freebase-rdf-latest.
An error occured,
[cc#localhost dir]$ ../apache-jena-3.2.0/bin/tdbloader2 --loc=./d-freebase/ ./freebase-rdf-latest
21:33:22 INFO -- TDB Bulk Loader Start
21:33:22 INFO Data Load Phase
21:33:22 INFO Got 1 data files to load
21:33:22 INFO Data file 1: freebase-rdf-latest
INFO Load: freebase-rdf-latest -- 2017/04/06 21:33:23 CST
org.apache.jena.riot.RiotException: Failed to determine the content type: (URI=freebase-rdf-latest : stream=null)
at org.apache.jena.riot.RDFDataMgr.process(RDFDataMgr.java:854)
at org.apache.jena.riot.RDFDataMgr.parse(RDFDataMgr.java:667)
at org.apache.jena.riot.RDFDataMgr.parse(RDFDataMgr.java:637)
at org.apache.jena.riot.RDFDataMgr.parse(RDFDataMgr.java:626)
at org.apache.jena.riot.RDFDataMgr.parse(RDFDataMgr.java:617)
at org.apache.jena.tdb.store.bulkloader2.ProcNodeTableBuilder.exec(ProcNodeTableBuilder.java:78)
at tdb.bulkloader2.CmdNodeTableBuilder.exec(CmdNodeTableBuilder.java:113)
at jena.cmd.CmdMain.mainMethod(CmdMain.java:93)
at jena.cmd.CmdMain.mainRun(CmdMain.java:58)
at jena.cmd.CmdMain.mainRun(CmdMain.java:45)
at tdb.bulkloader2.CmdNodeTableBuilder.main(CmdNodeTableBuilder.java:61)
21:33:23 ERROR Failed during data phase
But when I used tdbload2 in jena 2.12.1, no error occured!
So, I wonder why RiotException was raised when I used tdbload2 in jena 3.2.0?
The format of freebase-rdf-latest,
<http://rdf.freebase.com/ns/american_football.football_player.footballdb_id> <http://rdf.freebase.com/ns/type.object.type> <http://rdf.freebase.com/ns/type.property> .
<http://rdf.freebase.com/ns/american_football.football_player.footballdb_id> <http://rdf.freebase.com/ns/type.object.name> "footballdb ID"#en .
<http://rdf.freebase.com/ns/american_football.football_player.footballdb_id> <http://rdf.freebase.com/ns/type.property.unique> "true" .

I'm not sure about Jena version 2.12.1, but I've found with Jena version 3.2.0, I need to specify the content type using the file extension.
Try renaming your input file from "./freebase-rdf-latest" to "./freebase-rdf-latest.nt".

Related

Create msix package for a website using makeappx.exe

I'm trying to create msix package for a website using makeappx.exe (eg: makeappx pack /d C:\temp\mywebsite /p C:\temp\mywebsite.msix)
What would be the executable value since this is website?
Here is my Application section from AppxManifest.xml
<Application Id="MyWebSite" Executable="MyWebSite" EntryPoint="Windows.FullTrustApplication">
Here is an error that I got:
MakeAppx : error: Error info: error C00CE169: App manifest validation
error: The app manifest must be valid as per schema: Line 23, Column
44, Reason: 'Mywebsite' violates pattern constraint of
'.+.([Ee][Xx][Ee])'. The attribute 'Executable' with value
'MyWebSite' failed to parse.
I believe you need to set the StartPage attribute, not Executable, to point to your website.
Here you can find the schema for the AppXManifest file, with more details on each attribute from the Application element.

Error loading DBPedia Turtle in Virtuoso with Docker

I downloaded DBPedia turtle-files with their extraction framework (https://github.com/dbpedia/extraction-framework).
Then I used the docker image tenforce/virtuoso:1.3.2-virtuoso7.2.2 after extracting all ttl.bz2 to a toLoad folder.
After the full load, I checked isql with select * from DB.DBA.LOAD_LIST; and got an error from one of the files:
2 2019.2.2 11:31.43 69876000 2019.2.2 11:31.44 521623000 0 NULL 37000
[Vectorized Turtle loader] SP029: TURTLE RDF loader, line 172395:
syntax error
The virtuoso endpoint (http://localhost:8890/sparql) is online, but the queries don't return correct results.
Do you know what I can do to correct this error?
UPDATE: newer tenforce/virtuoso:1.3.2-virtuoso7.2.5.1 and openlink/virtuoso-opensource-7 were also tested giving the same result.
UPDATE 2: Line 172395 of that file seems ok: <http://pt.dbpedia.org/resource/Reino_de_Roma> <http://dbpedia.org/ontology/governmentType> <http://pt.dbpedia.org/resource/Monarquia> <http://pt.wikipedia.org/wiki/Reino_de_Roma?oldid=53119289&ns=0> .
As I said in your duplicate post on github --
I would start by using tenforce/virtuoso:latest or tenforce/virtuoso:virtuoso7.2.5 or tenforce/virtuoso:1.3.2-virtuoso7.2.5, all of which should be based on Virtuoso 7.2.5.1 (from August 2018), rather than the rather elderly tenforce/virtuoso:1.3.2-virtuoso7.2.2 which is based on the similarly elderly Virtuoso 7.2.2 (from December 2015).

A apoc.import.json procedure with can't read url error

I've installed a neo4j in my lab's centOS server.I want to import a json file into neo4j.
I've already put the apoc-3.3.0.1.jar in the NEO4J_HOME/plugins and add the
apoc.import.file.enabled=true
into neo4j.conf
Then i open the web UI of neo4j with my PC(windows 10) and input the cypher
call apoc.load.json("file:///C://Users//stefen//Desktop//test.json")yield value as company
create(c:company)
with c,company
unwind company.organizationInformationList as a
set c = a
The json file is saved in my pc.
And error info is:
Failed to invoke procedure apoc.load.json: Caused by: java.lang.RuntimeException: Can't read url file:/C://Users//stefen//Desktop//test.json as json: /C:/Users/stefen/Desktop/test.json
I have no idea where is the problem.Please help me.
PS:my neo4j version is 3.3.1
I'm sorry. I have made a mistake that i forget to put the data file in my server.
Now i have solved the question.

How to resolve unhandled error in Flume while extracting Tweets

Receiving Unhandled error - org.apache.flume.node.PollingPropertiesFileConfigurationProviders$FileWatchRunnable.run(PollingPropertiesFileConfigurationProvider.java
I am trying to extract Tweets into HDFS using Flume. But getting org.apache.flume.node.PollingPropertiesFileConfigurationProvider$FileWatchRunnable.run(PollingPropertiesFileConfigurationProvider.java) Unhandled Error
Configuration, Env.Sh file and .bashrc file details are included in the attached file. File also aontains the Twitter4j version (4j.0
Please have a look and suggest the Resolution.
DETAILS ATTACHED....
I was getting the same error with Flume-1.6 version. In flume.conf, update Twitter source type as below:
TwitterAgent.sources.Twitter.type = org.apache.flume.source.twitter.TwitterSource
I didn't use flume-sources-1.0.SNAPSHOT.jar
Thanks.

symfony 1.4: error with include_once()

after installing sfDoctrineApplyPlugin-1.1.1, extracting Zend at
lib/vendor/Zend, executing sfApply/apply and submitting the form that
appears i get this errror:
Warning:
include_once(Zend/Loader/Autoloader.php)
[function.include-once]: failed to
open stream: No such file or directory
in
/home/ptiteshina/workspace/sfprojects/moonrave/plugins/sfDoc
trineApplyPlugin/modules/sfApply/lib/BasesfApplyActions.clas
s.php on line 350
Warning: include_once()
[function.include]: Failed opening
'Zend/Loader/Autoloader.php' for
inclusion
(include_path='/home/ptiteshina/workspace/sfprojects/moonrav
e/lib/vendor:.:/usr/share/php:/usr/share/pear')
in
/home/ptiteshina/workspace/sfprojects/moonrave/plugins/sfDoc
trineApplyPlugin/modules/sfApply/lib/BasesfApplyActions.clas
s.php on line 350
Fatal error: Class
'Zend_Loader_Autoloader' not found in
/home/ptiteshina/workspace/sfprojects/moonrave/plugins/sfDoc
trineApplyPlugin/modules/sfApply/lib/BasesfApplyActions.clas
s.php on line 351
If i write
include_once('/opt/lampp/htdocs/rs7/lib/vendor/Zend/library/Zend/Loader/Autoloader.php');
the error disappears, but you know, i can not use absolute paths.
I tried with some piece of paths instead but it didn't work.
Any idea?
Javi
Did you read Installing and configuring the Zend Framework part of a jobeet tutorial? There's a simple way to use Zend autoloader in a ProjectConfiguration.

Resources