Stephen,<br><br>Do we intend to reimplement parsing each response formats in mapserver, or we would rather extend existing implementations (ie. in OGR) to support fetching data from an HTTP connection?<br><br>The are existing implementations like GeoJSON (see <a href="http://www.gdal.org/ogr/drv_geojson.html">http://www.gdal.org/ogr/drv_geojson.html</a>) already support this use case. In this regard the only issue would be to customize the url (OGR connection) with some dynamic information, or do we have further requirements?<br>
<br><br>Best regards,<br><br>Tamas<br><br><br><div style="visibility: hidden; display: inline;" id="avg_ls_inline_popup"></div><style type="text/css">#avg_ls_inline_popup {  position:absolute;  z-index:9999;  padding: 0px 0px;  margin-left: 0px;  margin-top: 0px;  width: 240px;  overflow: hidden;  word-wrap: break-word;  color: black;  font-size: 10px;  text-align: left;  line-height: 13px;}</style><br>
<div class="gmail_quote">2010/7/27 Stephen Woodbridge <span dir="ltr">&lt;<a href="mailto:woodbri@swoodbridge.com">woodbri@swoodbridge.com</a>&gt;</span><br><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
Hi Mapserver Devs,<br>
<br>
I am interested in getting input and interest in doing some possibly or partially funded development of the following.<br>
<br>
USE CASE:<br>
<br>
User has spatial data stored in a proprietary system, database, search engine, whatever. They want to pull that data into mapserver for rendering, querying, etc like any other data layer. They can access that data via PHP and possibly other tools. They would like to have a generic HTTP data provider LAYER added to mapserver where mapserver would make URL requests based on some defined template URL and the URL would return data in some  well know format like GeoJSON, GPX, KML, others.<br>

<br>
The LAYER definition would look something like:<br>
<br>
LAYER<br>
  NAME &quot;mylines&quot;<br>
  CONNECTIONTYPE HTTP<br>
  CONNECTIONFORMAT GEOJSON|GPX|KML|...<br>
  DATA &quot;<a href="http://localhost/mydata.php" target="_blank">http://localhost/mydata.php</a>&quot;<br>
  TYPE LINE<br>
  ...<br>
END<br>
<br>
or maybe:<br>
<br>
LAYER<br>
  NAME &quot;mylines&quot;<br>
  CONNECTIONTYPE HTTP/(GEOJSON|GPX|KML|...)<br>
  DATA &quot;<a href="http://localhost/mydata.php%5B?optional=user_args&amp;...]" target="_blank">http://localhost/mydata.php[?optional=user_args&amp;...]</a>&quot;<br>
  TYPE LINE<br>
  ...<br>
END<br>
<br>
Mapserver would add well defined arguments to the URL like:<br>
<br>
MODE=render|query|etc      - might be needed to set context of request<br>
BBOX=xmin,ymin,xmax,ymax   - area of interest<br>
FILTER=...                 - this could be a filter string of some kind<br>
ATTRS=gid,color,name,...   - list of expected/required? attributes<br>
TYPE=POINT|LINE|POLYGON    - type of spatial data expected<br>
FORMAT=GEOJSON|GPX|KML|... - format to respond in<br>
...                        - others as required<br>
<br>
<br>
The idea here is to forward the data request to the URL and it would validate the request and throw an error or handle the request and return the results as expected. Mapserver would then handle this like any other LAYER.<br>

<br>
BENEFITS:<br>
<br>
In general this opens up mapserver to easily be glued into any data source by writing an small external adapter in PHP, Perl or anything thing that can be queried via a URL that can conform to whatever protocol we require for mapserver.<br>

<br>
Much of the code already exists in mapserver for this, it is just getting reused as a new data provider.<br>
<br>
ISSUES:<br>
<br>
Other than the fact this this will not be the fastest data provider available, I can not think of any major one.<br>
<br>
FUNDING:<br>
<br>
I may be able to get some funding for this if we can get it into 6.0 and back ported to 5.6 even if it is not released on 5.6. Please contact me off list if you are interested in developing this. Currently on one format would need to be supported.<br>

<br>
COMMENTS:<br>
<br>
Please toss in your 2 cents on this. Raise issues, etc. The idea is to make this GENERIC so it can by used by anyone.<br>
_______________________________________________<br>
mapserver-dev mailing list<br>
<a href="mailto:mapserver-dev@lists.osgeo.org" target="_blank">mapserver-dev@lists.osgeo.org</a><br>
<a href="http://lists.osgeo.org/mailman/listinfo/mapserver-dev" target="_blank">http://lists.osgeo.org/mailman/listinfo/mapserver-dev</a><br>
</blockquote></div><br>