[mapserver-users] Make PROJECTION mandatory?

Steve Lime sdlime at gmail.com
Mon Apr 27 11:20:39 PDT 2020


I would prefer to pursue as a documentation/communication exercise first.
It's not that I don't agree that PROJECTION blocks are generally
recommended but making them required and introducing artificial projections
to deal with cases when projections aren't used (embedded legends, scale
bars and other static map elements) will touch a lot of code. It's also a
major breaking change that would potentially break a large percentage of
mapfiles going forward.

--Steve

On Mon, Apr 27, 2020 at 8:43 AM Jeff McKenna <jmckenna at gatewaygeomatics.com>
wrote:

> Hi Jukka,
>
> I personally consider defining PROJECTION blocks at the MAP level and
> all LAYERs mandatory, in my day-to-day work, for each and every mapfile.
>   If you do not specify all of these, MapServer makes assumptions and
> you are just asking for trouble downstream through WMS clients etc.
> (your users)
>
> I also do not rely on any PROJECTION AUTO magic either, for my paying
> clients.
>
> These are all nice tricks but in critical production environments I stay
> away from them; instead, find the source projection, and define the MAP
> projection block and all LAYER projection blocks.
>
> I'm not sure this answers your questions, but this was my 'gut reaction'
> to your message.  I believe we have the same thinking here.
>
> -jeff
>
>
>
> --
> Jeff McKenna
> MapServer Consulting and Training Services
> https://gatewaygeo.com/
>
>
>
> On 2020-04-27 10:36 a.m., Rahkonen Jukka (MML) wrote:
> > Hi,
> >
> > Recent Mapserver buids require PROJ and GDAL
> > https://mapserver.gis.umn.edu/ja/development/rfc/ms-rfc-127.html. That
> > means that every Mapserver can support PROJECTION blocks both at the MAP
> > level and within LAYER. And because there are no more builds without
> > Proj support there is no real need for writing mapfiles without
> > PROJECTION blocks. Therefore I suggest that such mapfiles should be
> > considered invalid in the future. If it is for some reason too strict
> > requirement, what if we at least edit the documentation
> > https://mapserver.org/mapfile/projection.html so that it really
> > encourages users to write the PROJECTION blocks. GetCapabilities could
> > also show something like
> > <!-- WARNING: No explicit source projection defined for layer
> > 'my_layer'. -->
> >
> > Having layers without PROJECTION saves users from writing this much text:
> >
> > “PROJECTION "init=epsg:3857" END
> >
> > but when the user meets any problem with accessing data or rendering the
> > first thing to check is the projection. In the mailing list it means one
> > more question-answer round before getting closer to the real problem –
> > if the problem was not in the projection, as it very often is.
> >
> > If source data are in local coordinate system it would be better to
> > define also that explicitly with a special keyword like PROJECTION
> “LOCAL”.
> >
> > Would other user consider making projection compulsory rather as an
> > improvement or inconvenience?
> >
> > -Jukka Rahkonen-
> >
> >
> > _______________________________________________
> > mapserver-users mailing list
> > mapserver-users at lists.osgeo.org
> > https://lists.osgeo.org/mailman/listinfo/mapserver-users
> >
>
>
> _______________________________________________
> mapserver-users mailing list
> mapserver-users at lists.osgeo.org
> https://lists.osgeo.org/mailman/listinfo/mapserver-users
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/mapserver-users/attachments/20200427/c3e6ad0a/attachment-0001.html>


More information about the mapserver-users mailing list