So uhm, full rollback ?
The original idea was to make it a bit easier to have different parsers/writers for the same serialization format, in particular JSON-LD
(otherwise some dependencies will trickle down via the helpers package)
But if the idea would be to switch to Titanium JSON-LD library in 5.0 and remove the current (unmaintained ?) JSON-LD Java library,
moving the settings might not be worth the effort …
Best regards,
Bart
From: rdf4j-dev <rdf4j-dev-bounces@xxxxxxxxxxx>
On Behalf Of Erik Godding Boye
Sent: zondag 21 mei 2023 13:32
To: rdf4j developer discussions <rdf4j-dev@xxxxxxxxxxx>
Subject: Re: [rdf4j-dev] Breaking change in latest minor release (4.3.0)?
I agree, at least to a certain extent. Deprecating something without a migration/replacement is not very user-friendly, and will create a lot of "noise" (deprecation warnings that a user cannot do anything about). I tried to come up with
something that allowed us to fulfill Barts intensions in the PR, but enums I Java are extremely painful, and should not be used in a public API IMO. I am working a lot with Kuberntes controllers, and even if enums also exists in Golang, it is NOT recommended
to use them in an API.
I took a look at the PR where the various parser/writer settings are deprecated and I’m a bit worried about there being side effects that are hard to predict if the code assumes that the new settings are used instead of the deprecated ones.
It’s also hard for me to see how it would affect classes that are extending the current parsers and writers.
We haven’t published a news item about the current release, so I’m inclined to remove the new settings and just keep the deprecations. That will make 5.0.0 a bit more of a hard transition, but at least we don’t inadvertently break something
in 4.3. I can’t really unpublish the 4.3.0 release, but I think that if we release 4.3.1 asap and then note in the release notes that we recommend using 4.3.1 instead of 4.3.0 it should be fine.
Hmz, existing code should still work, the idea is to deprecate the settings in the helper packages (to be removed in 5.0),
and move them to parser-specific ones
Bart
It seems like the classes are duplicated, and I think the relevant changes are in this PR: https://github.com/eclipse/rdf4j/pull/4332
No compiler error, but one of our tests were failing with the following error:
30261 [ERROR] verifyDatatypeReasoning Time elapsed: 0.026 s <<< ERROR!
java.lang.ClassCastException: class org.eclipse.rdf4j.rio.helpers.JSONLDMode cannot be cast to class org.eclipse.rdf4j.rio.jsonld.JSONLDMode (org.eclipse.rdf4j.rio.helpers.JSONLDMode and org.eclipse.rdf4j.rio.jsonld.JSONLDMode are in unnamed module of loader
'app')
at no.statnett.rdf4j.rio.DatatypeReasonerRDFHandlerTest.verifyDatatypeReasoning(DatatypeReasonerRDFHandlerTest.java:54)
It’s a bit hard to read the diff in an email, but it looks like a package has moved?
-import org.eclipse.rdf4j.rio.helpers.JSONLDMode;
-import org.eclipse.rdf4j.rio.helpers.JSONLDSettings;
+import org.eclipse.rdf4j.rio.jsonld.JSONLDMode;
+import org.eclipse.rdf4j.rio.jsonld.JSONLDSettings;
Håvard
> On 20 May 2023, at 16:52, Erik Godding Boye <egboye@xxxxxxxxx> wrote:
>
>
> Hi all,
>
> In one of our projects, I had to modify code upgrading to rdf4j 4.3.0, see the patch below.
> Is that expected? It appears like a breaking change to me.
🤔
>
> Erik
>
> Subject: [PATCH] chore: upgrade rdf4j to version 4.3.0
>
> ---
> pom.xml | 2 +-
> src/test/java/no/statnett/rdf4j/utils/Writers.java | 4 ++--
> 2 files changed, 3 insertions(+), 3 deletions(-)
>
> diff --git a/pom.xml b/pom.xml
> index d04aba1..ff31423 100644
> --- a/pom.xml
> +++ b/pom.xml
> @@ -19,7 +19,7 @@
> <properties>
> <spring-boot.version>2.7.12</spring-boot.version>
> <graphdb.version>10.2.1</graphdb.version>
> - <rdf4j.version>4.2.4</rdf4j.version>
> + <rdf4j.version>4.3.0</rdf4j.version>
> <cxf.version>3.6.0</cxf.version>
>
> <graphdb.dist.folder>${project.build.directory}/graphdb-${graphdb.version}</graphdb.dist.folder>
> diff --git a/src/test/java/no/statnett/rdf4j/utils/Writers.java b/src/test/java/no/statnett/rdf4j/utils/Writers.java
> index fe450ab..03a2091 100644
> --- a/src/test/java/no/statnett/rdf4j/utils/Writers.java
> +++ b/src/test/java/no/statnett/rdf4j/utils/Writers.java
> @@ -4,8 +4,8 @@
> import org.eclipse.rdf4j.rio.RDFWriter;
> import org.eclipse.rdf4j.rio.Rio;
> import org.eclipse.rdf4j.rio.helpers.BasicWriterSettings;
> -import org.eclipse.rdf4j.rio.helpers.JSONLDMode;
> -import org.eclipse.rdf4j.rio.helpers.JSONLDSettings;
> +import org.eclipse.rdf4j.rio.jsonld.JSONLDMode;
> +import org.eclipse.rdf4j.rio.jsonld.JSONLDSettings;
>
> import java.net.URISyntaxException;
>
> --
> _______________________________________________
> rdf4j-dev mailing list
> rdf4j-dev@xxxxxxxxxxx
> To unsubscribe from this list, visit
https://www.eclipse.org/mailman/listinfo/rdf4j-dev
_______________________________________________
rdf4j-dev mailing list
rdf4j-dev@xxxxxxxxxxx
To unsubscribe from this list, visit
https://www.eclipse.org/mailman/listinfo/rdf4j-dev
_______________________________________________
rdf4j-dev mailing list
rdf4j-dev@xxxxxxxxxxx
To unsubscribe from this list, visit
https://www.eclipse.org/mailman/listinfo/rdf4j-dev
_______________________________________________
rdf4j-dev mailing list
rdf4j-dev@xxxxxxxxxxx
To unsubscribe from this list, visit
https://www.eclipse.org/mailman/listinfo/rdf4j-dev
_______________________________________________
rdf4j-dev mailing list
rdf4j-dev@xxxxxxxxxxx
To unsubscribe from this list, visit
https://www.eclipse.org/mailman/listinfo/rdf4j-dev
|