2016-05-04 13 views
1

Webリンクを使用してWPSでGeoJSONを返そうとしているGeoserverがありますが、わかりません。Geoserver WPS実行依頼

Geoserverウェブサイトのチュートリアルでは、カールを行うと記載されています。 GeoserverはWPSビルダーのデモがあり、必要なものを返すため、これを行うことができると確信しています。私はリーフレットを使って返されたWebリンクを視覚化していますので、アップロードされたファイルを指すのではなく、動的に引っ張るのがいいと思います。

これは私が持っているものです。どんな助けでも大歓迎です。

http://localhost:8081/geoserver/ows?service=wps&version=1.0.0&request=Execute&identifier=vec:InclusionFeatureCollection&dataInputs=Layer=https://rawgit.com/pq1/772-Final/master/housesMetro.geojson&Layer=https://rawgit.com/pq1/772-Final/master/housesSchoolDistricts.geojson&Output=application/json 
+0

どのような応答が得られますか? –

+0

これは私が得る応答です。 不明なデータ入力が'レイヤー' pq1

答えて

0

それはあなたが(Windowsを使用している場合、\なしに、明らかにすべて1行で)

curl -v -u admin:geoserver -X POST -H "Content-type: xml" \ 
-d @test.xml \ 
http://localhost:4080/geoserver/wps\?request\=Execute\&service\=WPS\&version\=1.0.0 

のようなPOSTリクエストを使用する必要があるのか​​もしれtest.xmlが含まれている私のために

作品:

<?xml version="1.0" encoding="UTF-8"?><wps:Execute version="1.0.0" service="WPS" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns="http://www.opengis.net/wps/1.0.0" xmlns:wfs="http://www.opengis.net/wfs" xmlns:wps="http://www.opengis.net/wps/1.0.0" xmlns:ows="http://www.opengis.net/ows/1.1" xmlns:gml="http://www.opengis.net/gml" xmlns:ogc="http://www.opengis.net/ogc" xmlns:wcs="http://www.opengis.net/wcs/1.1.1" xmlns:xlink="http://www.w3.org/1999/xlink" xsi:schemaLocation="http://www.opengis.net/wps/1.0.0 http://schemas.opengis.net/wps/1.0.0/wpsAll.xsd"> 
    <ows:Identifier>vec:InclusionFeatureCollection</ows:Identifier> 
    <wps:DataInputs> 
    <wps:Input> 
     <ows:Identifier>first</ows:Identifier> 
     <wps:Reference mimeType="text/xml" xlink:href="http://geoserver/wfs" method="POST"> 
     <wps:Body> 
      <wfs:GetFeature service="WFS" version="1.0.0" outputFormat="GML2" xmlns:sf="http://www.openplans.org/spearfish"> 
      <wfs:Query typeName="sf:bugsites"/> 
      </wfs:GetFeature> 
     </wps:Body> 
     </wps:Reference> 
    </wps:Input> 
    <wps:Input> 
     <ows:Identifier>second</ows:Identifier> 
     <wps:Reference mimeType="text/xml" xlink:href="http://geoserver/wfs" method="POST"> 
     <wps:Body> 
      <wfs:GetFeature service="WFS" version="1.0.0" outputFormat="GML2" xmlns:sf="http://www.openplans.org/spearfish"> 
      <wfs:Query typeName="sf:restricted"/> 
      </wfs:GetFeature> 
     </wps:Body> 
     </wps:Reference> 
    </wps:Input> 
    </wps:DataInputs> 
    <wps:ResponseForm> 
    <wps:RawDataOutput mimeType="application/json"> 
     <ows:Identifier>result</ows:Identifier> 
    </wps:RawDataOutput> 
    </wps:ResponseForm> 
</wps:Execute> 
関連する問題