From 4c37849486d6520909712e8b838df1583fc18bce Mon Sep 17 00:00:00 2001 From: anton Date: Wed, 22 May 2024 15:15:42 +0200 Subject: [PATCH] FAIRSPC-69: fixed the Fuseki SPARQL endpoint which stopped working after upgrade of Jena from --- projects/saturn/build.gradle | 2 +- .../src/main/java/io/fairspace/saturn/services/BaseApp.java | 5 ++++- 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/projects/saturn/build.gradle b/projects/saturn/build.gradle index 1b6671815..d57939c6e 100644 --- a/projects/saturn/build.gradle +++ b/projects/saturn/build.gradle @@ -1,6 +1,6 @@ buildscript { ext { - jena_version = '4.10.0' + jena_version = '4.10.0' // todo: upgrade to 5+ (FAIRSPC-69) milton_version = '3.1.1.488' // Milton >= 4 is migrated to Jakarta EE 9, which is not compatible with Jena < 5 (no stable release of Jena 5 yet). To be updated when Jena 5 is released. mockitoVersion = '5.11.0' jacksonVersion = '2.15.3' // check what version is used by Jena diff --git a/projects/saturn/src/main/java/io/fairspace/saturn/services/BaseApp.java b/projects/saturn/src/main/java/io/fairspace/saturn/services/BaseApp.java index 06fa1427c..e2f9568ba 100644 --- a/projects/saturn/src/main/java/io/fairspace/saturn/services/BaseApp.java +++ b/projects/saturn/src/main/java/io/fairspace/saturn/services/BaseApp.java @@ -38,7 +38,10 @@ protected BaseApp(String basePath) { public final void init() { path(basePath, () -> { notFound((req, res) -> { - if (req.pathInfo().startsWith("/api/webdav") || req.pathInfo().startsWith("/api/extra-storage")) { + String pathInfo = req.pathInfo(); + if (pathInfo.startsWith("/api/webdav") + || pathInfo.startsWith("/api/extra-storage") + || pathInfo.startsWith("/api/rdf")) { return null; } return errorBody(SC_NOT_FOUND, "Not found");