This commit is contained in:
Gianpaolo Coro 2015-07-22 14:58:56 +00:00
parent 7bfb00db4f
commit e9021c3a91
4 changed files with 182 additions and 0 deletions

View File

@ -0,0 +1,21 @@
package=package org.gcube.dataanalysis.wps.statisticalmanager.synchserver.mappedclasses.#PACKAGE#;
import=import java.io.File;\nimport java.net.URL;\nimport java.io.IOException;\nimport java.io.InputStream;\nimport java.util.LinkedHashMap;\nimport java.io.StringWriter;\nimport org.apache.commons.io.IOUtils;\nimport org.apache.xmlbeans.XmlObject;\nimport org.gcube.dataanalysis.wps.statisticalmanager.synchserver.bindings.*;\nimport org.n52.wps.algorithm.annotation.*;\nimport org.n52.wps.io.data.*;\nimport org.n52.wps.io.data.binding.complex.*;\nimport org.n52.wps.io.data.binding.literal.*;\nimport org.n52.wps.server.*;import org.gcube.dataanalysis.wps.statisticalmanager.synchserver.mapping.AbstractEcologicalEngineMapper;import org.n52.wps.server.*;import org.gcube.dataanalysis.wps.statisticalmanager.synchserver.mappedclasses.*;
description=@Algorithm(statusSupported=false, title="#TITLE#", abstrakt="#ABSTRACT#", identifier="org.gcube.dataanalysis.wps.statisticalmanager.synchserver.mappedclasses.#PACKAGE#.#CLASSNAME#", version = "1.1.0")
class_definition=public class #CLASSNAME# extends AbstractEcologicalEngineMapper implements #INTERFACE#{
class_closure=@Execute public void run() throws Exception { super.run(); } }
scopeInput=@LiteralDataInput(abstrakt="The D4Science VRE scope in which the algorithm will be executed", defaultValue="/d4science.research-infrastructures.eu/gCubeApps/BiodiversityLab", title="scope", maxOccurs=1, minOccurs=1, identifier = "scope", binding = LiteralStringBinding.class) public void setScope(String data) {inputs.put(\"scope",data);}
usernameInput=@LiteralDataInput(abstrakt="An identifier of the user who executes the computation", defaultValue="wpssynch.statistical", title="User name", maxOccurs=1, minOccurs=1, identifier = "user.name", binding = LiteralStringBinding.class) public void setUserName(String data) {inputs.put(\"user.name\",data);}
stringInput=@LiteralDataInput(abstrakt="#ABSTRACT#", defaultValue="#DEFAULT#", title="#TITLE#", identifier = "#ID#", maxOccurs=1, minOccurs=1, binding = LiteralStringBinding.class) public void set#IDMETHOD#(String data) {inputs.put(\"#ID#\",data);}
enumeratedInput=@LiteralDataInput(abstrakt="#ABSTRACT#", allowedValues= {#ALLOWED#}, defaultValue="#DEFAULT#", title="#TITLE#", identifier = "#ID#", maxOccurs=1, minOccurs=1, binding = LiteralStringBinding.class) public void set#IDMETHOD#(String data) {inputs.put(\"#ID#\",data);}
doubleInput=@LiteralDataInput(abstrakt="#ABSTRACT#", defaultValue="#DEFAULT#", title="#TITLE#", identifier = "#ID#", maxOccurs=1, minOccurs=1, binding = LiteralDoubleBinding.class) public void set#IDMETHOD#(Double data) {inputs.put(\"#ID#\",""+data);}
integerInput=@LiteralDataInput(abstrakt="#ABSTRACT#", defaultValue="#DEFAULT#", title="#TITLE#", identifier = "#ID#", maxOccurs=1, minOccurs=1, binding = LiteralIntBinding.class) public void set#IDMETHOD#(Integer data) {inputs.put(\"#ID#\",""+data);}
booleanInput=@LiteralDataInput(abstrakt="#ABSTRACT#", defaultValue="#DEFAULT#", allowedValues= {"true","false"}, title="#TITLE#", identifier = "#ID#", maxOccurs=1, minOccurs=1,binding = LiteralBooleanBinding.class) public void set#IDMETHOD#(Boolean data) {inputs.put(\"#ID#\",""+data);}
csvFileInput=@ComplexDataInput(abstrakt="#ABSTRACT#", title="#TITLE#", maxOccurs=1, minOccurs=1, identifier = "#ID#", binding = GenericFileDataBinding.class) public void set#IDMETHOD#(GenericFileData file) {inputs.put(\"#ID#\",file);}
gislinkInput=@ComplexDataInput(abstrakt="#ABSTRACT#", title="#TITLE#", maxOccurs=1, minOccurs=1, identifier = "#ID#", binding = GisLinkDataInputBinding.class) public void set#IDMETHOD#(GenericFileData file) {inputs.put(\"#ID#\",file);}
d4scienceFileInput=@ComplexDataInput(abstrakt="#ABSTRACT#", title="#TITLE#", maxOccurs=1, minOccurs=1, identifier = "#ID#", binding = D4ScienceDataInputBinding.class) public void set#IDMETHOD#(GenericFileData file) {inputs.put(\"#ID#\",file);}
d4scienceFileOutput=@ComplexDataOutput(abstrakt="#ABSTRACT#", title="#TITLE#", identifier = "#ID#", binding = D4ScienceFileDataBinding.class) public GenericFileData get#IDMETHOD#() {URL url=null;try {url = new URL((String) outputs.get("#ID#")); return new GenericFileData(url.openStream(),"application/d4science");} catch (Exception e) {e.printStackTrace();return null;}}
pngFileOutput=@ComplexDataOutput(abstrakt="#ABSTRACT#", title="#TITLE#", identifier = "#ID#", binding = PngFileDataBinding.class) public GenericFileData get#IDMETHOD#() {URL url=null;try {url = new URL((String) outputs.get("#ID#")); return new GenericFileData(url.openStream(),"image/png");} catch (Exception e) {e.printStackTrace();return null;}}
csvFileOutput=@ComplexDataOutput(abstrakt="#ABSTRACT#", title="#TITLE#", identifier = "#ID#", binding = CsvFileDataBinding.class) public GenericFileData get#IDMETHOD#() {URL url=null;try {url = new URL((String) outputs.get("#ID#")); return new GenericFileData(url.openStream(),"text/csv");} catch (Exception e) {e.printStackTrace();return null;}}
gisLinkOutput=@ComplexDataOutput(abstrakt="#ABSTRACT#", title="#TITLE#", identifier = "#ID#", binding = GisLinkDataBinding.class) public GenericFileData get#IDMETHOD#() {URL url=null;try {url = new URL((String) outputs.get("#ID#")); return new GenericFileData(url.openStream(),"application/geotiff");} catch (Exception e) {e.printStackTrace();return null;}}
stringOutput=@LiteralDataOutput(abstrakt="#ABSTRACT#", title="#TITLE#", identifier = "#ID#", binding = LiteralStringBinding.class) public String get#IDMETHOD#() {return (String) outputs.get("#ID#");}
optionalOutput=@ComplexDataOutput(abstrakt="Output that is not predetermined", title="NonDeterministicOutput", identifier = "non_deterministic_output", binding = GenericXMLDataBinding.class)\n public XmlObject getNon_deterministic_output() {return (XmlObject) outputs.get("non_deterministic_output");}

View File

@ -0,0 +1,3 @@
maxcomputations=4
saveond4sstorage=true
simulationMode=true

View File

@ -0,0 +1,80 @@
<?xml version="1.0" encoding="UTF-8"?>
<wps:Capabilities service="WPS" version="1.0.0"
xml:lang="en-US" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:wps="http://www.opengis.net/wps/1.0.0"
xmlns:ows="http://www.opengis.net/ows/1.1" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
xsi:schemaLocation="http://www.opengis.net/wps/1.0.0 http://schemas.opengis.net/wps/1.0.0/wpsGetCapabilities_response.xsd"
updateSequence="1">
<ows:ServiceIdentification>
<ows:Title>D4Science WPS Service for synchronous executions</ows:Title>
<ows:Abstract>Service based on the 52°North implementation of WPS 1.0.0</ows:Abstract>
<ows:Keywords>
<ows:Keyword>WPS</ows:Keyword>
<ows:Keyword>geospatial</ows:Keyword>
<ows:Keyword>geoprocessing</ows:Keyword>
<ows:Keyword>D4Science</ows:Keyword>
</ows:Keywords>
<ows:ServiceType>WPS</ows:ServiceType>
<ows:ServiceTypeVersion>1.0.0</ows:ServiceTypeVersion>
<ows:Fees>NONE</ows:Fees>
<ows:AccessConstraints>NONE</ows:AccessConstraints>
</ows:ServiceIdentification>
<ows:ServiceProvider>
<ows:ProviderName>National Research Council of Italy</ows:ProviderName>
<ows:ProviderSite xlink:href="www.d4science.org" />
<ows:ServiceContact>
<ows:IndividualName>Gianpaolo Coro</ows:IndividualName>
<ows:PositionName>Researcher</ows:PositionName>
<ows:ContactInfo>
<ows:Phone>
<ows:Voice>+39 050 621 2978</ows:Voice>
</ows:Phone>
<ows:Address>
<ows:DeliveryPoint>Via Moruzzi 1</ows:DeliveryPoint>
<ows:City>Pisa</ows:City>
<ows:AdministrativeArea>Istituto di Scienza e Tecnologie dell'Informazione A. Faedo</ows:AdministrativeArea>
<ows:PostalCode>56124</ows:PostalCode>
<ows:Country>Italy</ows:Country>
<ows:ElectronicMailAddress>gianpaolo.coro@isti.cnr.it</ows:ElectronicMailAddress>
</ows:Address>
</ows:ContactInfo>
</ows:ServiceContact>
</ows:ServiceProvider>
<ows:OperationsMetadata>
<ows:Operation name="GetCapabilities">
<ows:DCP>
<ows:HTTP>
<ows:Get xlink:href="http://#HOST#:#PORT#/wps/WebProcessingService?" />
<ows:Post xlink:href="http://#HOST#:#PORT#/wps/WebProcessingService?" />
</ows:HTTP>
</ows:DCP>
</ows:Operation>
<ows:Operation name="DescribeProcess">
<ows:DCP>
<ows:HTTP>
<ows:Get xlink:href="http://#HOST#:#PORT#/wps/WebProcessingService?" />
<ows:Post xlink:href="http://#HOST#:#PORT#/wps/WebProcessingService?" />
</ows:HTTP>
</ows:DCP>
</ows:Operation>
<ows:Operation name="Execute">
<ows:DCP>
<ows:HTTP>
<ows:Get xlink:href="http://#HOST#:#PORT#/wps/WebProcessingService?" />
<ows:Post xlink:href="http://#HOST#:#PORT#/wps/WebProcessingService?" />
</ows:HTTP>
</ows:DCP>
</ows:Operation>
</ows:OperationsMetadata>
<wps:ProcessOfferings>
#PROCESSES#
</wps:ProcessOfferings>
<wps:Languages>
<wps:Default>
<ows:Language>en-GB</ows:Language>
</wps:Default>
<wps:Supported>
<ows:Language>en-GB</ows:Language>
</wps:Supported>
</wps:Languages>
</wps:Capabilities>

View File

@ -0,0 +1,78 @@
<?xml version="1.0" encoding="UTF-8"?>
<WPSConfiguration xmlns="http://n52.org/wps">
<Datahandlers>
<ParserList>
<Parser name="WCPSQueryParser" className="org.n52.wps.io.datahandler.parser.WCPSQueryParser" active="true">
<Format mimetype="text/plain" schema="http://schemas.opengis.net/wcps/1.0/wcpsAll.xsd"/>
</Parser>
<Parser name="WKTParser" className="org.n52.wps.io.datahandler.parser.WKTParser" active="true">
<Format mimetype="application/wkt"/>
</Parser>
<Parser name="GenericXMLDataParser" className="org.n52.wps.io.datahandler.parser.GenericXMLDataParser" active="true">
<Format mimetype="text/xml; subtype=gml/2.1.2" schema="http://schemas.opengis.net/gml/2.1.2/feature.xsd"/>
<Format mimetype="text/xml"/>
</Parser>
<Parser name="GenericFileParser" className="org.n52.wps.io.datahandler.parser.GenericFileParser" active="true">
<Format mimetype="text/csv"/>
<Format mimetype="text/plain"/>
</Parser>
<Parser name="GisLinkParser" className="org.gcube.dataanalysis.wps.statisticalmanager.synchserver.bindings.GisLinkParser" active="true">
<Format mimetype="application/geotiff"/>
<Format mimetype="application/wcs"/>
<Format mimetype="application/asc"/>
<Format mimetype="text/plain"/>
<Format mimetype="application/wfs"/>
<Format mimetype="application/opendap"/>
</Parser>
</ParserList>
<GeneratorList>
<Generator name="WKTGenerator" className="org.n52.wps.io.datahandler.generator.WKTGenerator" active="true">
<Format mimetype="application/wkt"/>
</Generator>
<Generator name="GenericXMLDataGenerator" className="org.n52.wps.io.datahandler.generator.GenericXMLDataGenerator" active="true">
<Format mimetype="text/xml; subtype=gml/2.1.2" schema="http://schemas.opengis.net/gml/2.1.2/feature.xsd"/>
</Generator>
<Generator name="GenericFileGenerator" className="org.n52.wps.io.datahandler.generator.GenericFileGenerator" active="true">
<Format mimetype="text/plain"/>
</Generator>
<Generator name="PngFileGenerator" className="org.gcube.dataanalysis.wps.statisticalmanager.synchserver.bindings.PngFileGenerator" active="true">
<Format mimetype="image/png"/>
</Generator>
<Generator name="GifFileGenerator" className="org.gcube.dataanalysis.wps.statisticalmanager.synchserver.bindings.GifFileGenerator" active="true">
<Format mimetype="image/gif"/>
</Generator>
<Generator name="D4ScienceFileGenerator" className="org.gcube.dataanalysis.wps.statisticalmanager.synchserver.bindings.D4ScienceFileGenerator" active="true">
<Format mimetype="application/d4science"/>
</Generator>
<Generator name="CsvFileGenerator" className="org.gcube.dataanalysis.wps.statisticalmanager.synchserver.bindings.CsvFileGenerator" active="true">
<Format mimetype="text/csv"/>
</Generator>
<Generator name="GisLinkGenerator" className="org.gcube.dataanalysis.wps.statisticalmanager.synchserver.bindings.GisLinkGenerator" active="true">
<Format mimetype="application/wms"/>
</Generator>
</GeneratorList>
</Datahandlers>
<AlgorithmRepositoryList>
<Repository name="LocalAlgorithmRepository" className="org.n52.wps.server.LocalAlgorithmRepository" active="true">
<Property name="Algorithm" active="true">org.gcube.dataanalysis.wps.statisticalmanager.synchserver.mappedclasses.BIONYM_LOCAL</Property>
<Property name="Algorithm" active="true">org.gcube.dataanalysis.wps.statisticalmanager.synchserver.mappedclasses.BIOCLIMATE_HCAF</Property>
<Property name="Algorithm" active="true">org.gcube.dataanalysis.wps.statisticalmanager.synchserver.mappedclasses.PRESENCE_CELLS_GENERATION</Property>
<Property name="Algorithm" active="true">org.gcube.dataanalysis.wps.statisticalmanager.synchserver.mappedclasses.HCAF_INTERPOLATION</Property>
<Property name="Algorithm" active="true">org.n52.wps.demo.GPDemoXML</Property>
<Property name="Algorithm" active="true">org.n52.wps.demo.TestIO</Property>
<Property name="Algorithm" active="true">org.n52.wps.server.algorithm.JTSConvexHullAlgorithm</Property>
<Property name="Algorithm" active="true">org.n52.wps.server.algorithm.test.DummyTestClass</Property>
<Property name="Algorithm" active="true">org.n52.wps.server.algorithm.test.EchoProcess</Property>
<Property name="Algorithm" active="true">org.n52.wps.server.algorithm.test.LongRunningDummyTestClass</Property>
<Property name="Algorithm" active="true">org.n52.wps.server.algorithm.test.MultiReferenceBinaryInputAlgorithm</Property>
<Property name="Algorithm" active="true">org.n52.wps.server.algorithm.test.MultiReferenceInputAlgorithm</Property>
<Property name="Algorithm" active="true">org.n52.wps.server.algorithm.test.MultipleComplexInAndOutputsDummyTestClass</Property>
</Repository>
<Repository name="UploadedAlgorithmRepository" className="org.n52.wps.server.UploadedAlgorithmRepository" active="false"/>
<Repository name="ServiceLoaderAlgorithmRepository" className="org.n52.wps.server.ServiceLoaderAlgorithmRepository" active="true"/>
</AlgorithmRepositoryList>
<RemoteRepositoryList/>
<Server protocol="http" hostname="localhost" hostport="8080" includeDataInputsInResponse="false" computationTimeoutMilliSeconds="5" cacheCapabilites="false" webappPath="wps" repoReloadInterval="0.0" minPoolSize="10" maxPoolSize="20" keepAliveSeconds="1000" maxQueuedTasks="100">
<Database/>
</Server>
</WPSConfiguration>