Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

feat: Add an RDF processing façade (2nd iteration) (DSP-1083) #1759

Merged
merged 14 commits into from Nov 24, 2020

Conversation

@benjamingeer
Copy link
Collaborator

@benjamingeer benjamingeer commented Nov 18, 2020

resolves DSP-1083

  • Add RDF stream processing to RdfFormatUtil, and use it in:
    • HttpTriplestoreConnector.turtleToTrig
    • ProjectsResponderADM.projectDataGetRequestADM
    • RepositoryUpdater
  • Add RdfRepository for using SPARQL to query an RdfModel in a test.
    • Move SparqlSelectResponse from TriplestoreMessages into org.knora.webapi.messages.util.rdf, and rename it SparqlSelectResult, so it can be used with RdfRepository.
    • Rename InconsistentTriplestoreDataException -> InconsistentRepositoryDataException so it can be used with RdfRepository.
  • Refactor the repository update framework, plugins, and tests to use the RDF façade.
  • Refactor TEIHeader to use the RDF façade.
    • Change RDF/XML formatting so that, when pretty-printing is off, all elements are rdf:Description elements, to facilitate writing XSLT stylesheets. (Previously, you could get a mix of rdf:Description elements and typed elements, making it difficult to write XPath.)
    • Change the sample XSLT stylesheet for generating a TEI/XML header, test_data/test_route/texts/beol/header.xsl (used by KnoraSipiIntegrationV1ITSpec), so it works with RDF/XML in that format.
  • Add tests.
  • Update docs.

For the next PR:

  • Add SHACL validation API.
@benjamingeer benjamingeer changed the title feat: Add an RDF processing façade (2nd iteration) feat: Add an RDF processing façade (2nd iteration) (DSP-1083) Nov 18, 2020
@benjamingeer benjamingeer self-assigned this Nov 18, 2020
- Move SparqlSelectResponse to RDF API, rename to SparqlSelectResult.
@benjamingeer benjamingeer marked this pull request as draft Nov 20, 2020
@benjamingeer benjamingeer marked this pull request as ready for review Nov 23, 2020
@benjamingeer benjamingeer requested a review from SepidehAlassi Nov 23, 2020
# Conflicts:
#	webapi/src/main/scala/org/knora/webapi/responders/admin/ListsResponderADM.scala
Copy link
Contributor

@SepidehAlassi SepidehAlassi left a comment

This looks great, thank you for implementing this.

}
}

// Wrap that Map in an ErrorHandlingMap that will gracefully report errors about missing values when they

This comment has been minimized.

@SepidehAlassi

SepidehAlassi Nov 24, 2020
Contributor

gracefully :-D

@@ -906,7 +907,7 @@ class SearchResponderV2(responderData: ResponderData) extends ResponderWithStand
}

prequeryResponseNotMerged.copy(
results = SparqlSelectResponseBody(prequeryRowsMerged)
results = SparqlSelectResultBody(prequeryRowsMerged)
)
}
}

This comment has been minimized.

@SepidehAlassi

SepidehAlassi Nov 24, 2020
Contributor

ha, I found something. Please add an empty line here :-D

@benjamingeer
Copy link
Collaborator Author

@benjamingeer benjamingeer commented Nov 24, 2020

Thanks for the review! I will try harder to make more mistakes next time. :)

@benjamingeer benjamingeer merged commit 346873d into main Nov 24, 2020
8 checks passed
8 checks passed
Build Everything
Details
API Unit Tests
Details
API E2E Tests
Details
API Integration Tests
Details
Upgrade Integration Tests
Details
Docs Build Test
Details
Update next release draft
Details
Publish (on release only)
Details
@benjamingeer benjamingeer deleted the wip/DSP-1083-rdf-api branch Nov 24, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Linked issues

Successfully merging this pull request may close these issues.

None yet

2 participants