Skip to content

Jena 6 ont-api#32

Open
namedgraph wants to merge 8 commits into
masterfrom
rf-jena-6-ont-api
Open

Jena 6 ont-api#32
namedgraph wants to merge 8 commits into
masterfrom
rf-jena-6-ont-api

Conversation

@namedgraph

Copy link
Copy Markdown
Member

No description provided.

namedgraph and others added 8 commits June 18, 2026 13:36
- Add jena-ontapi:6.1.0 dependency
- Migrate SD, A vocabularies off the deprecated-for-removal org.apache.jena.ontology API to org.apache.jena.ontapi (OntModelFactory/OntSpecification, createOntClass/createDataProperty)
- Add PrefixGraphRepository (extends DocumentGraphRepository): exact + longest-prefix URI->location mapping, HTTP loading via GraphStoreClient and classpath/file via RIOT StreamManager; replaces the DataManagerImpl loader, PrefixMapper and ontology ModelGetter
- Add PrefixGraphRepositoryTest

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
…r-app repositories

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
…ager from the stack

The data-access layer is now fully off the legacy org.apache.jena.util.FileManager / ontology ModelGetter. Loading + caching is GraphRepository; GSP is GraphStoreClient. Core Application no longer creates a DataManager.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
ontapi OWL2_* profiles (DL and Full) do not recognize bare rdfs:Class as an OntClass; legacy OntModelSpec.OWL_MEM is OWL 1 Full and does. Vocab holders SD/A use OWL1_FULL_MEM.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
PrefixGraphRepository.load parsed classpath/file documents with the file location as base, so relative URIs in the document (e.g. acl.rdf's <rdf:Description rdf:about=""> ontology resource) resolved against the location instead of the graph URI — losing the imported ontology's terms under its canonical URI. Use the graph id as the parser base, matching the legacy FileManager/OntDocumentManager behavior.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
SD.<clinit> ran m_model.createIndividual(...) for SPARQL10Query/SPARQL11Query/SPARQL11Update, but the OWL1 profile (OWL1_FULL_MEM, used so rdfs:Class is recognized as an OntClass) rejects named individuals — ontapi throws OntJenaException$Creation, which propagated out of Application.init() via ServiceImplementation.canWrap and prevented the webapp from starting. Create them as plain typed resources instead (identical RDF, works in any profile).

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
The ontologies are normalized to owl:Class (see LinkedDataHub), so the OWL2 profile recognizes them as OntClass while also allowing named individuals — SD's Language individuals go back to createIndividual().

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
…ite with RDFWriter

- Delete PrefixGraphRepository + test: Core is not ontology-aware, and this
  GraphRepository (owl:imports resolution) is used only by downstream Web-Client/LinkedDataHub
- ModelProvider/DatasetProvider: use RDFWriter instead of deprecated Model.write,
  keeping basic (plain) RDF/XML output

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant