From ad4bfe35c22791f079a1d2d681162329e2823205 Mon Sep 17 00:00:00 2001 From: Tpt Date: Thu, 27 Jan 2022 19:21:48 +0100 Subject: [PATCH] Fixes typos in the documentation --- README.md | 2 +- bench/README.md | 16 ++++++++-------- js/README.md | 2 +- lib/README.md | 2 +- lib/oxrdf/README.md | 2 +- lib/oxrdf/src/blank_node.rs | 16 ++++++++-------- lib/oxrdf/src/dataset.rs | 8 ++++---- lib/oxrdf/src/literal.rs | 4 ++-- lib/oxrdf/src/named_node.rs | 4 ++-- lib/oxrdf/src/triple.rs | 16 ++++++++-------- lib/sparesults/README.md | 2 +- lib/sparesults/src/lib.rs | 2 +- lib/spargebra/README.md | 2 +- lib/spargebra/src/term.rs | 8 ++++---- lib/src/io/format.rs | 2 +- lib/src/storage/backend/rocksdb.rs | 2 +- lib/src/store.rs | 8 ++++---- python/README.md | 2 +- python/docs/index.rst | 4 ++-- python/src/io.rs | 4 ++-- python/src/model.rs | 12 ++++++------ python/src/store.rs | 20 ++++++++++---------- server/README.md | 12 ++++++------ 23 files changed, 76 insertions(+), 76 deletions(-) diff --git a/README.md b/README.md index de75b2a1..48831f97 100644 --- a/README.md +++ b/README.md @@ -51,4 +51,4 @@ at your option. ### Contribution -Unless you explicitly state otherwise, any contribution intentionally submitted for inclusion in oxigraph by you, as defined in the Apache-2.0 license, shall be dual licensed as above, without any additional terms or conditions. +Unless you explicitly state otherwise, any contribution intentionally submitted for inclusion in Oxigraph by you, as defined in the Apache-2.0 license, shall be dual licensed as above, without any additional terms or conditions. diff --git a/bench/README.md b/bench/README.md index 9a47bd44..a68a8e4e 100644 --- a/bench/README.md +++ b/bench/README.md @@ -3,15 +3,15 @@ BSBM The [Berlin SPARQL Benchmark (BSBM)](http://wifo5-03.informatik.uni-mannheim.de/bizer/berlinsparqlbenchmark/) is a simple SPARQL benchmark. -It provides a dataset generator and multiple set of queries grouped by "use cases". +It provides a dataset generator and multiple sets of queries grouped by "use cases". ## Results -We compare here Oxigraph with some existing SPARQL implementations (Blazegraph, GraphDB, Jena and Virtuoso). +We compare here Oxigraph with some existing SPARQL implementations (Blazegraph, GraphDB, Jena, and Virtuoso). The dataset used in the following charts is generated with 100k "products" (see [its spec](http://wifo5-03.informatik.uni-mannheim.de/bizer/berlinsparqlbenchmark/spec/Dataset/index.html)). It leads to the creation of 35M triples. It has been executed on a PrevailPro P3000 with 32GB of RAM. -The tests have been executed with a concurrency factor of 16 (i.e. at most 16 queries are send at the same time to the server). +The tests have been executed with a concurrency factor of 16 (i.e. at most 16 queries are sent at the same time to the server). Beware, the graph *y* axis is in log scale to properly display on the same graph systems with very different speed behaviors. @@ -23,9 +23,9 @@ Query 6 existed in previous versions of the benchmark but is now removed. ![explore use case results](bsbm.explore.svg) ### Explore and update -The [explore and update use case](http://wifo5-03.informatik.uni-mannheim.de/bizer/berlinsparqlbenchmark/spec/index.html#usecase_explore_and_update) is composed of the 2 operations of the [update use case](http://wifo5-03.informatik.uni-mannheim.de/bizer/berlinsparqlbenchmark/spec/UpdateUseCase/index.html) (`INSERT DATA` and `DELETE WHERE`) and the 11 queries of the [explore use case](http://wifo5-03.informatik.uni-mannheim.de/bizer/berlinsparqlbenchmark/spec/ExploreUseCase/index.html) and the . +The [explore and update use case](http://wifo5-03.informatik.uni-mannheim.de/bizer/berlinsparqlbenchmark/spec/index.html#usecase_explore_and_update) is composed of the 2 operations of the [update use case](http://wifo5-03.informatik.uni-mannheim.de/bizer/berlinsparqlbenchmark/spec/UpdateUseCase/index.html) (`INSERT DATA` and `DELETE WHERE`) and the 11 queries of the [explore use case](http://wifo5-03.informatik.uni-mannheim.de/bizer/berlinsparqlbenchmark/spec/ExploreUseCase/index.html). -The first two elements (1 and 2) are the 2 updates and the other (3 to 14) are the 11 queries. +The first two elements (1 and 2) are the 2 updates and the others (3 to 14) are the 11 queries. ![explore use case results](bsbm.exploreAndUpdate.svg) @@ -36,7 +36,7 @@ The [business intelligence use case](http://wifo5-03.informatik.uni-mannheim.de/ Query 4 seems to be failing on Virtuoso and query 5 on Blazegraph and GraphDB. Oxigraph is still too slow to evaluate most of the queries. -It will be added in the graph after enough optimizations are done. +It will be added to the graph after enough optimizations are done. ![explore use case results](bsbm.businessIntelligence.svg) --> @@ -46,8 +46,8 @@ It will be added in the graph after enough optimizations are done. The code of the benchmark is in the `bsbm-tools` submodule. You should pull it with a `git submodule update` before running the benchmark. To run the benchmark for Oxigraph run `bash bsbm_oxigraph.sh`. It will compile the current Oxigraph code and run the benchmark against it. -You could tweak the number of products in the dataset using the environment variables at the beginning of `bsbm_oxigraph.sh`. +You can tweak the number of products in the dataset and the number of concurrent requests using the environment variables at the beginning of `bsbm_oxigraph.sh`. To generate the plots run `python3 bsbsm-plot.py`. -Scripts are also provided for the other benchmarks (`bsbm_blazegraph.sh`, `bsbm_graphdb.sh`, `bsbm_jena.sh` and `bsbm_virtuoso.sh`). +Scripts are also provided for the other systems (`bsbm_blazegraph.sh`, `bsbm_graphdb.sh`, `bsbm_jena.sh` and `bsbm_virtuoso.sh`). diff --git a/js/README.md b/js/README.md index b59af9e2..f847aac1 100644 --- a/js/README.md +++ b/js/README.md @@ -219,4 +219,4 @@ at your option. ### Contribution -Unless you explicitly state otherwise, any contribution intentionally submitted for inclusion in Futures by you, as defined in the Apache-2.0 license, shall be dual licensed as above, without any additional terms or conditions. +Unless you explicitly state otherwise, any contribution intentionally submitted for inclusion in Oxigraph by you, as defined in the Apache-2.0 license, shall be dual licensed as above, without any additional terms or conditions. diff --git a/lib/README.md b/lib/README.md index 5918a4c3..8d3064ed 100644 --- a/lib/README.md +++ b/lib/README.md @@ -68,4 +68,4 @@ at your option. ### Contribution -Unless you explicitly state otherwise, any contribution intentionally submitted for inclusion in Futures by you, as defined in the Apache-2.0 license, shall be dual licensed as above, without any additional terms or conditions. +Unless you explicitly state otherwise, any contribution intentionally submitted for inclusion in Oxigraph by you, as defined in the Apache-2.0 license, shall be dual licensed as above, without any additional terms or conditions. diff --git a/lib/oxrdf/README.md b/lib/oxrdf/README.md index f85f35d2..ee9dc3ec 100644 --- a/lib/oxrdf/README.md +++ b/lib/oxrdf/README.md @@ -46,4 +46,4 @@ at your option. ### Contribution -Unless you explicitly state otherwise, any contribution intentionally submitted for inclusion in Futures by you, as defined in the Apache-2.0 license, shall be dual licensed as above, without any additional terms or conditions. +Unless you explicitly state otherwise, any contribution intentionally submitted for inclusion in Oxigraph by you, as defined in the Apache-2.0 license, shall be dual licensed as above, without any additional terms or conditions. diff --git a/lib/oxrdf/src/blank_node.rs b/lib/oxrdf/src/blank_node.rs index 42b0f856..ab00ae61 100644 --- a/lib/oxrdf/src/blank_node.rs +++ b/lib/oxrdf/src/blank_node.rs @@ -9,9 +9,9 @@ use std::str; /// The common way to create a new blank node is to use the [`BlankNode::default()`] function. /// /// It is also possible to create a blank node from a blank node identifier using the [`BlankNode::new()`] function. -/// The blank node identifier must be valid according to N-Triples, Turtle and SPARQL grammars. +/// The blank node identifier must be valid according to N-Triples, Turtle, and SPARQL grammars. /// -/// The default string formatter is returning an N-Triples, Turtle and SPARQL compatible representation: +/// The default string formatter is returning an N-Triples, Turtle, and SPARQL compatible representation: /// ``` /// use oxrdf::BlankNode; /// @@ -33,7 +33,7 @@ enum BlankNodeContent { impl BlankNode { /// Creates a blank node from a unique identifier. /// - /// The blank node identifier must be valid according to N-Triples, Turtle and SPARQL grammars. + /// The blank node identifier must be valid according to N-Triples, Turtle, and SPARQL grammars. /// /// In most cases, it is much more convenient to create a blank node using [`BlankNode::default()`] ///that creates a random ID that could be easily inlined by Oxigraph stores. @@ -46,7 +46,7 @@ impl BlankNode { /// Creates a blank node from a unique identifier without validation. /// /// It is the caller's responsibility to ensure that `id` is a valid blank node identifier - /// according to N-Triples, Turtle and SPARQL grammars. + /// according to N-Triples, Turtle, and SPARQL grammars. /// /// [`BlankNode::new()`] is a safe version of this constructor and should be used for untrusted data. #[inline] @@ -120,9 +120,9 @@ impl Default for BlankNode { /// The common way to create a new blank node is to use the [`BlankNode::default`] trait method. /// /// It is also possible to create a blank node from a blank node identifier using the [`BlankNodeRef::new()`] function. -/// The blank node identifier must be valid according to N-Triples, Turtle and SPARQL grammars. +/// The blank node identifier must be valid according to N-Triples, Turtle, and SPARQL grammars. /// -/// The default string formatter is returning an N-Triples, Turtle and SPARQL compatible representation: +/// The default string formatter is returning an N-Triples, Turtle, and SPARQL compatible representation: /// ``` /// use oxrdf::BlankNodeRef; /// @@ -144,7 +144,7 @@ enum BlankNodeRefContent<'a> { impl<'a> BlankNodeRef<'a> { /// Creates a blank node from a unique identifier. /// - /// The blank node identifier must be valid according to N-Triples, Turtle and SPARQL grammars. + /// The blank node identifier must be valid according to N-Triples, Turtle, and SPARQL grammars. /// /// In most cases, it is much more convenient to create a blank node using [`BlankNode::default()`]. /// that creates a random ID that could be easily inlined by Oxigraph stores. @@ -156,7 +156,7 @@ impl<'a> BlankNodeRef<'a> { /// Creates a blank node from a unique identifier without validation. /// /// It is the caller's responsibility to ensure that `id` is a valid blank node identifier - /// according to N-Triples, Turtle and SPARQL grammars. + /// according to N-Triples, Turtle, and SPARQL grammars. /// /// [`BlankNodeRef::new()`) is a safe version of this constructor and should be used for untrusted data. #[inline] diff --git a/lib/oxrdf/src/dataset.rs b/lib/oxrdf/src/dataset.rs index f3b4ec39..1a9db41b 100644 --- a/lib/oxrdf/src/dataset.rs +++ b/lib/oxrdf/src/dataset.rs @@ -105,7 +105,7 @@ impl Dataset { Self::default() } - /// Provides a read-only view on a [RDF graph](https://www.w3.org/TR/rdf11-concepts/#dfn-graph) contained in this dataset. + /// Provides a read-only view on an [RDF graph](https://www.w3.org/TR/rdf11-concepts/#dfn-graph) contained in this dataset. /// /// ``` /// use oxrdf::*; @@ -128,7 +128,7 @@ impl Dataset { } } - /// Provides a read/write view on a [RDF graph](https://www.w3.org/TR/rdf11-concepts/#dfn-graph) contained in this dataset. + /// Provides a read/write view on an [RDF graph](https://www.w3.org/TR/rdf11-concepts/#dfn-graph) contained in this dataset. /// /// ``` /// use oxrdf::*; @@ -907,7 +907,7 @@ impl fmt::Display for Dataset { } } -/// A read-only view on a [RDF graph](https://www.w3.org/TR/rdf11-concepts/#dfn-graph) contained in a [`Dataset`]. +/// A read-only view on an [RDF graph](https://www.w3.org/TR/rdf11-concepts/#dfn-graph) contained in a [`Dataset`]. /// /// It is built using the [`Dataset::graph`] method. /// @@ -1242,7 +1242,7 @@ impl<'a> fmt::Display for GraphView<'a> { } } -/// A read/write view on a [RDF graph](https://www.w3.org/TR/rdf11-concepts/#dfn-graph) contained in a [`Dataset`]. +/// A read/write view on an [RDF graph](https://www.w3.org/TR/rdf11-concepts/#dfn-graph) contained in a [`Dataset`]. /// /// It is built using the [`Dataset::graph_mut`] method. /// diff --git a/lib/oxrdf/src/literal.rs b/lib/oxrdf/src/literal.rs index d0beb8ac..4948b745 100644 --- a/lib/oxrdf/src/literal.rs +++ b/lib/oxrdf/src/literal.rs @@ -10,7 +10,7 @@ use std::option::Option; /// An owned RDF [literal](https://www.w3.org/TR/rdf11-concepts/#dfn-literal). /// -/// The default string formatter is returning an N-Triples, Turtle and SPARQL compatible representation: +/// The default string formatter is returning an N-Triples, Turtle, and SPARQL compatible representation: /// ``` /// # use oxilangtag::LanguageTagParseError; /// use oxrdf::Literal; @@ -295,7 +295,7 @@ impl From for Literal { /// A borrowed RDF [literal](https://www.w3.org/TR/rdf11-concepts/#dfn-literal). /// -/// The default string formatter is returning an N-Triples, Turtle and SPARQL compatible representation: +/// The default string formatter is returning an N-Triples, Turtle, and SPARQL compatible representation: /// ``` /// use oxrdf::LiteralRef; /// use oxrdf::vocab::xsd; diff --git a/lib/oxrdf/src/named_node.rs b/lib/oxrdf/src/named_node.rs index 56294415..23a156d6 100644 --- a/lib/oxrdf/src/named_node.rs +++ b/lib/oxrdf/src/named_node.rs @@ -4,7 +4,7 @@ use std::fmt; /// An owned RDF [IRI](https://www.w3.org/TR/rdf11-concepts/#dfn-iri). /// -/// The default string formatter is returning an N-Triples, Turtle and SPARQL compatible representation: +/// The default string formatter is returning an N-Triples, Turtle, and SPARQL compatible representation: /// ``` /// use oxrdf::NamedNode; /// @@ -93,7 +93,7 @@ impl PartialEq for &str { /// A borrowed RDF [IRI](https://www.w3.org/TR/rdf11-concepts/#dfn-iri). /// -/// The default string formatter is returning an N-Triples, Turtle and SPARQL compatible representation: +/// The default string formatter is returning an N-Triples, Turtle, and SPARQL compatible representation: /// ``` /// use oxrdf::NamedNodeRef; /// diff --git a/lib/oxrdf/src/triple.rs b/lib/oxrdf/src/triple.rs index 06f6faf3..d91c287c 100644 --- a/lib/oxrdf/src/triple.rs +++ b/lib/oxrdf/src/triple.rs @@ -696,7 +696,7 @@ impl<'a> From> for Term { /// An owned [RDF triple](https://www.w3.org/TR/rdf11-concepts/#dfn-rdf-triple). /// -/// The default string formatter is returning an N-Triples, Turtle and SPARQL compatible representation: +/// The default string formatter is returning an N-Triples, Turtle, and SPARQL compatible representation: /// ``` /// use oxrdf::{Triple, NamedNode}; /// @@ -737,7 +737,7 @@ impl Triple { } } - /// Encodes that this triple is in a [RDF dataset](https://www.w3.org/TR/rdf11-concepts/#dfn-rdf-dataset). + /// Encodes that this triple is in an [RDF dataset](https://www.w3.org/TR/rdf11-concepts/#dfn-rdf-dataset). #[inline] pub fn in_graph(self, graph_name: impl Into) -> Quad { Quad { @@ -767,7 +767,7 @@ impl fmt::Display for Triple { /// A borrowed [RDF triple](https://www.w3.org/TR/rdf11-concepts/#dfn-rdf-triple). /// -/// The default string formatter is returning an N-Triples, Turtle and SPARQL compatible representation: +/// The default string formatter is returning an N-Triples, Turtle, and SPARQL compatible representation: /// ``` /// use oxrdf::{TripleRef, NamedNodeRef}; /// @@ -809,7 +809,7 @@ impl<'a> TripleRef<'a> { } } - /// Encodes that this triple is in a [RDF dataset](https://www.w3.org/TR/rdf11-concepts/#dfn-rdf-dataset). + /// Encodes that this triple is in an [RDF dataset](https://www.w3.org/TR/rdf11-concepts/#dfn-rdf-dataset). #[inline] pub fn in_graph(self, graph_name: impl Into>) -> QuadRef<'a> { QuadRef { @@ -1009,7 +1009,7 @@ impl<'a> From> for GraphName { } } -/// An owned [triple](https://www.w3.org/TR/rdf11-concepts/#dfn-rdf-triple) in a [RDF dataset](https://www.w3.org/TR/rdf11-concepts/#dfn-rdf-dataset). +/// An owned [triple](https://www.w3.org/TR/rdf11-concepts/#dfn-rdf-triple) in an [RDF dataset](https://www.w3.org/TR/rdf11-concepts/#dfn-rdf-dataset). /// /// The default string formatter is returning an N-Quads compatible representation: /// ``` @@ -1042,7 +1042,7 @@ pub struct Quad { } impl Quad { - /// Builds an RDF [triple](https://www.w3.org/TR/rdf11-concepts/#dfn-rdf-triple) in a [RDF dataset](https://www.w3.org/TR/rdf11-concepts/#dfn-rdf-dataset). + /// Builds an RDF [triple](https://www.w3.org/TR/rdf11-concepts/#dfn-rdf-triple) in an [RDF dataset](https://www.w3.org/TR/rdf11-concepts/#dfn-rdf-dataset). #[inline] pub fn new( subject: impl Into, @@ -1087,7 +1087,7 @@ impl From for Triple { } } -/// A borrowed [triple](https://www.w3.org/TR/rdf11-concepts/#dfn-rdf-triple) in a [RDF dataset](https://www.w3.org/TR/rdf11-concepts/#dfn-rdf-dataset). +/// A borrowed [triple](https://www.w3.org/TR/rdf11-concepts/#dfn-rdf-triple) in an [RDF dataset](https://www.w3.org/TR/rdf11-concepts/#dfn-rdf-dataset). /// /// The default string formatter is returning an N-Quads compatible representation: /// ``` @@ -1120,7 +1120,7 @@ pub struct QuadRef<'a> { } impl<'a> QuadRef<'a> { - /// Builds an RDF [triple](https://www.w3.org/TR/rdf11-concepts/#dfn-rdf-triple) in a [RDF dataset](https://www.w3.org/TR/rdf11-concepts/#dfn-rdf-dataset). + /// Builds an RDF [triple](https://www.w3.org/TR/rdf11-concepts/#dfn-rdf-triple) in an [RDF dataset](https://www.w3.org/TR/rdf11-concepts/#dfn-rdf-dataset). #[inline] pub fn new( subject: impl Into>, diff --git a/lib/sparesults/README.md b/lib/sparesults/README.md index 4039d26c..bd861ef1 100644 --- a/lib/sparesults/README.md +++ b/lib/sparesults/README.md @@ -68,4 +68,4 @@ at your option. ### Contribution -Unless you explicitly state otherwise, any contribution intentionally submitted for inclusion in Futures by you, as defined in the Apache-2.0 license, shall be dual licensed as above, without any additional terms or conditions. +Unless you explicitly state otherwise, any contribution intentionally submitted for inclusion in Oxigraph by you, as defined in the Apache-2.0 license, shall be dual licensed as above, without any additional terms or conditions. diff --git a/lib/sparesults/src/lib.rs b/lib/sparesults/src/lib.rs index 87bb216c..2e721c6e 100644 --- a/lib/sparesults/src/lib.rs +++ b/lib/sparesults/src/lib.rs @@ -96,7 +96,7 @@ impl QueryResultsFormat { /// Looks for a known format from a media type. /// /// It supports some media type aliases. - /// For example "application/xml" is going to return `Xml` even if it is not its canonical media type. + /// For example, "application/xml" is going to return `Xml` even if it is not its canonical media type. /// /// Example: /// ``` diff --git a/lib/spargebra/README.md b/lib/spargebra/README.md index 56677fcc..b2783605 100644 --- a/lib/spargebra/README.md +++ b/lib/spargebra/README.md @@ -43,4 +43,4 @@ at your option. ### Contribution -Unless you explicitly state otherwise, any contribution intentionally submitted for inclusion in Futures by you, as defined in the Apache-2.0 license, shall be dual licensed as above, without any additional terms or conditions. +Unless you explicitly state otherwise, any contribution intentionally submitted for inclusion in Oxigraph by you, as defined in the Apache-2.0 license, shall be dual licensed as above, without any additional terms or conditions. diff --git a/lib/spargebra/src/term.rs b/lib/spargebra/src/term.rs index 26783810..14af2ada 100644 --- a/lib/spargebra/src/term.rs +++ b/lib/spargebra/src/term.rs @@ -6,7 +6,7 @@ use std::fmt::Write; /// The union of [IRIs](https://www.w3.org/TR/rdf11-concepts/#dfn-iri) and [triples](https://www.w3.org/TR/rdf11-concepts/#dfn-rdf-triple). /// -/// The default string formatter is returning an N-Triples, Turtle and SPARQL compatible representation. +/// The default string formatter is returning an N-Triples, Turtle, and SPARQL compatible representation. #[derive(Eq, PartialEq, Debug, Clone, Hash)] pub enum GroundSubject { NamedNode(NamedNode), @@ -74,7 +74,7 @@ impl TryFrom for GroundSubject { /// The union of [IRIs](https://www.w3.org/TR/rdf11-concepts/#dfn-iri), [literals](https://www.w3.org/TR/rdf11-concepts/#dfn-literal) and [triples](https://www.w3.org/TR/rdf11-concepts/#dfn-rdf-triple). /// -/// The default string formatter is returning an N-Triples, Turtle and SPARQL compatible representation. +/// The default string formatter is returning an N-Triples, Turtle, and SPARQL compatible representation. #[derive(Eq, PartialEq, Debug, Clone, Hash)] pub enum GroundTerm { NamedNode(NamedNode), @@ -229,7 +229,7 @@ impl TryFrom for GraphName { } } -/// A [RDF triple](https://www.w3.org/TR/rdf11-concepts/#dfn-rdf-triple) in a [RDF dataset](https://www.w3.org/TR/rdf11-concepts/#dfn-rdf-dataset). +/// A [RDF triple](https://www.w3.org/TR/rdf11-concepts/#dfn-rdf-triple) in an [RDF dataset](https://www.w3.org/TR/rdf11-concepts/#dfn-rdf-dataset). /// /// The default string formatter is returning a N-Quads representation. /// @@ -304,7 +304,7 @@ impl TryFrom for Quad { } } -/// A [RDF triple](https://www.w3.org/TR/rdf11-concepts/#dfn-rdf-triple) in a [RDF dataset](https://www.w3.org/TR/rdf11-concepts/#dfn-rdf-dataset) without blank nodes. +/// A [RDF triple](https://www.w3.org/TR/rdf11-concepts/#dfn-rdf-triple) in an [RDF dataset](https://www.w3.org/TR/rdf11-concepts/#dfn-rdf-dataset) without blank nodes. /// /// The default string formatter is returning a N-Quads representation. /// diff --git a/lib/src/io/format.rs b/lib/src/io/format.rs index b833f4d2..af274815 100644 --- a/lib/src/io/format.rs +++ b/lib/src/io/format.rs @@ -63,7 +63,7 @@ impl GraphFormat { /// Looks for a known format from a media type. /// /// It supports some media type aliases. - /// For example "application/xml" is going to return `GraphFormat::RdfXml` even if it is not its canonical media type. + /// For example, "application/xml" is going to return `GraphFormat::RdfXml` even if it is not its canonical media type. /// /// Example: /// ``` diff --git a/lib/src/storage/backend/rocksdb.rs b/lib/src/storage/backend/rocksdb.rs index 55c58c85..0b6ca298 100644 --- a/lib/src/storage/backend/rocksdb.rs +++ b/lib/src/storage/backend/rocksdb.rs @@ -428,7 +428,7 @@ impl Db { || e.0.code == rocksdb_status_code_t_rocksdb_status_code_try_again }); if is_conflict_error { - // We give a chance to the OS to do something else before retrying in order to help avoiding an other conflict + // We give a chance to the OS to do something else before retrying in order to help avoiding another conflict yield_now(); } else { // We raise the error diff --git a/lib/src/store.rs b/lib/src/store.rs index 48a59f47..c15d2c65 100644 --- a/lib/src/store.rs +++ b/lib/src/store.rs @@ -49,7 +49,7 @@ use std::{fmt, str}; /// Allows to query and update it using SPARQL. /// It is based on the [RocksDB](https://rocksdb.org/) key-value store. /// -/// This store ensure the "repeatable read" isolation level: the store only exposes changes that have +/// This store ensures the "repeatable read" isolation level: the store only exposes changes that have /// been "committed" (i.e. no partial writes) and the exposed state does not change for the complete duration /// of a read operation (e.g. a SPARQL query) or a read/write operation (e.g. a SPARQL update). /// @@ -281,7 +281,7 @@ impl Store { /// Executes a transaction. /// - /// Transaction ensures the "repeatable read" isolation level: the store only exposes changes that have + /// Transactions ensure the "repeatable read" isolation level: the store only exposes changes that have /// been "committed" (i.e. no partial writes) and the exposed state does not change for the complete duration /// of a read operation (e.g. a SPARQL query) or a read/write operation (e.g. a SPARQL update). /// @@ -724,7 +724,7 @@ impl Store { /// Optimizes the database for future workload. /// - /// Useful to call after a batch upload or an other similar operation. + /// Useful to call after a batch upload or another similar operation. /// /// Warning: Can take hours on huge databases. #[cfg(not(target_arch = "wasm32"))] @@ -747,7 +747,7 @@ impl Store { /// but hard links will be used to point to the original database immutable snapshots. /// This allows cheap regular backups. /// - /// If you want to move your data to an other RDF storage system, you should have a look at the [`Store::dump_dataset`] function instead. + /// If you want to move your data to another RDF storage system, you should have a look at the [`Store::dump_dataset`] function instead. #[cfg(not(target_arch = "wasm32"))] pub fn backup(&self, target_directory: impl AsRef) -> Result<(), StorageError> { self.storage.backup(target_directory.as_ref()) diff --git a/python/README.md b/python/README.md index bfdc9f04..5d7e9bee 100644 --- a/python/README.md +++ b/python/README.md @@ -57,4 +57,4 @@ at your option. ### Contribution -Unless you explicitly state otherwise, any contribution intentionally submitted for inclusion in Futures by you, as defined in the Apache-2.0 license, shall be dual licensed as above, without any additional terms or conditions. +Unless you explicitly state otherwise, any contribution intentionally submitted for inclusion in Oxigraph by you, as defined in the Apache-2.0 license, shall be dual licensed as above, without any additional terms or conditions. diff --git a/python/docs/index.rst b/python/docs/index.rst index 3b29138c..9deda9e6 100644 --- a/python/docs/index.rst +++ b/python/docs/index.rst @@ -16,7 +16,7 @@ Pyoxigraph is a Python graph database library implementing the `SPARQL `_ using `PyO3 `_. -It also provides a set of utility functions for reading, writing and processing RDF files in +It also provides a set of utility functions for reading, writing, and processing RDF files in `Turtle `_, `TriG `_, `N-Triples `_, @@ -25,7 +25,7 @@ It also provides a set of utility functions for reading, writing and processing Pyoxigraph is `distributed on Pypi `_. -There is also a small library providing an `rdflib `_ store using pyoxigraph: `oxrdflib `_. +There is also a small library providing a `rdflib `_ store using pyoxigraph: `oxrdflib `_. Oxigraph and pyoxigraph source code are on `GitHub `_. diff --git a/python/src/io.rs b/python/src/io.rs index e0bda5cd..9f1504e4 100644 --- a/python/src/io.rs +++ b/python/src/io.rs @@ -27,7 +27,7 @@ pub fn add_to_module(module: &PyModule) -> PyResult<()> { /// * `RDF/XML `_ (``application/rdf+xml``) /// /// It supports also some MIME type aliases. -/// For example ``application/turtle`` could also be used for `Turtle `_ +/// For example, ``application/turtle`` could also be used for `Turtle `_ /// and ``application/xml`` for `RDF/XML `_. /// /// :param input: The binary I/O object to read from. For example, it could be a file opened in binary mode with ``open('my_file.ttl', 'rb')``. @@ -94,7 +94,7 @@ pub fn parse( /// * `RDF/XML `_ (``application/rdf+xml``) /// /// It supports also some MIME type aliases. -/// For example ``application/turtle`` could also be used for `Turtle `_ +/// For example, ``application/turtle`` could also be used for `Turtle `_ /// and ``application/xml`` for `RDF/XML `_. /// /// :param input: the RDF triples and quads to serialize. diff --git a/python/src/model.rs b/python/src/model.rs index 26ae958f..5bc38d10 100644 --- a/python/src/model.rs +++ b/python/src/model.rs @@ -15,7 +15,7 @@ use std::vec::IntoIter; /// :type value: str /// :raises ValueError: if the IRI is not valid according to `RFC 3987 `_. /// -/// The :py:func:`str` function provides a serialization compatible with NTriples, Turtle and SPARQL: +/// The :py:func:`str` function provides a serialization compatible with NTriples, Turtle, and SPARQL: /// /// >>> str(NamedNode('http://example.com')) /// '' @@ -115,9 +115,9 @@ impl PyNamedNode { /// /// :param value: the `blank node ID `_ (if not present, a random blank node ID is automatically generated). /// :type value: str, optional -/// :raises ValueError: if the blank node ID is invalid according to NTriples, Turtle and SPARQL grammars. +/// :raises ValueError: if the blank node ID is invalid according to NTriples, Turtle, and SPARQL grammars. /// -/// The :py:func:`str` function provides a serialization compatible with NTriples, Turtle and SPARQL: +/// The :py:func:`str` function provides a serialization compatible with NTriples, Turtle, and SPARQL: /// /// >>> str(BlankNode('ex')) /// '_:ex' @@ -226,7 +226,7 @@ impl PyBlankNode { /// :type language: str, optional /// :raises ValueError: if the language tag is not valid according to `RFC 5646 `_ (`BCP 47 `_). /// -/// The :py:func:`str` function provides a serialization compatible with NTriples, Turtle and SPARQL: +/// The :py:func:`str` function provides a serialization compatible with NTriples, Turtle, and SPARQL: /// /// >>> str(Literal('example')) /// '"example"' @@ -523,7 +523,7 @@ impl IntoPy for PyTerm { /// :param object: the triple object. /// :type object: NamedNode or BlankNode or Literal or Triple /// -/// The :py:func:`str` function provides a serialization compatible with NTriples, Turtle and SPARQL: +/// The :py:func:`str` function provides a serialization compatible with NTriples, Turtle, and SPARQL: /// /// >>> str(Triple(NamedNode('http://example.com'), NamedNode('http://example.com/p'), Literal('1'))) /// ' "1"' @@ -697,7 +697,7 @@ impl IntoPy for PyGraphName { /// :param graph: the quad graph name. If not present, the default graph is assumed. /// :type graph: NamedNode or BlankNode or DefaultGraph or None, optional /// -/// The :py:func:`str` function provides a serialization compatible with NTriples, Turtle and SPARQL: +/// The :py:func:`str` function provides a serialization compatible with NTriples, Turtle, and SPARQL: /// /// >>> str(Quad(NamedNode('http://example.com'), NamedNode('http://example.com/p'), Literal('1'), NamedNode('http://example.com/g'))) /// ' "1" ' diff --git a/python/src/store.rs b/python/src/store.rs index b7a4b950..e95a3c6c 100644 --- a/python/src/store.rs +++ b/python/src/store.rs @@ -17,13 +17,13 @@ use std::io::BufReader; /// It encodes a `RDF dataset `_ and allows to query it using SPARQL. /// It is based on the `RocksDB `_ key-value database. /// -/// This store ensure the "repeatable read" isolation level: the store only exposes changes that have +/// This store ensures the "repeatable read" isolation level: the store only exposes changes that have /// been "committed" (i.e. no partial writes) and the exposed state does not change for the complete duration /// of a read operation (e.g. a SPARQL query) or a read/write operation (e.g. a SPARQL update). /// /// :param path: the path of the directory in which the store should read and write its data. If the directory does not exist, it is created. /// If no directory is provided a temporary one is created and removed when the Python garbage collector removes the store. -/// In this case the store data are kept in memory and never written on disk. +/// In this case, the store data are kept in memory and never written on disk. /// :type path: str or None, optional. /// :raises IOError: if the target directory contains invalid data or could not be accessed. /// @@ -250,7 +250,7 @@ impl PyStore { /// * `RDF/XML `_ (``application/rdf+xml``) /// /// It supports also some MIME type aliases. - /// For example ``application/turtle`` could also be used for `Turtle `_ + /// For example, ``application/turtle`` could also be used for `Turtle `_ /// and ``application/xml`` for `RDF/XML `_. /// /// :param input: The binary I/O object to read from. For example, it could be a file opened in binary mode with ``open('my_file.ttl', 'rb')``. @@ -259,7 +259,7 @@ impl PyStore { /// :type mime_type: str /// :param base_iri: the base IRI used to resolve the relative IRIs in the file or :py:const:`None` if relative IRI resolution should not be done. /// :type base_iri: str or None, optional - /// :param to_graph: if it is a file composed of triples, the graph in which store the triples. By default, the default graph is used. + /// :param to_graph: if it is a file composed of triples, the graph in which the triples should be stored. By default, the default graph is used. /// :type to_graph: NamedNode or BlankNode or DefaultGraph or None, optional /// :raises ValueError: if the MIME type is not supported or the `to_graph` parameter is given with a quad file. /// :raises SyntaxError: if the provided data is invalid. @@ -326,7 +326,7 @@ impl PyStore { /// * `RDF/XML `_ (``application/rdf+xml``) /// /// It supports also some MIME type aliases. - /// For example ``application/turtle`` could also be used for `Turtle `_ + /// For example, ``application/turtle`` could also be used for `Turtle `_ /// and ``application/xml`` for `RDF/XML `_. /// /// :param input: The binary I/O object to read from. For example, it could be a file opened in binary mode with ``open('my_file.ttl', 'rb')``. @@ -335,7 +335,7 @@ impl PyStore { /// :type mime_type: str /// :param base_iri: the base IRI used to resolve the relative IRIs in the file or :py:const:`None` if relative IRI resolution should not be done. /// :type base_iri: str or None, optional - /// :param to_graph: if it is a file composed of triples, the graph in which store the triples. By default, the default graph is used. + /// :param to_graph: if it is a file composed of triples, the graph in which the triples should be stored. By default, the default graph is used. /// :type to_graph: NamedNode or BlankNode or DefaultGraph or None, optional /// :raises ValueError: if the MIME type is not supported or the `to_graph` parameter is given with a quad file. /// :raises SyntaxError: if the provided data is invalid. @@ -397,7 +397,7 @@ impl PyStore { /// * `RDF/XML `_ (``application/rdf+xml``) /// /// It supports also some MIME type aliases. - /// For example ``application/turtle`` could also be used for `Turtle `_ + /// For example, ``application/turtle`` could also be used for `Turtle `_ /// and ``application/xml`` for `RDF/XML `_. /// /// :param output: The binary I/O object to write to. For example, it could be a file opened in binary mode with ``open('my_file.ttl', 'wb')``. @@ -494,7 +494,7 @@ impl PyStore { /// Removes a graph from the store. /// - /// The default graph will not be remove but just cleared. + /// The default graph will not be removed but just cleared. /// /// :param graph_name: the name of the name graph to remove. /// :type graph_name: NamedNode or BlankNode or DefaultGraph @@ -537,9 +537,9 @@ impl PyStore { /// but hard links will be used to point to the original database immutable snapshots. /// This allows cheap regular backups. /// - /// If you want to move your data to an other RDF storage system, you should have a look at the :py:func:`dump_dataset` function instead. + /// If you want to move your data to another RDF storage system, you should have a look at the :py:func:`dump_dataset` function instead. /// - /// :param target_directory: the name of directory to save the database to. + /// :param target_directory: the directory name to save the database to. /// :type target_directory: str /// :raises IOError: if an I/O error happens during the backup. #[pyo3(text_signature = "($self, target_directory)")] diff --git a/server/README.md b/server/README.md index d9a782dc..8ff971bd 100644 --- a/server/README.md +++ b/server/README.md @@ -44,12 +44,12 @@ It will create a fat binary in `target/release/oxigraph_server`. ## Usage -Run `oxigraph_server --location my_data_storage_directory serve` to start the server where `my_data_storage_directory` is the directory where you want Oxigraph data to be stored in. It listens by default on `localhost:7878`. +Run `oxigraph_server --location my_data_storage_directory serve` to start the server where `my_data_storage_directory` is the directory where you want Oxigraph data to be stored. It listens by default on `localhost:7878`. The server provides an HTML UI, based on [YASGUI](https://yasgui.triply.cc), with a form to execute SPARQL requests. It provides the following REST actions: -* `/query` allows to evaluate SPARQL queries against the server repository following the [SPARQL 1.1 Protocol](https://www.w3.org/TR/sparql11-protocol/#query-operation). +* `/query` allows evaluating SPARQL queries against the server repository following the [SPARQL 1.1 Protocol](https://www.w3.org/TR/sparql11-protocol/#query-operation). For example: ```bash curl -X POST -H 'Content-Type:application/sparql-query' \ @@ -57,7 +57,7 @@ It provides the following REST actions: ``` This action supports content negotiation and could return [Turtle](https://www.w3.org/TR/turtle/), [N-Triples](https://www.w3.org/TR/n-triples/), [RDF XML](https://www.w3.org/TR/rdf-syntax-grammar/), [SPARQL Query Results XML Format](http://www.w3.org/TR/rdf-sparql-XMLres/) and [SPARQL Query Results JSON Format](https://www.w3.org/TR/sparql11-results-json/). * `/update` allows to execute SPARQL updates against the server repository following the [SPARQL 1.1 Protocol](https://www.w3.org/TR/sparql11-protocol/#update-operation). - For example: + For example: ```sh curl -X POST -H 'Content-Type: application/sparql-update' \ --data 'DELETE WHERE { ?p ?o }' http://localhost:7878/update @@ -90,7 +90,7 @@ It is also possible to load RDF data offline using bulk loading: docker run --rm oxigraph/oxigraph --help ``` -### Run the Web server +### Run the Webserver Expose the server on port `7878` of the host machine, and save data on the local `./data` folder ```sh docker run --rm -v $PWD/data:/data -p 7878:7878 oxigraph/oxigraph --location /data serve --bind 0.0.0.0:7878 @@ -223,7 +223,7 @@ It installs the `oxigraph_server` binary. [See the usage documentation to know h ## Migration guide ### From 0.2 to 0.3 -* The cli API have been completely rewritten. To start the server run `oxigraph_server serve --location MY_STORAGE` instead of `oxigraph_server --file MY_STORAGE`. +* The cli API has been completely rewritten. To start the server run `oxigraph_server serve --location MY_STORAGE` instead of `oxigraph_server --file MY_STORAGE`. * Fast data bulk loading is not supported using `oxigraph_server load --location MY_STORAGE --file MY_FILE`. The file format is guessed from the extension (`.nt`, `.ttl`, `.nq`...). * [RDF-star](https://w3c.github.io/rdf-star/cg-spec) is now implemented. * All operations are now transactional using the "repeatable read" isolation level: @@ -245,4 +245,4 @@ at your option. ### Contribution -Unless you explicitly state otherwise, any contribution intentionally submitted for inclusion in Futures by you, as defined in the Apache-2.0 license, shall be dual licensed as above, without any additional terms or conditions. +Unless you explicitly state otherwise, any contribution intentionally submitted for inclusion in Oxigraph by you, as defined in the Apache-2.0 license, shall be dual licensed as above, without any additional terms or conditions.