Hi All,
We have the following method where we are using Jena 2, where we are trying to 
fetch/ create Model object from ModelRDB utility method using 
com.hp.hpl.jena.db.IDBConnection 
    private Model getModelFromRDFStore(String modelName, IDBConnection conn)    
    
    {
        Model model = null;
        if (!conn.containsModel(modelName)) {
            model = ModelRDB.createModel(conn, modelName);
        }
        else {
            model = ModelRDB.open(conn, modelName);
        }

        return model;
    }

com.hp.hpl.jena.db.IDBConnection basically encapsulates a JDBC connection.

Now support for com.hp.hpl.jena.db.IDBConnection and corresponding implementing 
classes has been removed from Jena 3.
This is the functionality which we are trying to replicate in Jena 3.

So can you please guide how can we achieve this functionality in Jena 3 using 
TDB or something else?

Regards,
Ashwani

On 06/01/20, 3:55 AM, "Andy Seaborne" <[email protected]> wrote:

    
    
    On 05/01/2020 09:15, Ashwani Rathi wrote:
    > Hi,
    > 
    > We are upgrading from jena 2 to jena 3 in our project.
    > 
    > While jena used to have the following two classes in jena.jar:
    > com.hp.hpl.jena.db.DBConnection
    > com.hp.hpl.jena.db.IDBConnection
    
    That is the very old RDB layer; I am no sure it was ever released as 
    Apache Jena release. Which version of Jena do you have? 2.6.4 or earlier?
    
    > there are no such classes in jena 3
    
    There have been a lot of changes, including going from RDF 1.0 to RDF 1.1.
    
    > We are using these classes in our project.
    > 
    > Can someone guide me or provide a prototype on what claaes in jena 3 can 
be used to provide functionality for these missing classes?
    
    The current persistent storage options are TDB (TDB1, and TDB2). These 
    are custom RDF storage systems.  They scale better, load faster, run 
    faster and are more robust than RDB. There is a SQL-backed storage 
    system as well but we don't recommend it for any new work - and it is 
    not compatible in any way with RDB.
    
    But if, as I suspect, this is a big version jump, maybe the place to 
    start is describing what use of RDF is made by your project?  Is it 
    using the Model API? Some early SPARQL?
    
         Andy
    
    > Regards,
    > 
    > Ashwani
    > 
    > 
    


Reply via email to