Author: andy
Date: Wed Sep 25 20:09:32 2019
New Revision: 1867548

URL: http://svn.apache.org/viewvc?rev=1867548&view=rev
Log:
Jena 3.13.0: Further updates

Added:
    jena/site/trunk/content/documentation/shacl/
    jena/site/trunk/content/documentation/shacl/index.md
Modified:
    jena/site/trunk/content/documentation/fuseki2/data-access-control.md
    jena/site/trunk/content/documentation/fuseki2/fuseki-configuration.md
    jena/site/trunk/content/documentation/index.mdtext
    jena/site/trunk/content/download/index.mdtext

Modified: jena/site/trunk/content/documentation/fuseki2/data-access-control.md
URL: 
http://svn.apache.org/viewvc/jena/site/trunk/content/documentation/fuseki2/data-access-control.md?rev=1867548&r1=1867547&r2=1867548&view=diff
==============================================================================
--- jena/site/trunk/content/documentation/fuseki2/data-access-control.md 
(original)
+++ jena/site/trunk/content/documentation/fuseki2/data-access-control.md Wed 
Sep 25 20:09:32 2019
@@ -221,9 +221,9 @@ An access control list can be applied to
 Again, any  other "allowedUsers" configuration, service-wide, or
 server-wide) also applies.
 
