Mercurial > dive4elements > gnv-client
changeset 916:a03d2006d7c6
Added Example for adding a new FIS to the REST-Server
doc/trunk@1050 c6561f87-3c4e-4783-a992-168aeb5c3f6f
author | Tim Englich <tim.englich@intevation.de> |
---|---|
date | Tue, 04 May 2010 10:57:08 +0000 (2010-05-04) |
parents | a6f86fa053a1 |
children | 8c813d136298 |
files | doc/ChangeLog doc/config-manual/model_of_transitions.tex |
diffstat | 2 files changed, 35 insertions(+), 0 deletions(-) [+] |
line wrap: on
line diff
--- a/doc/ChangeLog Tue May 04 10:08:25 2010 +0000 +++ b/doc/ChangeLog Tue May 04 10:57:08 2010 +0000 @@ -1,3 +1,8 @@ +2010-05-04 Tim Englich <tim@intevation.de> + + * config-manual/model_of_transitions.tex: + Added Example for adding a new FIS to the REST-Server. + 2010-05-04 Tim Englich <tim@intevation.de> * config-manual/model_of_transitions.tex:
--- a/doc/config-manual/model_of_transitions.tex Tue May 04 10:08:25 2010 +0000 +++ b/doc/config-manual/model_of_transitions.tex Tue May 04 10:57:08 2010 +0000 @@ -567,6 +567,36 @@ In this XML-Fragment you only have to replace the placeholder NEWFISNAME with a unique short Name for the new FIS. +\paragraph{Example} +This Example shows how to add an FIS and which effects it took to the +REST-Server. + +At first we add the follwing Artifactfactory into the file conf/conf.xml +in Section /artifact-database/artifact-factories which add a new +FIS called justanewfis to the Server: + +\begin{lstlisting} +<artifact-factory name='fis\_justanewfis' + description='Factory to create an artifact to be used with the FIS NEWFISNAME' + ttl='3600000' + artifact='de.intevation.artifactdatabase.ProxyArtifact'> + de.intevation.gnv.artifacts.GNVProductArtifactFactory +</artifact-factory> +\end{lstlisting} + +Then we restart the Artifact-database executing the followinig command: + +/etc/init.d/artifactdb restart + +Then we check if the new FIS is served by the REST-Server +calling the following command: + +curl http://localhost:8181/factories |grep fis\_justanewfis + +If the FIS was added the new Artifactfactory will be found in the generated +XML-Output and it will be shown. +Otherwise no XML-Output will be shown. + \subsubsection{Adding a new Artifact for Artifactfactory} The next Step is to define the Artifact itself. For this it is necessary to add an XML-Fragment into the Section /artifacts of