0

I have a data set with about 9 million triples in it and the owl reasoner enabled.

When the first sparql query is sent I get a seemingly endless stream of lines in the log file that look similar this:

Adding rule [ (<http://example.org/cat3> ?P ?V) ->(<http://example.org/cat2> ?P ?V) ]

These lines keep appearing until my JVM runs out of memory and the fuseki server stops functioning.

Working with a smaller data set, I can see that the rules are only generated once. Subsequent queries do not re-log the creation of these rules, unless I bounce the server process.

Is there a way to generate these rules only once and have them persisted in the database? Or some other way to avoid loading them all into memory at once?

I very much appreciate any help I can get.

Roman
  • 21
  • 3
  • the phrase "generate rules" is a bit misleading. What do you mean by this? The idea should be to materialize the triples inferred by a reasoner. Your whole setup would be interesting to know. Which reasoner? Which Fuseki version. And then you could think about whether you need the reasoning profile that you"re using – UninformedUser Mar 12 '19 at 19:09
  • Thanks. I switched the reasoner from OWLFBRuleReasoner to OWLMicroFBRuleReasoner and this seems to have fixed the issue. I don't understand the limitations of the "micro" reasoner, so I don't know if it will suffice for our needs or not. All I meant by generating rules was that I see log lines like the above appear. My assumption was it's figuring out the things it needs to do reasoning. I see none of those "adding rule" log lines if the reasoner is disabled. It maybe it's materializing triples but it's not storing them - it re-materializes them when fuseki is restarted. Fuseki version 3.10 – Roman Mar 12 '19 at 21:03
  • The `OWLMicroFBRuleReasoner` reasoner just supports RDFS plus the various property axioms, `intersectionOf`, `unionOf` (partial) and `hasValue`. It omits the cardinality restrictions (`owl:minCardinality, owl:maxCardinality, owl:cardinality`) and equality axioms (e.g. `owl:sameAs, owl:differentFrom, owl:distinctMembers`) as well as property restrictions `owl:someValuesFrom, owl:allValuesFrom`, which enables it to achieve much higher performance. – UninformedUser Mar 13 '19 at 08:37
  • And yes, you have to write the materialized triples once to the triple store. That would allow to disable the reasoner for later querying and you can directly execute queries on the inferred RDF graph. – UninformedUser Mar 13 '19 at 08:38
  • How do you write them to the triple store? – Roman Mar 13 '19 at 12:59

0 Answers0