This is an automated email from the ASF dual-hosted git repository. git-site-role pushed a commit to branch asf-staging in repository https://gitbox.apache.org/repos/asf/jena-site.git
The following commit(s) were added to refs/heads/asf-staging by this push: new 9c4498cf4 Staged site from json10-status (2aeb89eab5439ff3055bfdfe2961aa0494ac765e) 9c4498cf4 is described below commit 9c4498cf4dcee9756d142b584fd5b0a548109a2b Author: jenkins <bui...@apache.org> AuthorDate: Tue Aug 15 07:33:04 2023 +0000 Staged site from json10-status (2aeb89eab5439ff3055bfdfe2961aa0494ac765e) --- .../fuseki2/fuseki-data-access-control.html | 8 +- content/documentation/fuseki2/fuseki-modules.html | 171 +++++++++++++++------ content/documentation/index.xml | 6 +- content/documentation/io/rdf-output.html | 30 ++++ .../documentation/query/javascript-functions.html | 29 +++- content/download/index.html | 36 ++--- content/index.json | 2 +- content/index.xml | 6 +- content/sitemap.xml | 18 +-- 9 files changed, 222 insertions(+), 84 deletions(-) diff --git a/content/documentation/fuseki2/fuseki-data-access-control.html b/content/documentation/fuseki2/fuseki-data-access-control.html index 93e56508d..6fbefb6a5 100644 --- a/content/documentation/fuseki2/fuseki-data-access-control.html +++ b/content/documentation/fuseki2/fuseki-data-access-control.html @@ -197,7 +197,7 @@ </li> <li><a href="#acl">Access Control Lists</a> <ul> - <li><a href="#alloweduser">Format of <code>ja:allowedUsers</code></a></li> + <li><a href="#alloweduser">Format of <code>fuseki:allowedUsers</code></a></li> <li><a href="#server-acl">Server Level ACLs</a></li> <li><a href="#dataset-acl">Dataset Level ACLs</a></li> <li><a href="#endpoint-acl">Endpoint Level ACLs</a></li> @@ -401,8 +401,8 @@ lists. Graph-level access control is <a href="#graph-acl">covered below</a>.</p> <pre> fuseki --conf <i>configFile.ttl</i> </pre> -<p>ACLs are provided by the <code>ja:allowedUsers</code> property</p> -<h3 id="alloweduser">Format of <code>ja:allowedUsers</code></h3> +<p>ACLs are provided by the <code>fuseki:allowedUsers</code> property</p> +<h3 id="alloweduser">Format of <code>fuseki:allowedUsers</code></h3> <p>The list of users allowed access can be an RDF list or repeated use of the property or a mixture. The different settings are combined into one ACL.</p> <pre><code> fuseki:allowedUsers "user1", "user2", "user3"; @@ -553,7 +553,7 @@ the deployed server can be run using a Jetty configuration.</p> </li> <li><a href="#acl">Access Control Lists</a> <ul> - <li><a href="#alloweduser">Format of <code>ja:allowedUsers</code></a></li> + <li><a href="#alloweduser">Format of <code>fuseki:allowedUsers</code></a></li> <li><a href="#server-acl">Server Level ACLs</a></li> <li><a href="#dataset-acl">Dataset Level ACLs</a></li> <li><a href="#endpoint-acl">Endpoint Level ACLs</a></li> diff --git a/content/documentation/fuseki2/fuseki-modules.html b/content/documentation/fuseki2/fuseki-modules.html index 505cc5f8e..4b36c3e16 100644 --- a/content/documentation/fuseki2/fuseki-modules.html +++ b/content/documentation/fuseki2/fuseki-modules.html @@ -181,57 +181,104 @@ <aside class="text-muted align-self-start mb-3 p-0 d-xl-none d-block"> <h2 class="h6 sticky-top m-0 p-2 bg-body-tertiary">On this page</h2> - <nav id="TableOfContents"></nav> + <nav id="TableOfContents"> + <ul> + <li> + <ul> + <li><a href="#automatically-loaded">Automatically loaded</a></li> + <li><a href="#programmaticaly-configuring-a-server">Programmaticaly configuring a server</a></li> + <li><a href="#fuseki-module-operations">Fuseki Module operations</a></li> + <li><a href="#fusekimodule-interface"><code>FusekiModule</code> interface</a></li> + </ul> + </li> + </ul> +</nav> </aside> <article class="flex-column me-lg-4"> <p><em>Fuseki modules</em> are a mechanism to include extension code into a Fuseki server. Modules are invoked during the process of building a <a href="./fuseki-main.html">Fuseki -Main</a> server. The module can modify the server +Main</a> server. A module can modify the server configuration, add new functionality, or react to a server being built and started.</p> -<p>This feature was added in Jena version 4.3.0. They are an expeirmental feature -that will evolve based on experineace and use cases.</p> -<p>Fuseki Modules are loaded use the JDK -<a href="https://www.baeldung.com/java-spi">ServiceLoader</a> by being placing a jar file on the classpath, -together with any additional dependencies. The service loader looks for files -<code>META-INF/services/org.apache.jena.fuseki.main.sys.FusekiModule</code> in the jar +<p>This feature was added in Jena version 4.3.0. It is an experimental feature +that will evolve based on feedback and use cases.</p> +<p>The interface for modules is <code>FusekiModule</code>; if automatcally loaded, the +interface is <code>FusekiAutoModule</code> which extends <code>FusekiModule</code>.</p> +<p>Fuseki modules can be provided in two ways:</p> +<ul> +<li>Loaded from additional jars on the classpath</li> +<li>Programmatically controlling the setup of the <code>FusekiServer</code> server.</li> +</ul> +<h3 id="automatically-loaded">Automatically loaded</h3> +<p>Fuseki Modules can be loaded using the JDK +<a href="https://www.baeldung.com/java-spi">ServiceLoader</a> by being placing +a jar file on the classpath, +together with any additional dependencies. These provide interface +<code>FusekiAutoModule</code>. +The service loader is controlled by file resources +<code>META-INF/services/org.apache.jena.fuseki.main.sys.FusekiAutoModule</code> in the jar file. -This is often done by placing the file in the development code in +The module class must have a no-argument constructor.</p> +<p>This is often done by placing the file in the development code in <code>src/main/resources/META-INF/services/</code>). The file containing a line with the implementation full class name. If <a href="../notes/jena-repack.html">repacking</a> Fuseki with the maven-shade-plugin, make -sure the <code>ServicesResourceTransformer</code> is used. The module must have a no -argument constructor.</p> -<p>If using Fuseki as an <a href="./fuseki-embedded.html">embedded server</a>, the module is -added in code as:</p> -<pre tabindex="0"><code> FusekiModule module = new MyModule(); - FusekiModules.add(module); -</code></pre><p>The method <code>start</code> is called when the module is loaded. Custom operations can +sure the <code>ServicesResourceTransformer</code> is used.</p> +<p>The method <code>start</code> is called when the module is loaded. Custom operations can be globally registered at this point (see the <a href="https://github.com/apache/jena/tree/main/jena-fuseki2/jena-fuseki-main/src/test/java/org/apache/jena/fuseki/main/examples">Fuseki examples</a> directory).</p> +<p>A <code>FusekiAutoModule</code> can provide a level, an integer, to control the order in which +modules are invoked during server building. Lower numbers are invoked before larger +numbers at each step.</p> +<h3 id="programmaticaly-configuring-a-server">Programmaticaly configuring a server</h3> +<p>If creating a Fuseki server from Java, the modules can be autoloaded as described above, +or explicitly added to the server builder.</p> +<p>A <code>FusekiModules</code> object is collection of modules, called at each point in the order +given when creating the object.</p> +<pre tabindex="0"><code> FusekiModule myModule = new MyModule(); + FusekiModules fmods = FusekiModules.create(myModule); + FusekiServer server = FusekiServer.create() + ... + .fusekiModules(fmods) + ... + .build(); +</code></pre><h3 id="fuseki-module-operations">Fuseki Module operations</h3> <p>The module lifecycle during creating a Fuseki server is:</p> <ul> -<li><code>configuration</code> - access and modify the setup. -This is called after the server has been configured, just before the server is built.</li> -<li><code>server</code> - access the built server</li> -<li><code>serverBeforeStarting</code> - about to call “server.start()”</li> -<li><code>serverAfterStarting</code> - just after calling “server.start()”</li> -<li><code>serverStopped</code> - called as the server stop +<li><code>prepare</code> - called at the start of the server +build steps before setting up the datasets.</li> +<li><code>configured</code> - access and modify the setup. +This is called after the server has been configured, before the server is built. +It defaults to calls to <code>configDataAccessPoint</code> for dataset being hosted by the server.</li> +<li><code>server</code> - called after the built, before the return of <code>FusekiServerBuilder.build()</code></li> +</ul> +<p>There are also operations notified when a server is reloaded while running.</p> +<ul> +<li><code>serverConfirmReload</code></li> +<li><code>serveReload</code></li> +</ul> +<p>As of Jena 4.9.0, eeload is not yet supported.</p> +<p>The Fuseki start up sequence is:</p> +<ul> +<li><code>serverBeforeStarting</code> - called at the start of <code>server.start()</code></li> +<li><code>serverAfterStarting</code> - called at the end of <code>server.start()</code></li> +<li><code>serverStopped</code> - called as just after the server +has stopped in the <code>server.stop()</code> call. (note, this is not always called because a server can simply exit the JVM).</li> </ul> -<p>A Fuseki module does not need to implement all these steps, the default for all -of them is “do nothing”. Usually, an extension will only be interested in -certain stpes, like the configuration and registry information of +<p>A Fuseki module does not need to implement all these steps. The default for all +steps is “do nothing”. Usually, an extension will only be interested in +certain steps, such as <code>prepare</code>, or the registry information of <code>configuration</code>.</p> -<p>During the configuration step, the Fuskei configuration file for the server is +<p>During the configuration step, the Fuseki configuration file for the server is available. If the server is built programmatically without a configuration file, this is null.</p> <p>The configuration file can contain RDF information to build resources (e.g. -contains assembler descriptions not directly linked to the server).</p> +it can contain additional assembler descriptions not directly linked to the server).</p> <p>There is an <a href="https://github.com/apache/jena/blob/main/jena-fuseki2/jena-fuseki-main/src/test/java/org/apache/jena/fuseki/main/examples/ExFusekiMain_3_FusekiModule.java">example Fuseki Module</a> in the Fuseki examples directory.</p> -<p><code>FusekiModule</code> interface:</p> +<h3 id="fusekimodule-interface"><code>FusekiModule</code> interface</h3> <div class="highlight"><pre tabindex="0" style="background-color:#f8f8f8;-moz-tab-size:4;-o-tab-size:4;tab-size:4;"><code class="language-java" data-lang="java"><span style="display:flex;"><span><span style="color:#080;font-style:italic">/** </span></span></span><span style="display:flex;"><span><span style="color:#080;font-style:italic"> * Module interface for Fuseki. </span></span></span><span style="display:flex;"><span><span style="color:#080;font-style:italic"> * <p> @@ -240,31 +287,39 @@ in the Fuseki examples directory.</p> </span></span></span><span style="display:flex;"><span><span style="color:#080;font-style:italic"> */</span> </span></span><span style="display:flex;"><span><span style="color:#a2f;font-weight:bold">public</span> <span style="color:#a2f;font-weight:bold">interface</span> <span style="color:#00f">FusekiModule</span> <span style="color:#a2f;font-weight:bold">extends</span> SubsystemLifecycle <span style="color:#666">{</span> </span></span><span style="display:flex;"><span> <span style="color:#080;font-style:italic">/** -</span></span></span><span style="display:flex;"><span><span style="color:#080;font-style:italic"> * Unique (within this server) name to identify this module. -</span></span></span><span style="display:flex;"><span><span style="color:#080;font-style:italic"> * The default is to generate an UUID. +</span></span></span><span style="display:flex;"><span><span style="color:#080;font-style:italic"> * Display name to identify this module. </span></span></span><span style="display:flex;"><span><span style="color:#080;font-style:italic"> */</span> </span></span><span style="display:flex;"><span> <span style="color:#a2f;font-weight:bold">public</span> String <span style="color:#00a000">name</span><span style="color:#666">();</span> </span></span><span style="display:flex;"><span> -</span></span><span style="display:flex;"><span> <span style="color:#080;font-style:italic">/** Module loaded */</span> -</span></span><span style="display:flex;"><span> <span style="color:#a2f">@Override</span> -</span></span><span style="display:flex;"><span> <span style="color:#a2f;font-weight:bold">public</span> <span style="color:#a2f;font-weight:bold">default</span> <span style="color:#0b0;font-weight:bold">void</span> <span style="color:#00a000">start</span><span style="color:#666">()</span> <span style="color:#666">{}</span> -</span></span><span style="display:flex;"><span> -</span></span><span style="display:flex;"><span> <span style="color:#080;font-style:italic">// ---- Build cycle +</span></span><span style="display:flex;"><span> <span style="color:#080;font-style:italic">// -- Build cycle. </span></span></span><span style="display:flex;"><span><span style="color:#080;font-style:italic"></span> </span></span><span style="display:flex;"><span> <span style="color:#080;font-style:italic">/** </span></span></span><span style="display:flex;"><span><span style="color:#080;font-style:italic"> * Called at the start of "build" step. The builder has been set according to the -</span></span></span><span style="display:flex;"><span><span style="color:#080;font-style:italic"> * configuration. The "configModel" parameter is set if a configuration file was -</span></span></span><span style="display:flex;"><span><span style="color:#080;font-style:italic"> * used otherwise it is null. +</span></span></span><span style="display:flex;"><span><span style="color:#080;font-style:italic"> * configuration of API calls and parsing configuration files. No build actions have been carried out yet. +</span></span></span><span style="display:flex;"><span><span style="color:#080;font-style:italic"> * The module can make further FusekiServer.{@link Builder} calls. +</span></span></span><span style="display:flex;"><span><span style="color:#080;font-style:italic"> * The "configModel" parameter is set if a configuration file was used otherwise it is null. </span></span></span><span style="display:flex;"><span><span style="color:#080;font-style:italic"> */</span> -</span></span><span style="display:flex;"><span> <span style="color:#a2f;font-weight:bold">public</span> <span style="color:#a2f;font-weight:bold">default</span> <span style="color:#0b0;font-weight:bold">void</span> <span style="color:#00a000">configuration</span><span style="color:#666">(</span>FusekiServer<span style="color:#666">.</span><span style="color:#b44">Builder</span> builder<span style="color:#666">,</span> DataAccessPointRegistry dapRegistry<span style="color:#666">,</spa [...] -</span></span><span style="display:flex;"><span> dapRegistry<span style="color:#666">.</span><span style="color:#b44">accessPoints</span><span style="color:#666">().</span><span style="color:#b44">forEach</span><span style="color:#666">(</span>accessPoint<span style="color:#666">-></span>configDataAccessPoint<span style="color:#666">(</span>builder<span style="color:#666">,</span> accessPoint<span style="color:#666">,</span> configModel<span style="color:#666">));</span> +</span></span><span style="display:flex;"><span> <span style="color:#a2f;font-weight:bold">public</span> <span style="color:#a2f;font-weight:bold">default</span> <span style="color:#0b0;font-weight:bold">void</span> <span style="color:#00a000">prepare</span><span style="color:#666">(</span>FusekiServer<span style="color:#666">.</span><span style="color:#b44">Builder</span> serverBuilder<span style="color:#666">,</span> Set<span style="color:#666"><</span>String<span style="color:#6 [...] +</span></span><span style="display:flex;"><span> +</span></span><span style="display:flex;"><span> <span style="color:#080;font-style:italic">/** +</span></span></span><span style="display:flex;"><span><span style="color:#080;font-style:italic"> * Called after the DataAccessPointRegistry has been built. +</span></span></span><span style="display:flex;"><span><span style="color:#080;font-style:italic"> * <p> +</span></span></span><span style="display:flex;"><span><span style="color:#080;font-style:italic"> * The default implementation is to call {@link #configDataAccessPoint(DataAccessPoint, Model)} +</span></span></span><span style="display:flex;"><span><span style="color:#080;font-style:italic"> * for each {@link DataAccessPoint}. +</span></span></span><span style="display:flex;"><span><span style="color:#080;font-style:italic"> * <pre> +</span></span></span><span style="display:flex;"><span><span style="color:#080;font-style:italic"> * dapRegistry.accessPoints().forEach(accessPoint{@literal ->}configDataAccessPoint(accessPoint, configModel)); +</span></span></span><span style="display:flex;"><span><span style="color:#080;font-style:italic"> * </pre> +</span></span></span><span style="display:flex;"><span><span style="color:#080;font-style:italic"> */</span> +</span></span><span style="display:flex;"><span> <span style="color:#a2f;font-weight:bold">public</span> <span style="color:#a2f;font-weight:bold">default</span> <span style="color:#0b0;font-weight:bold">void</span> <span style="color:#00a000">configured</span><span style="color:#666">(</span>FusekiServer<span style="color:#666">.</span><span style="color:#b44">Builder</span> serverBuilder<span style="color:#666">,</span> DataAccessPointRegistry dapRegistry<span style="color:#666">,</ [...] +</span></span><span style="display:flex;"><span> dapRegistry<span style="color:#666">.</span><span style="color:#b44">accessPoints</span><span style="color:#666">().</span><span style="color:#b44">forEach</span><span style="color:#666">(</span>accessPoint<span style="color:#666">-></span>configDataAccessPoint<span style="color:#666">(</span>accessPoint<span style="color:#666">,</span> configModel<span style="color:#666">));</span> </span></span><span style="display:flex;"><span> <span style="color:#666">}</span> </span></span><span style="display:flex;"><span> </span></span><span style="display:flex;"><span> <span style="color:#080;font-style:italic">/** -</span></span></span><span style="display:flex;"><span><span style="color:#080;font-style:italic"> * This method is called for each {@link DataAccessPoint} -</span></span></span><span style="display:flex;"><span><span style="color:#080;font-style:italic"> * by the default implementation of {@link #configuration}. +</span></span></span><span style="display:flex;"><span><span style="color:#080;font-style:italic"> * This method is called for each {@link DataAccessPoint} by the default +</span></span></span><span style="display:flex;"><span><span style="color:#080;font-style:italic"> * implementation of {@link #configured} after the new servers +</span></span></span><span style="display:flex;"><span><span style="color:#080;font-style:italic"> * DataAccessPointRegistry has been built. </span></span></span><span style="display:flex;"><span><span style="color:#080;font-style:italic"> */</span> -</span></span><span style="display:flex;"><span> <span style="color:#a2f;font-weight:bold">public</span> <span style="color:#a2f;font-weight:bold">default</span> <span style="color:#0b0;font-weight:bold">void</span> <span style="color:#00a000">configDataAccessPoint</span><span style="color:#666">(</span>FusekiServer<span style="color:#666">.</span><span style="color:#b44">Builder</span> builder<span style="color:#666">,</span> DataAccessPoint dap<span style="color:#666">,</span> Model [...] +</span></span><span style="display:flex;"><span> <span style="color:#a2f;font-weight:bold">public</span> <span style="color:#a2f;font-weight:bold">default</span> <span style="color:#0b0;font-weight:bold">void</span> <span style="color:#00a000">configDataAccessPoint</span><span style="color:#666">(</span>DataAccessPoint dap<span style="color:#666">,</span> Model configModel<span style="color:#666">)</span> <span style="color:#666">{}</span> </span></span><span style="display:flex;"><span> </span></span><span style="display:flex;"><span> <span style="color:#080;font-style:italic">/** </span></span></span><span style="display:flex;"><span><span style="color:#080;font-style:italic"> * Built, not started, about to be returned to the builder caller. @@ -272,6 +327,18 @@ in the Fuseki examples directory.</p> </span></span><span style="display:flex;"><span> <span style="color:#a2f;font-weight:bold">public</span> <span style="color:#a2f;font-weight:bold">default</span> <span style="color:#0b0;font-weight:bold">void</span> <span style="color:#00a000">server</span><span style="color:#666">(</span>FusekiServer server<span style="color:#666">)</span> <span style="color:#666">{</span> <span style="color:#666">}</span> </span></span><span style="display:flex;"><span> </span></span><span style="display:flex;"><span> <span style="color:#080;font-style:italic">/** +</span></span></span><span style="display:flex;"><span><span style="color:#080;font-style:italic"> * Confirm or reject a request to reload. +</span></span></span><span style="display:flex;"><span><span style="color:#080;font-style:italic"> */</span> +</span></span><span style="display:flex;"><span> <span style="color:#a2f;font-weight:bold">public</span> <span style="color:#a2f;font-weight:bold">default</span> <span style="color:#0b0;font-weight:bold">boolean</span> <span style="color:#00a000">serverConfirmReload</span><span style="color:#666">(</span>FusekiServer server<span style="color:#666">)</span> <span style="color:#666">{</span> <span style="color:#a2f;font-weight:bold">return</span> <span style="color:#a2f;font-weight:bold [...] +</span></span><span style="display:flex;"><span> +</span></span><span style="display:flex;"><span> <span style="color:#080;font-style:italic">/** +</span></span></span><span style="display:flex;"><span><span style="color:#080;font-style:italic"> * Perform any operations necessary for a reload. +</span></span></span><span style="display:flex;"><span><span style="color:#080;font-style:italic"> */</span> +</span></span><span style="display:flex;"><span> <span style="color:#a2f;font-weight:bold">public</span> <span style="color:#a2f;font-weight:bold">default</span> <span style="color:#0b0;font-weight:bold">void</span> <span style="color:#00a000">serverReload</span><span style="color:#666">(</span>FusekiServer server<span style="color:#666">)</span> <span style="color:#666">{</span> <span style="color:#666">}</span> +</span></span><span style="display:flex;"><span> +</span></span><span style="display:flex;"><span> <span style="color:#080;font-style:italic">// -- Server start up +</span></span></span><span style="display:flex;"><span><span style="color:#080;font-style:italic"></span> +</span></span><span style="display:flex;"><span> <span style="color:#080;font-style:italic">/** </span></span></span><span style="display:flex;"><span><span style="color:#080;font-style:italic"> * Server starting - called just before server.start happens. </span></span></span><span style="display:flex;"><span><span style="color:#080;font-style:italic"> */</span> </span></span><span style="display:flex;"><span> <span style="color:#a2f;font-weight:bold">public</span> <span style="color:#a2f;font-weight:bold">default</span> <span style="color:#0b0;font-weight:bold">void</span> <span style="color:#00a000">serverBeforeStarting</span><span style="color:#666">(</span>FusekiServer server<span style="color:#666">)</span> <span style="color:#666">{</span> <span style="color:#666">}</span> @@ -289,16 +356,30 @@ in the Fuseki examples directory.</p> </span></span></span><span style="display:flex;"><span><span style="color:#080;font-style:italic"> */</span> </span></span><span style="display:flex;"><span> <span style="color:#a2f;font-weight:bold">public</span> <span style="color:#a2f;font-weight:bold">default</span> <span style="color:#0b0;font-weight:bold">void</span> <span style="color:#00a000">serverStopped</span><span style="color:#666">(</span>FusekiServer server<span style="color:#666">)</span> <span style="color:#666">{</span> <span style="color:#666">}</span> </span></span><span style="display:flex;"><span> -</span></span><span style="display:flex;"><span> <span style="color:#080;font-style:italic">/** Module unloaded */</span> +</span></span><span style="display:flex;"><span> <span style="color:#080;font-style:italic">/** Module unloaded : do not rely on this happening. */</span> </span></span><span style="display:flex;"><span> <span style="color:#a2f">@Override</span> </span></span><span style="display:flex;"><span> <span style="color:#a2f;font-weight:bold">public</span> <span style="color:#a2f;font-weight:bold">default</span> <span style="color:#0b0;font-weight:bold">void</span> <span style="color:#00a000">stop</span><span style="color:#666">()</span> <span style="color:#666">{}</span> </span></span><span style="display:flex;"><span><span style="color:#666">}</span> -</span></span></code></pre></div> +</span></span></code></pre></div><p><code>FusekiAutoModules</code> also provide the +<a href="https://jena.apache.org/documentation/javadoc/jena/org.apache.jena.core/org/apache/jena/sys/JenaSubsystemLifecycle.html"><code>org.apache.jena.base.module.SubsystemLifecycle</code></a> +interface.</p> + </article> <aside class="text-muted align-self-start mb-3 mb-xl-5 p-0 d-none d-xl-flex flex-column sticky-top"> <h2 class="h6 sticky-top m-0 p-2 bg-body-tertiary">On this page</h2> - <nav id="TableOfContents"></nav> + <nav id="TableOfContents"> + <ul> + <li> + <ul> + <li><a href="#automatically-loaded">Automatically loaded</a></li> + <li><a href="#programmaticaly-configuring-a-server">Programmaticaly configuring a server</a></li> + <li><a href="#fuseki-module-operations">Fuseki Module operations</a></li> + <li><a href="#fusekimodule-interface"><code>FusekiModule</code> interface</a></li> + </ul> + </li> + </ul> +</nav> </aside> </main> diff --git a/content/documentation/index.xml b/content/documentation/index.xml index 8067c2142..c7b451d86 100644 --- a/content/documentation/index.xml +++ b/content/documentation/index.xml @@ -810,9 +810,9 @@ Many web log analysers can process this format.</description> <pubDate>Mon, 01 Jan 0001 00:00:00 +0000</pubDate> <guid>https://jena.apache.org/documentation/fuseki2/fuseki-modules.html</guid> - <description>Fuseki modules are a mechanism to include extension code into a Fuseki server. Modules are invoked during the process of building a Fuseki Main server. The module can modify the server configuration, add new functionality, or react to a server being built and started. -This feature was added in Jena version 4.3.0. They are an expeirmental feature that will evolve based on experineace and use cases. -Fuseki Modules are loaded use the JDK ServiceLoader by being placing a jar file on the classpath, together with any additional dependencies.</description> + <description>Fuseki modules are a mechanism to include extension code into a Fuseki server. Modules are invoked during the process of building a Fuseki Main server. A module can modify the server configuration, add new functionality, or react to a server being built and started. +This feature was added in Jena version 4.3.0. It is an experimental feature that will evolve based on feedback and use cases. +The interface for modules is FusekiModule; if automatcally loaded, the interface is FusekiAutoModule which extends FusekiModule.</description> </item> <item> diff --git a/content/documentation/io/rdf-output.html b/content/documentation/io/rdf-output.html index ea2c59780..b61c47b19 100644 --- a/content/documentation/io/rdf-output.html +++ b/content/documentation/io/rdf-output.html @@ -423,6 +423,10 @@ or write N-triples/N-Quads.</p> :b foaf:knows :a . </code></pre> +<p>The default pretty printed output (shown above) aligns predicates +and objects, which can result in wide lines. For a narrower +indentation style, set <code>ttl:indentStyle</code> to <code>long</code>. +See <a href="#opt-turtle-trig">Turtle and Trig format options</a>.</p> <p>Pretty printed formats:</p> <table> <thead> @@ -556,6 +560,11 @@ otherwise noted, the setting applies to both Turtle and TriG.</p> <td>“sparql”, “rdf11”, “at”, “n3”</td> </tr> <tr> +<td>RIOT.symTurtleIndentStyle</td> +<td>“ttl:indentStyle”</td> +<td>“wide”, “long”</td> +</tr> +<tr> <td>RIOT.symTurtleOmitBase</td> <td>“ttl:omitBase”</td> <td>“true”, “false”</td> @@ -594,6 +603,17 @@ otherwise noted, the setting applies to both Turtle and TriG.</p> .set(RIOT.symTurtleDirectiveStyle, "sparql") .lang(Lang.TTL) .output(System.out); +</code></pre><h5 id="_setting-indent-style_"><em>Setting indent style</em></h5> +<pre tabindex="0"><code> riot --set ttl:indentStyle=long --formatted=ttl file1.rdf file2.nt ... +</code></pre><p>and in code:</p> +<pre tabindex="0"><code>RDFWriter.source(model) + .format(RDFFormat.TURTLE_LONG) + .output(System.out); +</code></pre><p>or:</p> +<pre tabindex="0"><code> RDFWriter.source(model) + .set(RIOT.symTurtleIndentStyle, "long") + .lang(Lang.TTL) + .output(System.out); </code></pre><h5 id="_base-uri_"><em>Base URI</em></h5> <p>Output can be written with relative URIs and no base. Note: such output is not portable; its meaning depends on the base URI at the time of reading.</p> @@ -669,6 +689,16 @@ in ASCII (using <code>\u</code> escape sequences for non-ASCI characters where n </tbody> </table> <h3 id="json-ld">JSON-LD</h3> +<blockquote> +<p>Caution. This section describes features that may be removed.</p> +<p>Jena uses different third party processors for JSON-LD 1.0 and JSON-LD 1.1.</p> +<p>This section describes support for passing configuration to the JSON-LD 1.0 +processor only. It does not apply to the JSON-LD 1.1 processor.</p> +<p>It is planned that support for JSON-LD 1.0 will be removed in Jena5.</p> +<p>The project is looking for contributions for passing framing configuration to +the JSON-LD 1.1 processor, which is +<a href="https://github.com/filip26/titanium-json-ld">titanium-json-ld</a>.</p> +</blockquote> <p>JSON-LD output is supported, in its various flavors (“compacted”, “expanded”, “flattened”, “framed”), by using one of the following RDFFormats:</p> diff --git a/content/documentation/query/javascript-functions.html b/content/documentation/query/javascript-functions.html index bce078be2..146d56dc1 100644 --- a/content/documentation/query/javascript-functions.html +++ b/content/documentation/query/javascript-functions.html @@ -185,6 +185,7 @@ <ul> <li><a href="#requirements">Requirements</a></li> <li><a href="#enabling-and-loading-javascript-functions">Enabling and Loading JavaScript functions</a></li> + <li><a href="#identifying-callable-functions">Identifying callable functions</a></li> <li><a href="#using-javascript-functions">Using JavaScript functions</a> <ul> <li><a href="#arguments-and-function-results">Arguments and Function Results</a></li> @@ -244,6 +245,25 @@ sparql --set arq:js-library=SomeFile.js --data ... --query ... <p><strong>WARNING:</strong> Enabling this feature exposes the majority of the underlying scripting engine directly to SPARQL queries so may provide a vector for arbitrary code execution. Therefore it is recommended that this feature remain disabled for any publicly accessible deployment that utilises the ARQ query engine.</p> +<h2 id="identifying-callable-functions">Identifying callable functions</h2> +<p>The context setting ““<a href="http://jena.apache.org/ARQ#scriptAllowList%22">http://jena.apache.org/ARQ#scriptAllowList"</a> is used to +provide a comma-separated list of function names, which are the local part of +the URI, that are allowed to be called +as custom script functions.</p> +<p>This can be written as <code>arq:scriptAllowList</code> for commands and Fuseki configuration files. +It is the java constant <code>ARQ.symCustomFunctionScriptAllowList</code></p> +<pre><code>sparql --set arq:js-library=SomeFile.js \ + --set arq:scriptAllowList=toCamelCase,anotherFunction + --data ... --query ... +</code></pre> +<p>and a query of:</p> +<pre><code>PREFIX js: <http://jena.apache.org/ARQ/jsFunction#> + +SELECT ?input (js:toCamelCase(?input) AS ?X) +{ + VALUES ?input { "some woRDs to PROCESS" } +} +</code></pre> <h2 id="using-javascript-functions">Using JavaScript functions</h2> <p>SPARQL functions implemented in JavaScript are automatically called when a URI starting “<a href="http://jena.apache.org/ARQ/jsFunction#%22">http://jena.apache.org/ARQ/jsFunction#"</a> used.</p> @@ -314,7 +334,9 @@ SELECT ?input (js:toCamelCase(?input) AS ?X) <p>The context setting can be provided on the command line starting the server, for example:</p> <pre><code>export JVM_ARGS=-Djena:scripting=true -fuseki --set arq:js-library=functions.js --mem /ds +fuseki --set arq:js-library=functions.js \ + --set arq:scriptAllowList=toCamelCase \ + --mem /ds </code></pre> <p>or it can be specified in the server configuration file <code>config.ttl</code>:</p> <pre><code>PREFIX : <#> @@ -329,6 +351,10 @@ PREFIX ja: <http://jena.hpl.hp.com/2005/11/Assembler#> ja:cxtName "arq:js-library" ; ja:cxtValue "/filepath/functions.js" ] ; + ja:context [ + ja:cxtName "arq:scriptAllowList" ; + ja:cxtValue "toCamelCase" + ] ; . <#service> rdf:type fuseki:Service; @@ -355,6 +381,7 @@ fuseki --conf config.ttl <ul> <li><a href="#requirements">Requirements</a></li> <li><a href="#enabling-and-loading-javascript-functions">Enabling and Loading JavaScript functions</a></li> + <li><a href="#identifying-callable-functions">Identifying callable functions</a></li> <li><a href="#using-javascript-functions">Using JavaScript functions</a> <ul> <li><a href="#arguments-and-function-results">Arguments and Function Results</a></li> diff --git a/content/download/index.html b/content/download/index.html index 1b8c11b71..91907fffb 100644 --- a/content/download/index.html +++ b/content/download/index.html @@ -208,9 +208,9 @@ </thead> <tbody> <tr> -<td><a href="[preferred]jena/source/jena-4.8.0-source-release.zip">jena-4.8.0-source-release.zip</a></td> -<td style="text-align:center"><a href="https://downloads.apache.org/jena/source/jena-4.8.0-source-release.zip.sha512">SHA512</a></td> -<td style="text-align:center"><a href="https://downloads.apache.org/jena/source/jena-4.8.0-source-release.zip.asc">PGP</a></td> +<td><a href="[preferred]jena/source/jena-4.9.0-source-release.zip">jena-4.9.0-source-release.zip</a></td> +<td style="text-align:center"><a href="https://downloads.apache.org/jena/source/jena-4.9.0-source-release.zip.sha512">SHA512</a></td> +<td style="text-align:center"><a href="https://downloads.apache.org/jena/source/jena-4.9.0-source-release.zip.asc">PGP</a></td> </tr> </tbody> </table> @@ -226,14 +226,14 @@ </thead> <tbody> <tr> -<td><a href="[preferred]jena/binaries/apache-jena-fuseki-4.8.0.tar.gz">apache-jena-fuseki-4.8.0.tar.gz</a></td> -<td style="text-align:center"><a href="https://downloads.apache.org/jena/binaries/apache-jena-fuseki-4.8.0.tar.gz.sha512">SHA512</a></td> -<td style="text-align:center"><a href="https://downloads.apache.org/jena/binaries/apache-jena-fuseki-4.8.0.tar.gz.asc">PGP</a></td> +<td><a href="[preferred]jena/binaries/apache-jena-fuseki-4.9.0.tar.gz">apache-jena-fuseki-4.9.0.tar.gz</a></td> +<td style="text-align:center"><a href="https://downloads.apache.org/jena/binaries/apache-jena-fuseki-4.9.0.tar.gz.sha512">SHA512</a></td> +<td style="text-align:center"><a href="https://downloads.apache.org/jena/binaries/apache-jena-fuseki-4.9.0.tar.gz.asc">PGP</a></td> </tr> <tr> -<td><a href="[preferred]jena/binaries/apache-jena-fuseki-4.8.0.zip">apache-jena-fuseki-4.8.0.zip</a></td> -<td style="text-align:center"><a href="https://downloads.apache.org/jena/binaries/apache-jena-fuseki-4.8.0.zip.sha512">SHA512</a></td> -<td style="text-align:center"><a href="https://downloads.apache.org/jena/binaries/apache-jena-fuseki-4.8.0.zip.asc">PGP</a></td> +<td><a href="[preferred]jena/binaries/apache-jena-fuseki-4.9.0.zip">apache-jena-fuseki-4.9.0.zip</a></td> +<td style="text-align:center"><a href="https://downloads.apache.org/jena/binaries/apache-jena-fuseki-4.9.0.zip.sha512">SHA512</a></td> +<td style="text-align:center"><a href="https://downloads.apache.org/jena/binaries/apache-jena-fuseki-4.9.0.zip.asc">PGP</a></td> </tr> </tbody> </table> @@ -249,14 +249,14 @@ The binary distribution of libraries contains the APIs, SPARQL engine, the TDB n </thead> <tbody> <tr> -<td><a href="[preferred]jena/binaries/apache-jena-4.8.0.tar.gz">apache-jena-4.8.0.tar.gz</a></td> -<td style="text-align:center"><a href="https://downloads.apache.org/jena/binaries/apache-jena-4.8.0.tar.gz.sha512">SHA512</a></td> -<td style="text-align:center"><a href="https://downloads.apache.org/jena/binaries/apache-jena-4.8.0.tar.gz.asc">PGP</a></td> +<td><a href="[preferred]jena/binaries/apache-jena-4.9.0.tar.gz">apache-jena-4.9.0.tar.gz</a></td> +<td style="text-align:center"><a href="https://downloads.apache.org/jena/binaries/apache-jena-4.9.0.tar.gz.sha512">SHA512</a></td> +<td style="text-align:center"><a href="https://downloads.apache.org/jena/binaries/apache-jena-4.9.0.tar.gz.asc">PGP</a></td> </tr> <tr> -<td><a href="[preferred]jena/binaries/apache-jena-4.8.0.zip">apache-jena-4.8.0.zip</a></td> -<td style="text-align:center"><a href="https://downloads.apache.org/jena/binaries/apache-jena-4.8.0.zip.sha512">SHA512</a></td> -<td style="text-align:center"><a href="https://downloads.apache.org/jena/binaries/apache-jena-4.8.0.zip.asc">PGP</a></td> +<td><a href="[preferred]jena/binaries/apache-jena-4.9.0.zip">apache-jena-4.9.0.zip</a></td> +<td style="text-align:center"><a href="https://downloads.apache.org/jena/binaries/apache-jena-4.9.0.zip.sha512">SHA512</a></td> +<td style="text-align:center"><a href="https://downloads.apache.org/jena/binaries/apache-jena-4.9.0.zip.asc">PGP</a></td> </tr> </tbody> </table> @@ -272,9 +272,9 @@ The binary distribution of Fuseki as a WAR file: </thead> <tbody> <tr> -<td><a href="[preferred]jena/binaries/jena-fuseki-war-4.8.0.war">jena-fuseki-war-4.8.0.war</a></td> -<td style="text-align:center"><a href="https://downloads.apache.org/jena/binaries/jena-fuseki-war-4.8.0.war.sha512">SHA512</a></td> -<td style="text-align:center"><a href="https://downloads.apache.org/jena/binaries/jena-fuseki-war-4.8.0.war.asc">PGP</a></td> +<td><a href="[preferred]jena/binaries/jena-fuseki-war-4.9.0.war">jena-fuseki-war-4.9.0.war</a></td> +<td style="text-align:center"><a href="https://downloads.apache.org/jena/binaries/jena-fuseki-war-4.9.0.war.sha512">SHA512</a></td> +<td style="text-align:center"><a href="https://downloads.apache.org/jena/binaries/jena-fuseki-war-4.9.0.war.asc">PGP</a></td> </tr> </tbody> </table> diff --git a/content/index.json b/content/index.json index d1dbe12d5..2d6018e57 100644 --- a/content/index.json +++ b/content/index.json @@ -1 +1 @@ -[{"categories":null,"contents":"This page is historical \u0026ldquo;for information only\u0026rdquo; - there is no Apache release of Eyeball and the code has not been updated for Jena3.\nThe original source code is available. So you\u0026rsquo;ve got Eyeball installed and you\u0026rsquo;ve run it on one of your files, and Eyeball doesn\u0026rsquo;t like it. You\u0026rsquo;re not sure why, or what to do about it. Here\u0026rsquo;s what\u0026rsquo;s going on.\nEyeball inspects your model a [...] \ No newline at end of file +[{"categories":null,"contents":"This page is historical \u0026ldquo;for information only\u0026rdquo; - there is no Apache release of Eyeball and the code has not been updated for Jena3.\nThe original source code is available. So you\u0026rsquo;ve got Eyeball installed and you\u0026rsquo;ve run it on one of your files, and Eyeball doesn\u0026rsquo;t like it. You\u0026rsquo;re not sure why, or what to do about it. Here\u0026rsquo;s what\u0026rsquo;s going on.\nEyeball inspects your model a [...] \ No newline at end of file diff --git a/content/index.xml b/content/index.xml index 589bd44fa..899ae73a3 100644 --- a/content/index.xml +++ b/content/index.xml @@ -872,9 +872,9 @@ Many web log analysers can process this format.</description> <pubDate>Mon, 01 Jan 0001 00:00:00 +0000</pubDate> <guid>https://jena.apache.org/documentation/fuseki2/fuseki-modules.html</guid> - <description>Fuseki modules are a mechanism to include extension code into a Fuseki server. Modules are invoked during the process of building a Fuseki Main server. The module can modify the server configuration, add new functionality, or react to a server being built and started. -This feature was added in Jena version 4.3.0. They are an expeirmental feature that will evolve based on experineace and use cases. -Fuseki Modules are loaded use the JDK ServiceLoader by being placing a jar file on the classpath, together with any additional dependencies.</description> + <description>Fuseki modules are a mechanism to include extension code into a Fuseki server. Modules are invoked during the process of building a Fuseki Main server. A module can modify the server configuration, add new functionality, or react to a server being built and started. +This feature was added in Jena version 4.3.0. It is an experimental feature that will evolve based on feedback and use cases. +The interface for modules is FusekiModule; if automatcally loaded, the interface is FusekiAutoModule which extends FusekiModule.</description> </item> <item> diff --git a/content/sitemap.xml b/content/sitemap.xml index a81200d4e..2f70d218d 100644 --- a/content/sitemap.xml +++ b/content/sitemap.xml @@ -6,7 +6,7 @@ <lastmod>2020-06-28T16:59:07+01:00</lastmod> </url><url> <loc>https://jena.apache.org/about_jena.html</loc> - <lastmod>2023-07-07T19:09:02+01:00</lastmod> + <lastmod>2023-07-11T20:47:52+01:00</lastmod> </url><url> <loc>https://jena.apache.org/documentation/permissions/example.html</loc> <lastmod>2022-01-12T17:24:53+00:00</lastmod> @@ -51,7 +51,7 @@ <lastmod>2020-02-28T13:09:12+01:00</lastmod> </url><url> <loc>https://jena.apache.org/download/</loc> - <lastmod>2023-04-16T17:26:15+01:00</lastmod> + <lastmod>2023-07-08T22:28:51+01:00</lastmod> </url><url> <loc>https://jena.apache.org/documentation/archive/sdb/</loc> <lastmod>2022-11-09T14:16:56+00:00</lastmod> @@ -114,7 +114,7 @@ <lastmod>2021-11-05T08:11:46+00:00</lastmod> </url><url> <loc>https://jena.apache.org/documentation/query/javascript-functions.html</loc> - <lastmod>2023-04-26T11:23:47+01:00</lastmod> + <lastmod>2023-07-08T22:09:07+01:00</lastmod> </url><url> <loc>https://jena.apache.org/documentation/query/lateral-join.html</loc> <lastmod>2023-02-26T22:14:57+01:00</lastmod> @@ -195,16 +195,16 @@ <lastmod>2021-11-05T11:40:17+00:00</lastmod> </url><url> <loc>https://jena.apache.org/documentation/fuseki2/fuseki-data-access-control.html</loc> - <lastmod>2023-02-05T18:59:30+01:00</lastmod> + <lastmod>2023-08-15T08:28:56+01:00</lastmod> </url><url> <loc>https://jena.apache.org/documentation/rdfs/</loc> <lastmod>2023-04-09T15:11:22+02:00</lastmod> </url><url> <loc>https://jena.apache.org/documentation.html</loc> - <lastmod>2023-07-04T08:38:43+01:00</lastmod> + <lastmod>2023-08-15T08:29:25+01:00</lastmod> </url><url> <loc>https://jena.apache.org/download.html</loc> - <lastmod>2023-04-16T17:26:15+01:00</lastmod> + <lastmod>2023-07-08T22:28:51+01:00</lastmod> </url><url> <loc>https://jena.apache.org/documentation/notes/event-handler-howto.html</loc> <lastmod>2023-06-06T21:08:29+02:00</lastmod> @@ -249,7 +249,7 @@ <lastmod>2022-09-18T09:08:25+02:00</lastmod> </url><url> <loc>https://jena.apache.org/documentation/fuseki2/fuseki-modules.html</loc> - <lastmod>2022-02-01T20:25:33+00:00</lastmod> + <lastmod>2023-07-08T22:09:33+01:00</lastmod> </url><url> <loc>https://jena.apache.org/documentation/fuseki2/fuseki-quick-start.html</loc> <lastmod>2021-09-16T13:13:09+02:00</lastmod> @@ -375,7 +375,7 @@ <lastmod>2020-05-01T11:11:56+12:00</lastmod> </url><url> <loc>https://jena.apache.org/about_jena/security-advisories.html</loc> - <lastmod>2023-07-07T19:09:02+01:00</lastmod> + <lastmod>2023-07-11T20:47:52+01:00</lastmod> </url><url> <loc>https://jena.apache.org/documentation/txn/</loc> <lastmod>2020-02-28T13:09:12+01:00</lastmod> @@ -723,6 +723,6 @@ <lastmod>2023-02-20T16:01:22-05:00</lastmod> </url><url> <loc>https://jena.apache.org/documentation/io/rdf-output.html</loc> - <lastmod>2022-08-26T15:49:37+01:00</lastmod> + <lastmod>2023-08-15T08:29:25+01:00</lastmod> </url> </urlset>