comparison doc/config-manual/model_of_transitions.tex @ 908:babeef4f8480

Added description fpr Configuration of Products, States and Transitions doc/trunk@1042 c6561f87-3c4e-4783-a992-168aeb5c3f6f
author Tim Englich <tim.englich@intevation.de>
date Mon, 03 May 2010 12:35:48 +0000
parents 29a675796e76
children fcde68463722
comparison
equal deleted inserted replaced
907:29a675796e76 908:babeef4f8480
1 \section{Model of transitions} 1 \section{Model of transitions}
2 \subsection{General principle of model of transitions} 2 \subsection{General principle of model of transitions}
3 - FIS -> product -> transitions in data model 3 - FIS -> product -> transitions in data model
4 The configuration of the provided FIS are devided in three parts. 4
5 5 It is possible to configure the GNV in many ways.
6 * Configuration of the Artifactfactories which represents the FIS. 6 It is possible to add or remove FIS, add or remove Products from a FIS or
7 * Configuration of main Artifacts which will be instantiated if an 7 to manipulate the steps which must be gone until a product can be create
8 a diagramm or generate an CSV-Export.
9
10 The configuration of the provided FIS are devided in three main parts.
11
12 \begin{itemize}
13 \item Configuration of the Artifactfactories which represents the FIS.
14 \item Configuration of main Artifacts which will be instantiated if an
8 Artifactfactory was called. 15 Artifactfactory was called.
9 * Configuration of the different Artifacts which provides Products which can be 16 \item Configuration of the different Artifacts which provides Products which can be
10 served by the FIS. 17 served by the FIS.
18 \end{itemize}
11 19
12 \subsubsection{Configuration of ArtifactFactories} 20 \subsubsection{Configuration of ArtifactFactories}
13 The Point of Enty into the system is to configure an Artifactfactory. 21 The Point of Enty into the system is to configure an Artifactfactory.
14 Each Artifactfactory represents one FIS. 22 Each Artifactfactory represents one FIS.
15 It is possible to configure several Artifactfactories. 23 It is possible to configure several Artifactfactories.
16 The Artifactfactories will be vonfigured in the Section 24 The Artifactfactories will be configured in the Section
17 /artifact-database/artifact-factories of the Configurationfile. 25 /artifact-database/artifact-factories of the Configurationfile.
18 26
19 \begin{lstlisting} 27 \begin{lstlisting}
20 <artifact-factory name='fis\_marnet' 28 <artifact-factory name='fis\_marnet'
21 description='Factory to create an artifact to be used with the FIS NEWFISNAME' 29 description='Factory to create an artifact to be used with the FIS NEWFISNAME'
24 de.intevation.gnv.artifacts.GNVProductArtifactFactory 32 de.intevation.gnv.artifacts.GNVProductArtifactFactory
25 </artifact-factory> 33 </artifact-factory>
26 \end{lstlisting} 34 \end{lstlisting}
27 35
28 At this moment the following Attributes of an Artifact-Factory are configurabel. 36 At this moment the following Attributes of an Artifact-Factory are configurabel.
29 * name: The Name of the Artifact. Must be unique in one Artifact-Server 37 \begin{itemize}
30 * description: Short description which Job the Artifactfactory has to do. 38 \item name: The Name of the Artifact. Must be unique in one Artifact-Server
31 * ttl: The Time to Live: The Time using Milliseconds an Artifact created by this 39 \item description: Short description which Job the Artifactfactory has to do.
32 factory can live without any Userinteraction. 40 \item ttl: The Time to Live: The Time using Milliseconds an Artifact, created using this
33 * artifact: The Name of the Class of the Artifact which should be created. 41 factory, can live without any Userinteraction.
42 \item artifact: The Name of the Class of the Artifact which should be created.
43 \end{itemize}
34 44
35 // TODO: List of Artifacts which currently used in this Configuration? 45 // TODO: List of Artifacts which currently used in this Configuration?
36 46
37 \subsubsection{Configuration of main Artifact} 47 \subsubsection{Configuration of main Artifact}
38 To each Artifact-Factory it is necessary to configure one Artifact which will be 48 For each Artifact-Factory it is necessary to configure one Artifact which will be
39 created from the Factory. 49 created using the Factory.
40 This Artifact is the representation of the specific FIS. 50 This Artifact is the representation of the specific FIS.
41 It contains the Configuration which product will be serverd for ths FIS. 51 It contains the Configuration which products will be serverd for ths FIS.
42 52
43 The Artifacts are configured in the Section /artifact-database/artifacts of 53 The Artifacts are configured in the Section /artifact-database/artifacts of
44 the Configurationfile. 54 the Configurationfile.
45 55
46 \begin{lstlisting} 56 \begin{lstlisting}
76 value="fis\_marnet"/> 86 value="fis\_marnet"/>
77 </parameters> 87 </parameters>
78 </product> 88 </product>
79 \end{lstlisting} 89 \end{lstlisting}
80 90
81 Each Product is represented by an Artifact. To create this Artifact we have to 91 Each Product is also represented by an Artifact. To create this Artifact we have to
82 use an Artifact-Factory which is configured in each product 92 use an Artifact-Factory which is configured in each product
83 (/product/artifact-factory). 93 (/product/artifact-factory).
84 94
85 Each Product can have several parameters /product/parameters/parameters. 95 Each Product can have several parameters /product/parameters/parameters.
86 The Parameter named sourceid and fisname are required Parameters. 96 The Parameter named sourceid and fisname are required Parameters.
90 The Parameter sourceid contains the key to identify the FIS in the 100 The Parameter sourceid contains the key to identify the FIS in the
91 DataWareHouse. (MEDIAN.SOURCEINFO) 101 DataWareHouse. (MEDIAN.SOURCEINFO)
92 102
93 103
94 \subsubsection{Configuration of the Product-Artifacts} 104 \subsubsection{Configuration of the Product-Artifacts}
105 The Products of the different FIS are also modeled as Artifact-Objects.
106 The different Products which are currently avaliable are stored in separate
107 Files in the Folder project.
108
109 In those Files the Workflow of each product is configured. Each step which is
110 required to model a new Diagramm is represented using a state in the
111 Configuration-File.
112
113 To move between those States it is required to model Transitions which define
114 between which States it is possible to move and which conditions must be
115 fulfilled.
116
117 The Last step is called OutputState. This State is responsible to generate the
118 output for the different Formats which can be served from the Product (Diagramm,
119 CSV, ODV, WMS,...).
120
95 \paragraph{States} 121 \paragraph{States}
122 A state is one Step which is required to fetch the Data for generating e.g. an
123 Diagramm.
124
125 For example in each Product it is Possible to choose one or more Parameters.
126
127 To configure a State you have to use a XML-Fragment as shown below:
128
129 \begin{lstlisting}
130 <state id="timeseries_parameter" description="timeseries_parameter" state="de.intevation.gnv.state.DefaultState">
131 <queryID>timeseries_parameter</queryID>
132 <dataname>parameterid</dataname>
133 <data-multiselect>true</data-multiselect>
134 <inputvalues>
135 <inputvalue name="featureid" type="Integer" multiselect="false"/>
136 <inputvalue name="fisname" type="String" multiselect="false" usedinquery="0"/>
137 <inputvalue name="parameterid" type="Integer" multiselect="true" usedinquery="0"/>
138 </inputvalues>
139 </state>
140 \end{lstlisting}
141
142 At this moment the following Attributes of an Artifact-Factory are configurabel.
143 \begin{itemize}
144 \item id: The Name of the Artifact. Must be unique in one Artifact-Server
145 \item description: Short description which Job the Artifactfactory has to do.
146 \item queryID: The ID of the Query which should be used to fetch the Data
147 displayed in this state. //TODO: Reference to queries.properties
148 \item dataname: The ID of the Data which will be displaied in this State.
149 The ID will be use to localize the description of the Data.
150 \item data-multiselect: true it is possible to select 1 or more Items.
151 false ist is possible to select only one Item.
152 \item inputvalues: The Values which can be "feed" //TODO: How to explain this
153 to this State.
154 \end{itemize}
155
156
96 \paragraph{Transitions} 157 \paragraph{Transitions}
158
159 To move between two States it is necessary to configure dependencies between
160 the different States.
161 This dependencies are called. Transitions.
162
163 There are different Kind of Transitions which can be used.
164 \begin{itemize}
165 \item Transitions which only link two States
166 \item Transition which link two States with a aditional Condition.
167 (e.g. If a region was selected in the Regionfilter or not )
168 \end{itemize}
169
170 The listing below shows a Transition with an additional Condition.
171 \begin{lstlisting}
172 <transition transition="de.intevation.gnv.transition.ValueCompareTransition">
173 <from state="timeseries_area"/>
174 <to state="timeseries_without_geom"/>
175 <condition inputvalue="areaid" value="n/n" operator="equal"/>
176 </transition>
177 \end{lstlisting}
178
179 \begin{itemize}
180 \item from: The ID of the State which you have to come from
181 \item to: The ID of the State which can be reached.
182 \item condition: The Condition which have to be fulfilled.
183 \end{itemize}
184
97 \paragraph{Outputstate} 185 \paragraph{Outputstate}
98 186
99 187
100 \subsection{Adding a new FIS} 188 \subsection{Adding a new FIS}
101 In this Section it will explained which steps has to be done to integrate a new 189 In this Section it will be explained which steps has to be done to integrate a
102 FIS into the Artifact-Server. 190 new FIS into the Artifact-Server. This will be done using the Configuration for
103 This will be done using the Configuration for an FIS which use data from 191 an FIS which use data from MEDIAN.TIMESERIES Section of the DataWareHouse e.g.
104 MEDIAN.TIMESERIES Section of the DataWareHouse e.g. MARNET or STAUN 192 MARNET or STAUN
105 193
106 Pay attention that for publishing the Changes to the Artifact-Server you will 194 Pay attention that for publishing the Changes to the Artifact-Server you will
107 have to restart it. 195 have to restart it.
108 196
109 \subsubsection{Adding a new Artifactfactory} 197 \subsubsection{Adding a new Artifactfactory}
181 </product> 269 </product>
182 </products> 270 </products>
183 </artifact> 271 </artifact>
184 \end{lstlisting} 272 \end{lstlisting}
185 273
186 In this XML Fragment you have to replace the placeholders NEWFISNAME as before 274 In this XML-Fragment you have to replace the placeholders NEWFISNAME as before
187 and VALUEOFSOURCEID with the value for the new FIS as defined in the Table 275 and VALUEOFSOURCEID with the value for the new FIS as defined in the Table
188 MEDIAN.SOURCEINFO. 276 MEDIAN.SOURCEINFO.
189 277
190 \subsubsection{Putting SourceID to specific Artifact} 278 \subsubsection{Putting SourceID to specific Artifact}
191 \subsection{Adding a new Product} 279 \subsection{Adding a new Product}
192 To add a new Product to the System it is necessary that the required 280 To add a new Product to the System it is necessary that the required
193 Artifactrepresentation is Implemented in the SourceCode. 281 Artifactrepresentation is Implemented in the SourceCode.
194 Without doing that step it is not possible to create a new Product. 282 Without doing that step it is not possible to create a new Product.
195 283
196 All Products are configured in separate Files that will be included into the 284 All Products are configured in separate Files that will be included into the
197 Mainconfiguration using Xlink-references. 285 Mainconfiguration using Xlink-References.
198 286
199 First Step is to create a new File in the Folder products and there in the 287 First Step is to create a new File in the Folder products and there in the
200 subfolder where the Product belongs to (timeseries,verticalprofile, 288 subfolder where the Product belongs to (timeseries,verticalprofile,
201 horizontalprofile,horizontalcrosssection,layer,...) 289 horizontalprofile,horizontalcrosssection,layer,...)
202 290

http://dive4elements.wald.intevation.org