[ https://issues.apache.org/jira/browse/JENA-624?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14999210#comment-14999210 ]
ASF GitHub Bot commented on JENA-624: ------------------------------------- Github user ajs6f commented on a diff in the pull request: https://github.com/apache/jena/pull/94#discussion_r44455660 --- Diff: jena-arq/src/main/java/org/apache/jena/sparql/core/DatasetGraphFactory.java --- @@ -53,45 +54,38 @@ private static void copyOver(DatasetGraph dsgDest, DatasetGraph dsgSrc) * Create a DatasetGraph starting with a single graph. * New graphs must be explicitly added. */ - public static DatasetGraph create(Graph graph) + public static DatasetGraph create(final Graph graph) { - DatasetGraph dsg2 = createMemFixed() ; + final DatasetGraph dsg2 = createMemFixed() ; dsg2.setDefaultGraph(graph) ; return dsg2 ; } - + /** * Create a DatasetGraph which only ever has a single default graph. */ - public static DatasetGraph createOneGraph(Graph graph) { return new DatasetGraphOne(graph) ; } + public static DatasetGraph createOneGraph(final Graph graph) { return new DatasetGraphOne(graph) ; } /** Interface for makign graphs when a dataset needs to add a new graph. * Return null for no graph created. - */ + */ public interface GraphMaker { public Graph create() ; } /** A graph maker that doesn't make graphs */ - public static GraphMaker graphMakerNull = new GraphMaker() { - @Override - public Graph create() - { - return null ; - } } ; - - private static GraphMaker memGraphMaker = new GraphMaker() - { - @Override - public Graph create() - { - return GraphFactory.createDefaultGraph() ; - } - } ; - + public static GraphMaker graphMakerNull = () -> null ; + + private static GraphMaker memGraphMaker = () -> GraphFactory.createDefaultGraph() ; + + /** + * @return a DatasetGraph which features transactional in-memory operation + */ + public static DatasetGraph createTxMem() { return new DatasetGraphInMemory(); } + --- End diff -- Changed. > Develop a new in-memory RDF Dataset implementation > -------------------------------------------------- > > Key: JENA-624 > URL: https://issues.apache.org/jira/browse/JENA-624 > Project: Apache Jena > Issue Type: Improvement > Reporter: Andy Seaborne > Assignee: A. Soroka > Labels: gsoc, gsoc2015, java, linked_data, rdf > > The current (Jan 2014) Jena in-memory dataset uses a general purpose > container that works for any storage technology for graphs together with > in-memory graphs. > This project would develop a new implementation design specifically for RDF > datasets (triples and quads) and efficient SPARQL execution, for example, > using multi-core parallel operations and/or multi-version concurrent > datastructures to maximise true parallel operation. > This is a system project suitable for someone interested in datatbase > implementation, datastructure design and implementation, operating systems or > distributed systems. > Note that TDB can operate in-memory using a simulated disk with > copy-in/copy-out semantics for disk-level operations. It is for faithful > testing TDB infrastructure and is not designed performance, general in-memory > use or use at scale. While lesson may be learnt from that system, TDB > in-memory is not the answer here. -- This message was sent by Atlassian JIRA (v6.3.4#6332)