Managing transactions with AllegroGraph's Jena API
I'm uncertain as to the behaviour of the AllegroGraph triple store in regard to transactions. The tutorial talks about using two connections, but does not mention Jena models.
If I use Model's begin(), commit(), and abort() methods, do I still need to use two connections? How does a model interact with the connection's auto-commit s开发者_开发技巧etting?
The Jena tutorial doesn't have an example of transactions, but they are supported by using the Model methods: begin, commit, and abort.
You don't have to do anything manually with 2 connections. I'll work on clarifying the language in the tutorial.
The way it's implemented, when you call begin(), it calls setAutoCommit(false).
精彩评论