[ 
https://issues.apache.org/jira/browse/JENA-1422?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16253838#comment-16253838
 ] 

ASF GitHub Bot commented on JENA-1422:
--------------------------------------

GitHub user afs opened a pull request:

    https://github.com/apache/jena/pull/310

    JENA-1422:  Transactions and switchable graphs

    

You can merge this pull request into a Git repository by running:

    $ git pull https://github.com/afs/jena JENA-1422_tdb2-loader

Alternatively you can review and apply these changes as the patch at:

    https://github.com/apache/jena/pull/310.patch

To close this pull request, make a commit to your master/trunk branch
with (at least) the following in the commit message:

    This closes #310
    
----
commit f030d2258ec74989ddef7fc560399b714cc98a52
Author: Andy Seaborne <a...@apache.org>
Date:   2017-11-15T16:04:02Z

    JENA-1422: Transactional, switchable, TDB2 graphs.
    
    Including tdb2.tbdloader loading one graph.

commit b895366750927d9e3e74c7473bebd3365a822f0e
Author: Andy Seaborne <a...@apache.org>
Date:   2017-11-15T17:26:01Z

    toString() inside a transaction.

commit e40c036a9ad797a223255edf4135984f852e2967
Author: Andy Seaborne <a...@apache.org>
Date:   2017-11-15T17:27:34Z

    JENA-1422: Tests of switchable graphs + transactions.

----


> tdb2.tdbloader fails when trying to load to named graph
> -------------------------------------------------------
>
>                 Key: JENA-1422
>                 URL: https://issues.apache.org/jira/browse/JENA-1422
>             Project: Apache Jena
>          Issue Type: Bug
>          Components: TDB2
>    Affects Versions: Jena 3.5.0
>         Environment: Ubuntu 16.04
>            Reporter: Osma Suominen
>
> I'm using Jena 3.5.0 and testing the new TDB2 store. I tried to load a 
> dataset directly into a named graph using tdb2.tdbloader.
> This is my dataset:
> {noformat}
> <http://example.org/s> <http://example.org/p> <http://example.org/o> .
> {noformat}
> Loading into the default graph works:
> {noformat}
> $ tdb2.tdbloader --loc=defaultgraph example.nt 
> 09:16:22 INFO  TDB2                 :: Finished: 1 example.nt 0,05s (Avg: 19)
> {noformat}
> Loading into a named graph using --graph option throws an exception:
> {noformat}
> $ tdb2.tdbloader --graph=http://example.org/g --loc=namedgraph example.nt 
> java.lang.ClassCastException: org.apache.jena.tdb2.store.GraphViewSwitchable 
> cannot be cast to org.apache.jena.tdb2.store.GraphTDB
>       at tdb2.cmdline.CmdTDBGraph.getGraph(CmdTDBGraph.java:70)
>       at tdb2.tdbloader.loadNamedGraph(tdbloader.java:123)
>       at tdb2.tdbloader.exec(tdbloader.java:113)
>       at jena.cmd.CmdMain.mainMethod(CmdMain.java:93)
>       at jena.cmd.CmdMain.mainRun(CmdMain.java:58)
>       at jena.cmd.CmdMain.mainRun(CmdMain.java:45)
>       at tdb2.tdbloader.main(tdbloader.java:54)
> {noformat}



--
This message was sent by Atlassian JIRA
(v6.4.14#64029)

Reply via email to