-        fuseki:serviceQuery  [ fuseki:name "query ;
+        fuseki:serviceQuery  [ fuseki:name "query" ;
                                fuseki:allowedUsers "user1", "user2"] ;
-        fuseki:serviceUpdate [ fuseki:name "update ;
+        fuseki:serviceUpdate [ fuseki:name "update" ;
                                fuseki:allowedUsers "user1"] ;
 
 Only <em>user1</em> can use SPARQL update; both <em>user1</em> and

Modified: jena/site/trunk/content/documentation/fuseki2/fuseki-configuration.md
URL: 
http://svn.apache.org/viewvc/jena/site/trunk/content/documentation/fuseki2/fuseki-configuration.md?rev=1867548&r1=1867547&r2=1867548&view=diff
==============================================================================
--- jena/site/trunk/content/documentation/fuseki2/fuseki-configuration.md 
(original)
+++ jena/site/trunk/content/documentation/fuseki2/fuseki-configuration.md Wed 
Sep 25 20:09:32 2019
@@ -40,7 +40,7 @@ Some useful prefix declarations:
     @prefix rdfs:    <http://www.w3.org/2000/01/rdf-schema#> .
     @prefix tdb:     <http://jena.hpl.hp.com/2008/tdb#> .
     @prefix ja:      <http://jena.hpl.hp.com/2005/11/Assembler#> .
-    @prefix :        <#> .
+    @prefix :        <#> .
 
 ### Assembler Initialization
 
@@ -64,16 +64,16 @@ The base name is `/ds`.
 
     ## Updateable in-memory dataset.
 
-    <#service1> rdf:type fuseki:Service ;
-        fuseki:name                       "ds" ;       # http://host:port/ds
-        fuseki:serviceQuery               "sparql" ;   # SPARQL query service
-        fuseki:serviceQuery               "query" ;    # SPARQL query service 
(alt name)
-        fuseki:serviceUpdate              "update" ;   # SPARQL update service
-        fuseki:serviceUpload              "upload" ;   # Non-SPARQL upload 
service
-        fuseki:serviceReadWriteGraphStore "data" ;     # SPARQL Graph store 
protocol (read and write)
+    <#service1> rdf:type fuseki:Service ;
+        fuseki:name                       "ds" ;       # http://host:port/ds
+        fuseki:serviceQuery               "sparql" ;   # SPARQL query service
+        fuseki:serviceQuery               "query" ;    # SPARQL query service 
(alt name)
+        fuseki:serviceUpdate              "update" ;   # SPARQL update service
+        fuseki:serviceUpload              "upload" ;   # Non-SPARQL upload 
service
+        fuseki:serviceReadWriteGraphStore "data" ;     # SPARQL Graph store 
protocol (read and write)
         # A separate read-only graph store endpoint:
-        fuseki:serviceReadGraphStore      "get" ;      # SPARQL Graph store 
protocol (read only)
-        fuseki:dataset                   <#dataset> ;
+        fuseki:serviceReadGraphStore      "get" ;      # SPARQL Graph store 
protocol (read only)
+        fuseki:dataset                   <#dataset> ;
         .
 
 `<#dataset>` refers to a dataset description in the same file.
@@ -86,11 +86,11 @@ SPARQl Graph Store protocol).
 This service offers read-only access to a dataset with a single
 graph of data.
 
-    <#service2> rdf:type fuseki:Service ;
-        fuseki:name                     "/ds-ro" ;   # http://host:port/ds-ro
-        fuseki:serviceQuery             "query" ;    # SPARQL query service
-        fuseki:serviceReadGraphStore    "data" ;     # SPARQL Graph store 
protocol (read only)
-        fuseki:dataset           <#dataset> ;
+    <#service2> rdf:type fuseki:Service ;
+        fuseki:name                     "/ds-ro" ;   # http://host:port/ds-ro
+        fuseki:serviceQuery             "query" ;    # SPARQL query service
+        fuseki:serviceReadGraphStore    "data" ;     # SPARQL Graph store 
protocol (read only)
+        fuseki:dataset           <#dataset> ;
         .
 
 ### Dataset
@@ -99,23 +99,23 @@ graph of data.
 
 An in-memory dataset, with data in the default graph taken from a local file.
 
-    <#books>    rdf:type ja:RDFDataset ;
-        rdfs:label "Books" ;
+    <#books>    rdf:type ja:RDFDataset ;
+        rdfs:label "Books" ;
         ja:defaultGraph
-          [ rdfs:label "books.ttl" ;
-            a ja:MemoryModel ;
-            ja:content [ja:externalContent <file:Data/books.ttl> ] ;
-          ] ;
+          [ rdfs:label "books.ttl" ;
+            a ja:MemoryModel ;
+            ja:content [ja:externalContent <file:Data/books.ttl> ] ;
+          ] ;
         .
 
 #### TDB
 
-    <#dataset> rdf:type      tdb:DatasetTDB ;
-        tdb:location "DB" ;
+    <#dataset> rdf:type      tdb:DatasetTDB ;
+        tdb:location "DB" ;
         # Query timeout on this dataset (1s, 1000 milliseconds)
-        ja:context [ ja:cxtName "arq:queryTimeout" ;  ja:cxtValue "1000" ] ;
+        ja:context [ ja:cxtName "arq:queryTimeout" ;  ja:cxtValue "1000" ] ;
         # Make the default graph be the union of all named graphs.
-        ## tdb:unionDefaultGraph true ;
+        ## tdb:unionDefaultGraph true ;
          .
 
 #### Inference
@@ -133,16 +133,16 @@ web application and the additional class
 
 ### Server Section
 
-    [] rdf:type fuseki:Server ;
+    [] rdf:type fuseki:Server ;
        # Server-wide context parameters can be given here.
        # For example, to set query timeouts: on a server-wide basis:
        # Format 1: "1000" -- 1 second timeout
        # Format 2: "10000,60000" -- 10s timeout to first result, then 60s 
timeout to for rest of query.
        # See java doc for ARQ.queryTimeout
-       # ja:context [ ja:cxtName "arq:queryTimeout" ;  ja:cxtValue "10000" ] 
;
+       # ja:context [ ja:cxtName "arq:queryTimeout" ;  ja:cxtValue "10000" ] ;
 
        # Load custom code (rarely needed)
-       # ja:loadClass "your.code.Class" ;
+       # ja:loadClass "your.code.Class" ;
        .
 
 ## Compatibility with Fuseki 1 configuration

Modified: jena/site/trunk/content/documentation/index.mdtext
URL: 
http://svn.apache.org/viewvc/jena/site/trunk/content/documentation/index.mdtext?rev=1867548&r1=1867547&r2=1867548&view=diff
==============================================================================
--- jena/site/trunk/content/documentation/index.mdtext (original)
+++ jena/site/trunk/content/documentation/index.mdtext Wed Sep 25 20:09:32 2019
@@ -10,20 +10,19 @@ sections.
 * [SPARQL](./query/) - querying and updating RDF models using the SPARQL 
standards
 * [Fuseki](./fuseki2/) - SPARQL server which can present RDF data and answer 
SPARQL queries over HTTP
 * [I/O](./io/) - reading and writing RDF data
-* [Elephas](./hadoop) - working with RDF data on Apache Hadoop.
 * [Assembler](./assembler/) - describing recipes for constructing Jena models 
declaratively using RDF
 * [Inference](./inference/) - using the Jena rules engine and other inference 
algorithms to derive consequences from RDF models
 * [Ontology](./ontology/) - support for handling OWL models in Jena
 * [TDB](./tdb/) - a fast persistent triple store that stores directly to disk
 * [TDB2](./tdb2) - next generation TDB
 * [RDF Connection](./rdfconnection/) - a SPARQL API for local datasets and 
remote services
+* [SHACL](./shacl) - SHACL processor for Jena
 * [Javadoc](./javadoc/) - JavaDoc generated from the Jena source
 * [Text Search](./query/text-query.html) - enhanced indexes using Lucene or 
Solr for more efficient searching of text literals in Jena models and datasets.
 * [GeoSPARQL](./geosparql/) - support for GeoSPARQL
+* [Elephas](./hadoop) - working with RDF data on Apache Hadoop.
 * [How-To's](./notes/) - various topic-specific how-to documents
 * [Permissions](./permissions/) - a permissions wrapper around Jena RDF 
implementation
 * [JDBC](./jdbc/) - a SPARQL over JDBC driver framework
 * [Tools](./tools/) - various command-line tools and utilities to help 
developers manage RDF data and other aspects of Jena
 * [Extras](./extras/) - various modules that provide utilities and larger 
packages that make Apache Jena development or usage easier but that do not fall 
within the standard Jena framework.
-
-

Added: jena/site/trunk/content/documentation/shacl/index.md
URL: 
http://svn.apache.org/viewvc/jena/site/trunk/content/documentation/shacl/index.md?rev=1867548&view=auto
==============================================================================
--- jena/site/trunk/content/documentation/shacl/index.md (added)
+++ jena/site/trunk/content/documentation/shacl/index.md Wed Sep 25 20:09:32 
2019
@@ -0,0 +1,102 @@
+Title: Apache Jena Shacl
+
+jena-shacl is an implementation of the 
+W3C [Shapes Constraint Language (SHACL)](https://www.w3.org/TR/shacl/).
+It implements SHACL Core and SHACL SPARQL Constraints.
+
+## Command line
+
+The command `shacl` introduces shacl operations; it takes a sub-command
+argument. 
+
+To validate:
+
+<pre>shacl validate --shapes <i>SHAPES.ttl</i> --data <i>DATA.ttl</i></pre>
+<pre>shacl v -s <i>SHAPES.ttl</i> -d <i>DATA.ttl</i></pre>
+
+The shapes and data files can be the same; the `--shapes` is optional and
+default to the same as `--data`.  This includes running individual W3C Working
+Group tests.
+
+To parse a file
+
+<pre>shacl parse <i>FILE</i></pre>
+<pre>shacl p <i>FILE</i></pre>
+
+which writes out a text format.
+
+## Integration with Apache Jena Fuseki
+
+Fuseki has a new service operation `fuseki:serviceShacl`:
+
+<pre>
+&lt;#serviceInMemoryShacl&gt; rdf:type fuseki:Service ;
+    rdfs:label                   "Dataset with SHACL validation" ;
+    fuseki:name                  "<i>ds</i>" ;
+    fuseki:serviceReadWriteGraphStore "" ;
+    fuseki:endpoint [ fuseki:operation fuseki:shacl ; fuseki:name "shacl" ] ;
+    fuseki:dataset &lt;#dataset&gt; ;
+    .
+</pre>
+
+This requires a "new style" endpoint declaration:  see
+"[Fuseki Endpoint Configuration](/documentation//fuseki2/fuseki-config-doc)".
+
+This is not installed into a dataset setup by default; a configuration file 
using
+`fuseki:serviceShacl` is necessary (or programmatic setup for Fuskei Main).
+
+The service accepts a shapes graph posted as RDF to <tt>/<i>ds</i>/shacl</tt> 
with
+content negotiation.
+
+There is an graph argument, `?graph=`, that specifies the graph to validate. It
+is the URI of a named graph, `default` for the unnamed, default graph (and
+this is the assumed value of `?graph` if not present), or `union` for union of
+all named graphs in the dataset.
+
+Upload data in file `fu-data.ttl`:
+
+    curl -XPOST --data-binary @fu-data.ttl    \  
+         --header 'Content-type: text/turtle' \  
+         'http://localhost:3030/ds?default'
+
+Validate with shapes in `fu-shapes.ttl` and get back a validation report:
+
+    curl -XPOST --data-binary @fu-shapes.ttl  \  
+         --header 'Content-type: text/turtle' \  
+         'http://localhost:3030/ds/shacl?graph-default'
+
+## API
+
+The package `org.apache.jena.shacl` has the main classes.
+
+* `ShaclValidator` for parsing and validation
+* `GraphValidation` for updating graphs with validation
+
+## API Examples
+
+https://github.com/apache/jena/tree/master/jena-shacl/src/main/java/org/apache/jena/shacl/examples
+
+Example
+[`Shacl01_validateGraph`](
+https://github.com/apache/jena/tree/master/jena-shacl/src/main/java/org/apache/jena/shacl/examples/Shacl01_validateGraph.java)
+shows validation and printing of the validation report in a text form and in 
RDF:
+
+    public static void main(String ...args) {
+        String SHAPES = "shapes.ttl";
+        String DATA = "data1.ttl";
+
+        Graph shapesGraph = RDFDataMgr.loadGraph(SHAPES);
+        Graph dataGraph = RDFDataMgr.loadGraph(DATA);
+
+        Shapes shapes = Shapes.parse(shapesGraph);
+
+        ValidationReport report = ShaclValidator.get().validate(shapes, 
dataGraph);
+        ShLib.printReport(report);
+        System.out.println();
+        RDFDataMgr.write(System.out, report.getModel(), Lang.TTL);
+    }
+
+Example
+[`Shacl02_validateTransaction`](https://github.com/apache/jena/tree/master/jena-shacl/src/main/java/org/apache/jena/shacl/examples/Shacl02_validateTransaction.java)
+shows how to update a graph only if, after the changes, the graph is validate
+according to the shapes provided.

Modified: jena/site/trunk/content/download/index.mdtext
URL: 
http://svn.apache.org/viewvc/jena/site/trunk/content/download/index.mdtext?rev=1867548&r1=1867547&r2=1867548&view=diff
==============================================================================
--- jena/site/trunk/content/download/index.mdtext (original)
+++ jena/site/trunk/content/download/index.mdtext Wed Sep 25 20:09:32 2019
@@ -5,7 +5,7 @@ Jena is packaged as downloads which cont
 - **apache-jena** &ndash; contains the APIs, SPARQL engine, the TDB native RDF 
database and command line tools
 - **apache-jena-fuseki** &ndash; the Jena SPARQL server
 
-Jena requires Java8 (from Jena version 3.0.0 onwards).
+Jena requires Java8.
 
 ## Download Mirrors
 
@@ -41,32 +41,32 @@ This distribution contains the APIs, SPA
 
 The binary distribution may be downloaded at:
 
-<a 
href="[preferred]jena/binaries/apache-jena-3.12.0.tar.gz">apache-jena-3.12.0.tar.gz</a>
-(<a 
href="https://www.apache.org/dist/jena/binaries/apache-jena-3.12.0.tar.gz.sha512";>SHA512</a>,
 
-<a 
href="https://www.apache.org/dist/jena/binaries/apache-jena-3.12.0.tar.gz.asc";>PGP</a>)
-
-<a 
href="[preferred]jena/binaries/apache-jena-3.12.0.zip">apache-jena-3.12.0.zip</a>
-(<a 
href="https://www.apache.org/dist/jena/binaries/apache-jena-3.12.0.zip.sha512";>SHA512</a>,
-<a 
href="https://www.apache.org/dist/jena/binaries/apache-jena-3.12.0.zip.asc";>PGP</a>)
+<a 
href="[preferred]jena/binaries/apache-jena-3.13.0.tar.gz">apache-jena-3.13.0.tar.gz</a>
+(<a 
href="https://www.apache.org/dist/jena/binaries/apache-jena-3.13.0.tar.gz.sha512";>SHA512</a>,
 
+<a 
href="https://www.apache.org/dist/jena/binaries/apache-jena-3.13.0.tar.gz.asc";>PGP</a>)
+
+<a 
href="[preferred]jena/binaries/apache-jena-3.13.0.zip">apache-jena-3.13.0.zip</a>
+(<a 
href="https://www.apache.org/dist/jena/binaries/apache-jena-3.13.0.zip.sha512";>SHA512</a>,
+<a 
href="https://www.apache.org/dist/jena/binaries/apache-jena-3.13.0.zip.asc";>PGP</a>)
 
 The source distribution, which includes the source for Fuseki and all modules 
in the release, may be downloaded at:
 
-<a 
href="[preferred]jena/source/jena-3.12.0-source-release.zip">jena-3.12.0-source-release.zip</a>
-(<a 
href="https://www.apache.org/dist/jena/source/jena-3.12.0-source-release.zip.sha512";>SHA512</a>,
-<a 
href="https://www.apache.org/dist/jena/source/jena-3.12.0-source-release.zip.asc";>PGP</a>)
+<a 
href="[preferred]jena/source/jena-3.13.0-source-release.zip">jena-3.13.0-source-release.zip</a>
+(<a 
href="https://www.apache.org/dist/jena/source/jena-3.13.0-source-release.zip.sha512";>SHA512</a>,
+<a 
href="https://www.apache.org/dist/jena/source/jena-3.13.0-source-release.zip.asc";>PGP</a>)
 
 ### Apache Jena Fuseki
 
 The binary distribution of Fuseki2 (this includes both the standalone and
 WAR file packaging) may be downloaded at:
 
-<a 
href="[preferred]jena/binaries/apache-jena-fuseki-3.12.0.tar.gz">apache-jena-fuseki-3.12.0.tar.gz</a>
-(<a 
href="https://www.apache.org/dist/jena/binaries/apache-jena-fuseki-3.12.0.tar.gz.sha512";>SHA512</a>,
-<a 
href="https://www.apache.org/dist/jena/binaries/apache-jena-fuseki-3.12.0.tar.gz.asc";>PGP</a>)
-
-<a 
href="[preferred]jena/binaries/apache-jena-fuseki-3.12.0.zip">apache-jena-fuseki-3.12.0.zip</a>
-(<a 
href="https://www.apache.org/dist/jena/binaries/apache-jena-fuseki-3.12.0.zip.sha512";>SHA512</a>,
-<a 
href="https://www.apache.org/dist/jena/binaries/apache-jena-fuseki-3.12.0.zip.asc";>PGP</a>)
+<a 
href="[preferred]jena/binaries/apache-jena-fuseki-3.13.0.tar.gz">apache-jena-fuseki-3.13.0.tar.gz</a>
+(<a 
href="https://www.apache.org/dist/jena/binaries/apache-jena-fuseki-3.13.0.tar.gz.sha512";>SHA512</a>,
+<a 
href="https://www.apache.org/dist/jena/binaries/apache-jena-fuseki-3.13.0.tar.gz.asc";>PGP</a>)
+
+<a 
href="[preferred]jena/binaries/apache-jena-fuseki-3.13.0.zip">apache-jena-fuseki-3.13.0.zip</a>
+(<a 
href="https://www.apache.org/dist/jena/binaries/apache-jena-fuseki-3.13.0.zip.sha512";>SHA512</a>,
+<a 
href="https://www.apache.org/dist/jena/binaries/apache-jena-fuseki-3.13.0.zip.asc";>PGP</a>)
 
 ### Individual Modules
 


Reply via email to