[postgis-devel] Proj GUCs

Paul Ramsey pramsey at cleverelephant.ca
Tue Jun 20 12:45:07 PDT 2023


So, looking for some feedback and institutional memory here.

First, it looks like if we want to move the locus of control for the proj grid cache up from the proj library into postgis proper, we will need at least two and maybe all three of these GUCs.

postgis.proj_network = boolean
postgis.proj_url_endpoint = string
postgis.proj_grid_cache_filename = string

These would allow people to manipulate the behaviour of their proj environment without having to have system access to muck with the proj.ini file directly. Of course, if proj is built without curl support then these GUCs will be useless.

Another possibility would be to just not bother with GUCs at this point and make the proj configuration semi-visible via an informational function that returns the these results in some form of info string:

int PROJ_DLL proj_context_is_network_enabled(PJ_CONTEXT *ctx);
const char PROJ_DLL *proj_context_get_url_endpoint(PJ_CONTEXT *ctx);
const char PROJ_DLL *proj_context_get_user_writable_directory(PJ_CONTEXT *ctx,
                                                              int create);

These are all available in proj from 7.0 and up, so pretty far back.

What do you think the best approach to avoiding proj network related issues is?

P


More information about the postgis-devel mailing list