Hi Robert,

On 26/05/2022 11:17, [email protected] wrote:
Hi,
I'm working with an old project developed with java 8.
I need
to use rdfstar but i can't switch to java 11.

For background - why can't you switch?

Jena's policy has always been "last 2 releases" which we interpret nowadays as "two LTS".

I have verified that
support exists starting with version 3.16.0
(https://lists.w3.org/Archives/Public/public-rdf-star/2020Aug/0001.html)

Note: RDF*, not RDF-star

Jena 3.16.0 was released 2020-07


But
the SPARQL Functions don't work:
isTRIPLE (? t)
SUBJECT (? T)
PREACH (?
T)
OBJECT (? T)

The SPARQL functions came along later.

Seems to be added to the RDF-star community spec at edit on

 Tue Mar 2 15:04:51 2021 +0100

(it was in Jena from Feb 2021)

There were other changes as well wgebb - RDF*, not RDF-star, has a special BIND operator.

The original RDF* both asserted the triple and quoted it with <<>>, RDF-star it is only quoted and not asserted, by the <<>> syntax.


This code dont work with version 3.16.0 (work with
4.4.0):
  String sq = "SELECT SUBJECT(?s) PREDICATE(?s) OBJECT(?s)rn"
  +
"WHERE {rn"
  + " ?s ?p ?orn"
  + " Filter(isTRIPLE(?s))rn"
  + "}rn"
  +
"LIMIT 100";

  Query originalQuery = QueryFactory.create(sq,
StandardCharsets.UTF_8.name());

Suggestions?

Upgrade Java - if necessary, use a container because then you control the Java version.

You could try backporting. Jena 4.3.0 (4.3.2 has log4j fixes) switch to java.net.http so at that point simply recompiling for java8 is not going to work. As this is an unrelated change, finding the right RDF-star files might be reasonably easy.

    Andy

Thanks

Reply via email to