source: branches/PublicaMundi_David-devel/docs/_build/html/services/process-profiles.html @ 659

Last change on this file since 659 was 659, checked in by nbozon, 9 years ago

Massive update of zoo docs

File size: 17.7 KB
Line 
1
2
3<!DOCTYPE html>
4<!--[if IE 8]><html class="no-js lt-ie9" lang="en" > <![endif]-->
5<!--[if gt IE 8]><!--> <html class="no-js" lang="en" > <!--<![endif]-->
6<head>
7  <meta charset="utf-8">
8  <meta name="viewport" content="width=device-width, initial-scale=1.0">
9 
10  <title>Process profiles registry &mdash; ZOO-Project 1.4a0 documentation</title>
11 
12  <link href="http://fonts.googleapis.com/css?family=Days+One" rel="stylesheet" type="text/css">
13 
14 
15
16 
17
18 
19 
20   
21      <link rel="search" type="application/opensearchdescription+xml" title="Search within ZOO-Project 1.4a0 documentation" href="../_static/opensearch.xml"/>
22   
23
24 
25
26 
27 
28    <link rel="stylesheet" href="../_static/css/theme.css" type="text/css" />
29 
30
31 
32
33 
34    <link rel="top" title="ZOO-Project 1.4a0 documentation" href="../index.html"/>
35        <link rel="up" title="ZOO-Services" href="index.html"/>
36        <link rel="next" title="Create your own ZOO-Services" href="howtos.html"/>
37        <link rel="prev" title="ZOO-Service configuration file" href="zcfg-reference.html"/> 
38
39 
40  <script src="_static/js/modernizr.min.js"></script>
41
42</head>
43
44<body class="wy-body-for-nav" role="document">
45
46  <div class="wy-grid-for-nav">
47
48   
49    <nav data-toggle="wy-nav-shift" class="wy-nav-side">
50      <div class="wy-side-nav-search">
51       
52
53       
54          <a class="shrink" href="http://zoo-project.org"><img src="http://zoo-project.org/img/zoo-sun-logo.png" class="img-responsive sun" style="display: inline;"> ZOO</a>
55       
56
57       
58        </a>
59
60       
61<div role="search">
62  <form id="rtd-search-form" class="wy-form" action="../search.html" method="get">
63    <input type="text" name="q" placeholder="Search docs" />
64    <input type="hidden" name="check_keywords" value="yes" />
65    <input type="hidden" name="area" value="default" />
66  </form>
67</div>
68
69       
70      </div>
71
72      <div class="wy-menu wy-menu-vertical" data-spy="affix" role="navigation" aria-label="main navigation">
73       
74         
75         
76              <ul class="current">
77<li class="toctree-l1"><a class="reference internal" href="../intro.html">Introduction</a><ul>
78<li class="toctree-l2"><a class="reference internal" href="../intro.html#what-is-zoo-project">What is ZOO-Project ?</a></li>
79<li class="toctree-l2"><a class="reference internal" href="../intro.html#zoo-project-components">ZOO-Project components</a></li>
80<li class="toctree-l2"><a class="reference internal" href="../intro.html#open-source">Open Source</a></li>
81</ul>
82</li>
83<li class="toctree-l1"><a class="reference internal" href="../install/index.html">ZOO-Project installation</a><ul>
84<li class="toctree-l2"><a class="reference internal" href="../install/install-prerequisites.html">Prerequisites</a></li>
85<li class="toctree-l2"><a class="reference internal" href="../install/install-download.html">Download</a></li>
86<li class="toctree-l2"><a class="reference internal" href="../install/install-confoptions.html">Configure options</a></li>
87<li class="toctree-l2"><a class="reference internal" href="../install/install-installation.html">Installation on Unix/Linux</a></li>
88<li class="toctree-l2"><a class="reference internal" href="../install/install-onwindows.html">Installation on Windows ™</a></li>
89<li class="toctree-l2"><a class="reference internal" href="../install/install-onmacos.html">Installation on MacOSX ™</a></li>
90</ul>
91</li>
92<li class="toctree-l1"><a class="reference internal" href="../kernel/index.html">ZOO-Kernel</a><ul>
93<li class="toctree-l2"><a class="reference internal" href="../kernel/what.html">What is ZOO-Kernel ?</a></li>
94<li class="toctree-l2"><a class="reference internal" href="../kernel/configuration.html">ZOO-Kernel configuration</a></li>
95<li class="toctree-l2"><a class="reference internal" href="../kernel/mapserver.html">Optional MapServer support</a></li>
96<li class="toctree-l2"><a class="reference internal" href="../kernel/orfeotoolbox.html">Optional Orfeo Toolbox support</a></li>
97<li class="toctree-l2"><a class="reference internal" href="../kernel/sagagis.html">Optional SAGA GIS support</a></li>
98</ul>
99</li>
100<li class="toctree-l1 current"><a class="reference internal" href="index.html">ZOO-Services</a><ul class="current">
101<li class="toctree-l2"><a class="reference internal" href="what.html">What are ZOO-Services ?</a></li>
102<li class="toctree-l2"><a class="reference internal" href="zcfg-reference.html">ZOO-Service configuration file</a></li>
103<li class="toctree-l2 current"><a class="current reference internal" href="">Process profiles registry</a></li>
104<li class="toctree-l2"><a class="reference internal" href="howtos.html">Create your own ZOO-Services</a></li>
105<li class="toctree-l2"><a class="reference internal" href="status.html">ZOO Status Service</a></li>
106<li class="toctree-l2"><a class="reference internal" href="debug.html">Debugging ZOO Services</a></li>
107<li class="toctree-l2"><a class="reference internal" href="zoo-services.html">Available ZOO-Services</a></li>
108</ul>
109</li>
110<li class="toctree-l1"><a class="reference internal" href="../api/index.html">ZOO-API</a><ul>
111<li class="toctree-l2"><a class="reference internal" href="../api/what.html">What is ZOO-API ?</a></li>
112<li class="toctree-l2"><a class="reference internal" href="../api/howto.html">Using ZOO-API</a></li>
113<li class="toctree-l2"><a class="reference internal" href="../api/classes.html">ZOO-API Classes</a></li>
114<li class="toctree-l2"><a class="reference internal" href="../api/examples.html">Examples</a></li>
115</ul>
116</li>
117<li class="toctree-l1"><a class="reference internal" href="../client/index.html">ZOO-Client</a><ul>
118<li class="toctree-l2"><a class="reference internal" href="../client/what.html">What is ZOO-Client ?</a></li>
119<li class="toctree-l2"><a class="reference internal" href="../client/howto.html">Using ZOO-Client</a></li>
120<li class="toctree-l2"><a class="reference internal" href="../client/example.html">Example application</a></li>
121</ul>
122</li>
123<li class="toctree-l1"><a class="reference internal" href="../contribute/index.html">Contributor Guide</a><ul>
124<li class="toctree-l2"><a class="reference internal" href="../contribute/howto.html">How to contribute ?</a></li>
125<li class="toctree-l2"><a class="reference internal" href="../contribute/code.html">Contribute code</a></li>
126</ul>
127</li>
128</ul>
129
130         
131       
132      </div>
133      &nbsp;
134    </nav>
135
136    <section data-toggle="wy-nav-shift" class="wy-nav-content-wrap">
137
138     
139      <nav class="wy-nav-top" role="navigation" aria-label="top navigation">
140        <i data-toggle="wy-nav-top" class="fa fa-bars"></i>
141        <a href="../contents.html">ZOO-Project</a>
142      </nav>
143
144
145     
146      <div class="wy-nav-content">
147        <div class="rst-content">
148          <div role="navigation" aria-label="breadcrumbs navigation">
149  <ul class="wy-breadcrumbs">
150
151    <li><a href="../contents.html"> Docs</a> &#8725; &#160;</li>
152     
153          <li><a href="index.html">ZOO-Services</a> &#8725; &#160;</li>
154     
155    <li>Process profiles registry</li>
156      <li class="wy-breadcrumbs-aside">
157       
158          <a href="../_sources/services/process-profiles.txt" rel="nofollow"> View page source</a>
159       
160      </li>
161  </ul>
162  <hr/>
163</div>
164          <div role="main" class="document">
165           
166  <div class="section" id="process-profiles-registry">
167<span id="process-profiles"></span><h1>Process profiles registry<a class="headerlink" href="#process-profiles-registry" title="Permalink to this headline"></a></h1>
168<p>WPS Services belonging to the same Services provider often share the
169same inputs and outputs. In such a case, every <a class="reference internal" href="zcfg-reference.html#services-zcfg"><span>ZCFG</span></a> file would contain the same metadata information and
170this may be a waste of time to write them all.</p>
171<p><a class="reference internal" href="../kernel/index.html#kernel-index"><span>ZOO-Kernel</span></a> is able to handle metadata inheritance from <a class="reference external" href="http://www.zoo-project.org/trac/changeset/607">rev. 607</a>, and this solves the issue of writing many ZCFG with same input and output. A registry can be loaded (before any other ZCFG files) and contain a set of Process Profiles organized in hierarchic levels according to the following rules:</p>
172<blockquote>
173<div><ul class="simple">
174<li><em>Concept</em>: The higher level in the hierarchy. <em>Concepts</em> are basic text files containing an abstract description of a WPS Service.</li>
175<li><em>Generic</em>: A <em>Generic</em> profile can make reference to <em>Concepts</em>. It defines inputs and outputs without data format or maximum size limitation.</li>
176<li><em>Implementation</em>: An <em>Implementation</em> profile can inherit from a
177generic profile and make reference to concepts. It contains all
178the metadata information about a particular WPS Service (see
179<a class="reference internal" href="zcfg-reference.html#services-zcfg"><span>ZCFG reference</span></a> for more information).</li>
180</ul>
181</div></blockquote>
182<p>Both <em>Generic</em> and <em>Implementation</em> process profiles are created  from <a class="reference internal" href="zcfg-reference.html#services-zcfg"><span>ZCFG</span></a> files and stored in the registry sub-directories
183according to their level (<em>Concept</em>, <em>Generic</em> or <em>Implementation</em>).</p>
184<p>To activate the registry, you have to add a <code class="docutils literal"><span class="pre">registry</span></code> key to the
185<code class="docutils literal"><span class="pre">[main]</span></code> section of your <code class="docutils literal"><span class="pre">main.cfg</span></code> file, and set its value to the
186directory path used to store the profile ZCFG files.</p>
187<div class="section" id="generic-process-profile">
188<h2>Generic Process Profile<a class="headerlink" href="#generic-process-profile" title="Permalink to this headline"></a></h2>
189<p>A Generic Process Profile is a ZCFG file located in the <code class="docutils literal"><span class="pre">generic</span></code>
190sub-directory, it defines <a class="reference external" href="zcfg-reference.html#main-metadata-information">main metadata information</a>, inputs and outputs
191name, basic metadata and multiplicity. It can make reference to a
192concept by defining a <code class="docutils literal"><span class="pre">concept</span></code> key in the <a class="reference external" href="zcfg-reference.html#main-metadata-information">main metadata
193information</a> part.</p>
194<p>You can find below the <cite>GO.zcfg</cite> file, a typical Generic Process
195Profile for Generic Geographic Operation, taking one InputPolygon
196input parameter and returning a result named Result, it make reference
197to the <code class="docutils literal"><span class="pre">GOC</span></code> concept:</p>
198<div class="highlight-none"><table class="highlighttable"><tr><td class="linenos"><div class="linenodiv"><pre> 1
199 2
200 3
201 4
202 5
203 6
204 7
205 8
206 9
20710
20811
20912
21013
21114
21215
21316
21417
21518
21619</pre></div></td><td class="code"><div class="highlight"><pre>[GO]
217 Title = Geographic Operation
218 Abstract = Geographic Operation on exactly one input, returning one output
219 concept = GOC
220 level = generic
221 statusSupported = true
222 storeSupported = true
223 &lt;DataInputs&gt;
224  [InputPolygon]
225   Title = the geographic data
226   Abstract = the geographic data to run geographipc operation
227   minOccurs = 1
228   maxOccurs = 1
229 &lt;/DataInputs&gt;
230 &lt;DataOutputs&gt;
231  [Result]
232   Title = the resulting data
233   Abstract = the resulting data after processing the operation
234 &lt;/DataOutputs&gt;
235</pre></div>
236</td></tr></table></div>
237<div class="admonition note">
238<p class="first admonition-title">Note</p>
239<p class="last">if you need to reference more than one concept, you should
240separate their names with a comma (ie. concept = GO,GB),</p>
241</div>
242</div>
243<div class="section" id="process-implementation-profile">
244<h2>Process Implementation Profile<a class="headerlink" href="#process-implementation-profile" title="Permalink to this headline"></a></h2>
245<p>A Process Implementation Profile is similar to a <a class="reference external" href="zcfg-reference.html">ZCFG file</a> located in the <cite>implementation</cite>
246sub-directory, it defines (or inherit from its parent) all the
247properties of a <a class="reference external" href="#generic-process-profile">Generic Process Profile</a>
248and specify <a class="reference external" href="zcfg-reference.html#type-of-data-nodes">Data Format</a>
249for both inputs and outputs. It can make reference to a concept by
250defining a <code class="docutils literal"><span class="pre">concept</span></code> key in the <a class="reference external" href="zcfg-reference.html#main-metadata-information">main metadata information</a> part.</p>
251<p>You can find below the <cite>VectorOperation.zcfg</cite> file, a typical Process
252Implementation Profile for Vector Geographic Operation, it inherit
253from the <a class="reference external" href="#generic-process-profile">GP generic profile</a>:</p>
254<div class="highlight-none"><table class="highlighttable"><tr><td class="linenos"><div class="linenodiv"><pre> 1
255 2
256 3
257 4
258 5
259 6
260 7
261 8
262 9
26310
26411
26512
26613
26714
26815
26916
27017
27118
27219
27320
27421
27522
27623
27724
27825
27926
28027
28128
28229
28330
28431
28532
28633
28734
28835
28936
29037
29138</pre></div></td><td class="code"><div class="highlight"><pre>[VectorOperation]
292 Title = Vector Geographic Operation
293 Abstract = Apply a Vector Geographic Operation on a features collection and return the resulting features collection
294 extend = GO
295 level = profile
296 &lt;DataInputs&gt;
297  [InputPolygon]
298   Title = the vector data
299   Abstract = the vector data to run geographic operation
300   &lt;ComplexData&gt;
301    &lt;Default&gt;
302     mimeType = text/xml
303     encoding = UTF-8
304     schema = http://fooa/gml/3.1.0/polygon.xsd
305    &lt;/Default&gt;
306    &lt;Supported&gt;
307     mimeType = application/json
308     encoding = UTF-8
309     extension = js
310    &lt;/Supported&gt;
311 &lt;/DataInputs&gt;
312 &lt;DataOutputs&gt;
313  [Result]
314   Title = the resulting data
315   Abstract = the resulting geographic data after processing the operation
316   &lt;ComplexData&gt;
317    &lt;Default&gt;
318     mimeType = text/xml
319     encoding = UTF-8
320     schema = http://fooa/gml/3.1.0/polygon.xsd
321    &lt;/Default&gt;
322    &lt;Supported&gt;
323     mimeType = application/json
324     encoding = UTF-8
325     extension = js
326    &lt;/Supported&gt;
327   &lt;/ComplexData&gt;
328 &lt;/DataOutputs&gt;
329</pre></div>
330</td></tr></table></div>
331</div>
332<div class="section" id="zcfg-inheritance">
333<h2>ZCFG inheritance<a class="headerlink" href="#zcfg-inheritance" title="Permalink to this headline"></a></h2>
334<p>For the ZCFG files at the service level, you can inherit the metadata
335from a Process Implementation Profile available in the registry. As
336before, you simply need to add a <code class="docutils literal"><span class="pre">extend</span></code> key refering the ZCFG you
337want to inherit from and a <code class="docutils literal"><span class="pre">level</span></code> key taking the <cite>ìmplementation`</cite>
338value to your main metadata informations.</p>
339<p>So, for example, the original <a class="reference external" href="http://www.zoo-project.org/trac/browser/trunk/zoo-project/zoo-services/ogr/base-vect-ops/cgi-env/ConvexHull.zcfg?rev=491">ConvexHull.zcfg</a>
340may be rewritten as:</p>
341<div class="highlight-none"><table class="highlighttable"><tr><td class="linenos"><div class="linenodiv"><pre>1
3422
3433
3444
3455
3466
3477</pre></div></td><td class="code"><div class="highlight"><pre>[ConvexHull]
348 Title = Compute convex hull.
349 Abstract = Return a feature collection that represents the convex hull of each geometry from the input collection.
350 serviceProvider = ogr_service.zo
351 serviceType = C
352 extend = VectorOperation
353 level = implementation
354</pre></div>
355</td></tr></table></div>
356<p>Now, suppose that your service is able to return the result in KML
357format, then you may write the following:</p>
358<div class="highlight-none"><table class="highlighttable"><tr><td class="linenos"><div class="linenodiv"><pre> 1
359 2
360 3
361 4
362 5
363 6
364 7
365 8
366 9
36710
36811
36912
37013
37114</pre></div></td><td class="code"><div class="highlight"><pre>[ConvexHull]
372 Title = Compute convex hull.
373 Abstract = Return a feature collection that represents the convex hull of each geometry from the input collection.
374 serviceProvider = ogr_service.zo
375 serviceType = C
376 extend = VectorOperation
377 level = implementation
378 &lt;DataOutputs&gt;
379  [Result]
380     &lt;Supported&gt;
381      mimeType = application/vnd.google-earth.kml+xml
382      encoding = utf-8
383     &lt;/Supported&gt;
384 &lt;/DataOutputs&gt;
385</pre></div>
386</td></tr></table></div>
387</div>
388</div>
389
390
391          </div>
392          <footer>
393 
394    <div class="rst-footer-buttons" role="navigation" aria-label="footer navigation">
395     
396        <a href="howtos.html" class="btn btn-neutral float-right" title="Create your own ZOO-Services">Next <span class="fa fa-arrow-circle-right"></span></a>
397     
398     
399        <a href="zcfg-reference.html" class="btn btn-neutral" title="ZOO-Service configuration file"><span class="fa fa-arrow-circle-left"></span> Previous</a>
400     
401    </div>
402 
403
404  <hr/>
405  <div class="pfoot">
406  <div role="contentinfo">
407    <p>
408        &copy; Copyright 2009-2015, ZOO-Project team.
409    </p>
410  </div>
411  Built with <a href="http://sphinx-doc.org/">Sphinx</a> using a <a href="https://github.com/snide/sphinx_rtd_theme">theme</a> inspired by <a href="https://readthedocs.org">Read the Docs</a>.
412</div>
413</footer>
414
415        </div>
416      </div>
417
418    </section>
419
420  </div>
421 
422
423
424 
425
426    <script type="text/javascript">
427        var DOCUMENTATION_OPTIONS = {
428            URL_ROOT:'../',
429            VERSION:'1.4a0',
430            COLLAPSE_INDEX:false,
431            FILE_SUFFIX:'.html',
432            HAS_SOURCE:  true
433        };
434    </script>
435      <script type="text/javascript" src="../_static/jquery.js"></script>
436      <script type="text/javascript" src="../_static/underscore.js"></script>
437      <script type="text/javascript" src="../_static/doctools.js"></script>
438
439 
440
441 
442 
443    <script type="text/javascript" src="../_static/js/theme.js"></script>
444 
445
446 
447 
448  <script type="text/javascript">
449      jQuery(function () {
450          SphinxRtdTheme.StickyNav.enable();
451      });
452  </script>
453   
454
455</body>
456</html>
Note: See TracBrowser for help on using the repository browser.

Search

Context Navigation

ZOO Sponsors

http://www.zoo-project.org/trac/chrome/site/img/geolabs-logo.pnghttp://www.zoo-project.org/trac/chrome/site/img/neogeo-logo.png http://www.zoo-project.org/trac/chrome/site/img/apptech-logo.png http://www.zoo-project.org/trac/chrome/site/img/3liz-logo.png http://www.zoo-project.org/trac/chrome/site/img/gateway-logo.png

Become a sponsor !

Knowledge partners

http://www.zoo-project.org/trac/chrome/site/img/ocu-logo.png http://www.zoo-project.org/trac/chrome/site/img/gucas-logo.png http://www.zoo-project.org/trac/chrome/site/img/polimi-logo.png http://www.zoo-project.org/trac/chrome/site/img/fem-logo.png http://www.zoo-project.org/trac/chrome/site/img/supsi-logo.png http://www.zoo-project.org/trac/chrome/site/img/cumtb-logo.png

Become a knowledge partner

Related links

http://zoo-project.org/img/ogclogo.png http://zoo-project.org/img/osgeologo.png