Re: the scripting is a use of parameter substitution -
http://tldp.org/LDP/abs/html/parameter-substitution.html - the general
form of which is as follows:
VAR=${VAR:-DEFAULT}
This initialising a variable from the existing value if available and the
:- says if it is currently undeclared/null use the given default instead
So in the specific example you gave it says honour the users JVM_ARGS
variable if set in their environment otherwise use -Xmx1200M as the value
Rob
On 27/01/2015 08:27, "Stian Soiland-Reyes" <[email protected]> wrote:
>On 27 January 2015 at 15:23, Andy Seaborne <[email protected]> wrote:
>
>> tdbloader is pure java and is included in the fuseki jar.
>> tdbloader2 has a shell script to drive it.
>> You can't run either loader on a live database
>
>Right. A nice feature (or side-effect?) I found was that Fuseki can
>pick up live any existing datasets (made by tdloader) by simply
>"Creating a new dataset" that has exactly the same name:
>
>https://github.com/stain/jena/blob/fuseki2-docker/jena-fuseki2/jena-fuseki
>-docker/README.md#recognizing-the-dataset-in-fuseki
>
>
>
>
>> did you mean
>> java -cp fuseki-server.jar tdb.tdbloader --loc
>
>
>Right - I got this to work, and even added a little shell-script to
>help with *ttl.gz expansion (as that could get tricky through the
>shell on the host).
>
>See
>https://github.com/stain/jena/tree/fuseki2-docker/jena-fuseki2/jena-fuseki
>-docker#data-loading
>
>
>With not much adjustment (usual FUSEKI_HOME/FUSEKI_BASE stuff) this
>script could work well also in the normal fuseki2 dist?
>
>https://github.com/stain/jena/blob/fuseki2-docker/jena-fuseki2/jena-fuseki
>-docker/load.sh
>
>
>The default is to load all *ttl *rdf.gz etc. in the /staging directory.
>
>
>As tdbloader with just filenames chucks everything into the default
>graph, I guess the only option to get named graphs is through an
>assembler file?
>
>I didn't use tdbloader2 for now as it will only work with fresh
>databases (could add confusion to the README).
>
>
>> config.ttl or the UI.
>
>I went with just telling people to click the button in the UI, this
>worked smoothly. :-)
>
>I guess it would only be a challenge if you wanted to load many datasets.
>
>
>It would be nice to just add it to config.ttl, but it seems then I
>have to copy the defaults for "query" endpoints etc? (Where from?).
>It would also have to detect if the dataset already exists.
>
>
>Would I get reasonable defaults if I add a minimal config with just
>DatasetTDB, fuseki:dataset and tdb:location - or do I need to include
>all of those from the template?
>
>
>The datasets created in the UI seem to live under
>system-configuration/ rather than in config.ttl
>-- should such a register-load shell script put things in there
>instead of config.ttl?
>
>Are those UUIDs registered somewhere?
>
>
>
>>> Q: Should I run the standalone Fuseki or a WAR inside say Tomcat?
>> Your choice!
>
>I'll stick with the standalone then, as it means I get the tdb.loader
>for free :)
>
>
>>> Q: Are there any memory settings that should be made accessible?
>> Heap - usually it does not need changing but if you have lots of
>>datasets it
>> might.
>
>I see - now it is this line:
>
> JVM_ARGS=${JVM_ARGS:--Xmx1200M}
>
>Why is this using ":" here? I don't understand that bit. :-)
>
>I guess I would need to freshen my sed skills to set the memory limit
>from a shell variable.
>
>
>So you generally mean.. a high number of datasets? Size of dataset or
>query doesn't matter much with TDB?
>
>
>>> Q: Is it safe to just stop fuseki-server with Ctrl-C / docker stop? It
>>> seems to stop a bit too fast, with no log outputs.
>> Yes - or even "kill -9"
>
>Nice! So
>
> docker stop fuseki
>
>just works safely.
>
>
>> The distribution has an unversioned file in it IIRC
>
>Could you clarify..?
>
>apache-jena-2.12.1.tar.gz and jena-fuseki-1.1.1-distribution.tar.gz
>don't seem to include fuseki2.
>
>
>So I have to (at least until Fuseki 2.0.0 is released) download
>jena-fuseki-dist from
>
>https://repository.apache.org/content/groups/snapshots/org/apache/jena/jen
>a-fuseki-dist/2.0.0-SNAPSHOT/
>
>by finding the timestamp in
>
>https://repository.apache.org/content/groups/snapshots/org/apache/jena/jen
>a-fuseki-dist/2.0.0-SNAPSHOT/maven-metadata.xml
>
>
>
>
>--
>Stian Soiland-Reyes
>Apache Taverna (incubating)
>http://orcid.org/0000-0001-9842-9718