Package org.openrdf.sail

Examples of org.openrdf.sail.Sail.shutDown()


        System.out.println("Loading " + file + ": ");
        loadFile(file, sail.getConnection(), sail.getValueFactory(), manager);
        System.out.print('\n');
      }
      manager.close();
      sail.shutDown();
    }

  private static void loadFile(final String file, SailConnection sc, ValueFactory vf, CommitManager manager) throws RDFParseException, RDFHandlerException, FileNotFoundException, IOException {
    NTriplesParser parser = new NTriplesParser(vf);
    TripleHandler handler = new TripleHandler(sc, manager);
View Full Code Here


            } finally {
                sc.rollback();
                sc.close();
            }
        } finally {
            sail.shutDown();
        }
    }

    ////////////////////////////////////////////////////////////////////////////////
View Full Code Here

                assertEquals(29, sc.size());
            } finally {
                sc.close();
            }
        } finally {
            sail.shutDown();
        }
    }

    // hastily stolen from http://stackoverflow.com/questions/941754/how-to-get-a-path-to-a-resource-in-a-java-jar-file
    private File resourceToFile(final String resource) {
View Full Code Here

    else if ("RDFS-VP".equals(entailment)) {
      sail = new ForwardChainingRDFSInferencer(sail);
      sail = new DirectTypeHierarchyInferencer(sail);
    }
    else {
      sail.shutDown();
      fail("Invalid value for entailment level:" + entailment);
    }

    Repository dataRep = new SailRepository(sail);
    dataRep.initialize();
View Full Code Here

                }
            } finally {
                store.shutDown();
            }
        } finally {
            sail.shutDown();
        }
    }

    private static Handler<Tweet> createAnnotator(final TweetStore store,
                                                  final CustomTwitterClient client) throws TweetStoreException, TwitterClientException {
View Full Code Here

                    }
                } finally {
                    store.shutDown();
                }
            } finally {
                streamingSail.shutDown();
            }
        } finally {
            workingSail.shutDown();
        }
    }
View Full Code Here

                    }
                } finally {
                    store.shutDown();
                }
            } finally {
                streamingSail.shutDown();
            }
        } finally {
            workingSail.shutDown();
        }
    }
View Full Code Here

            sc.rollback();
            sc.close();
        }

        sail.shutDown();
        baseSail.shutDown();
    }

    ////////////////////////////////////////////////////////////////////////////

    // Around 14,000 t/s on the reference machine.
View Full Code Here

                stressTest(p, 1000);
            } finally {
                store.shutDown();
            }
        } finally {
            sail.shutDown();
        }
    }

    // Reaches a peak of around 2,100 t/s and remains there indefinitely
    private void testTransientMemoryPersister() throws Exception {
View Full Code Here

                }
            } finally {
                store.shutDown();
            }
        } finally {
            sail.shutDown();
        }
    }

    // Around 900 t/s (up from 500 t/s before omitting read-operation logging)
    private void testLoggingTransientMemoryPersister() throws Exception {
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.