LorenzBuehmann opened a new issue, #1442:
URL: https://github.com/apache/jena/issues/1442

   ### Version
   
   4.6.0 latest SNAPSHOT
   
   ### What happened?
   
   When using both, the text and the geo index the order of wrapping both 
matters.
   
   **Works**: TDB2 -> Geo -> Text -> Service
   **Fails**:  TDB2 -> Text  -> Geo-> Service
   
   
   The reason is basically that the geo calls
   ```
   boolean isEmpty = dataset.calculate(()->dataset.isEmpty());
   ```
   which as far as I understand is a "promoting" transaction. The problem is, 
that the text index implementation never implemented handling those, see the 
lines in 
[DatasetGraphText](https://github.com/apache/jena/blob/main/jena-text/src/main/java/org/apache/jena/query/text/DatasetGraphText.java#L159-L161)
   
   The question is now:
   - Do we have to implement handling that transaction type?
   - Or should we call `dataset.calc()` instead which is no promoting type? 
What would be the implications here?
   
   Attached are 2 assembler files, need GeoSPARQL module enabled in Fuseki (we 
should make this default anyways I think and add it to the POM similar to text 
being enabled by default)
   
   
[fails_tdb2_text_geo_assembler.ttl.gz](https://github.com/apache/jena/files/9118293/fails_tdb2_text_geo_assembler.ttl.gz)
   
[works_tdb2_geo_text_assembler.ttl.gz](https://github.com/apache/jena/files/9118295/works_tdb2_geo_text_assembler.ttl.gz)
    
   
   ### Relevant output and stacktrace
   
   ```shell
   Caused by: java.lang.UnsupportedOperationException: begin(READ_PROMOTE)
        at 
org.apache.jena.query.text.DatasetGraphText.begin(DatasetGraphText.java:161) 
~[fuseki-server.jar:4.6.0-SNAPSHOT]
        at org.apache.jena.sparql.core.DatasetImpl.begin(DatasetImpl.java:114) 
~[fuseki-server.jar:4.6.0-SNAPSHOT]
        at org.apache.jena.system.Txn.calc(Txn.java:96) 
~[fuseki-server.jar:4.6.0-SNAPSHOT]
        at org.apache.jena.system.Txn.calculate(Txn.java:67) 
~[fuseki-server.jar:4.6.0-SNAPSHOT]
        at 
org.apache.jena.sparql.core.Transactional.calculate(Transactional.java:248) 
~[fuseki-server.jar:4.6.0-SNAPSHOT]
        at 
org.apache.jena.geosparql.assembler.GeoAssembler.prepareSpatialExtension(GeoAssembler.java:176)
 ~[fuseki-server.jar:4.6.0-SNAPSHOT]
        at 
org.apache.jena.geosparql.assembler.GeoAssembler.createDataset(GeoAssembler.java:158)
 ~[fuseki-server.jar:4.6.0-SNAPSHOT]
        at 
org.apache.jena.sparql.core.assembler.DatasetAssembler.open(DatasetAssembler.java:40)
 ~[fuseki-server.jar:4.6.0-SNAPSHOT]
        at 
org.apache.jena.sparql.core.assembler.DatasetAssembler.open(DatasetAssembler.java:33)
 ~[fuseki-server.jar:4.6.0-SNAPSHOT]
        at 
org.apache.jena.assembler.assemblers.AssemblerGroup$PlainAssemblerGroup.openBySpecificType(AssemblerGroup.java:157)
 ~[fuseki-server.jar:4.6.0-SNAPSHOT]
   ```
   
   
   ### Are you interested in making a pull request?
   
   _No response_


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to