[Mapbender-dev] Cleaning up the SQL database
arnulf.christl at wheregroup.com
Thu May 31 07:50:01 EDT 2007
I propose to change our way to manage SQL data in Mapbender.
There are two different kinds
* Service data (WMS, WFS)
* GUI element data (code, module, position, content, element variables, etc.)
== Service Data ==
This is a hot topic when updating. Currently we have a fixed ID that is generated by the development server's sequence. This is horror for people who maintain a large number of WMS and have them organized in GUI. Currently every time Mapbender is updated we get load-errors because of constraints on the WMS ID or - even worse - we mess up the client's repository and bound GUIs.
== GUI element data ==
GUI element data comes in two variants:
# template GUI (currently gui, gui1, etc.)
# as an "SQL template" to be used to update private GUI.
In the second case it is required to add the GUI name to any update scripts. Potentially we do not need to do this because people can first update gui and gui1 and then copy from those GUIs. (There was a separate discussion to rename gui and gui1 into template_gui or template_basic_gui, etc.)
Some Mapbender functionality needs several modules. Therefore sometimes in the Wiki we name the function as the code, sometimes we invent a new name. Example:
* http://www.mapbender.org/index.php/AddWMS (simple)
* http://www.mapbender.org/index.php/MonitorCapabilities (many)
Another background is maintainability of the SQL. Currently keeping the dump up to date is painful and error prone. My hope is that if we split the large SQL chunk up into little pieces it will help maintenance because then the developer of the corresponding module also maintains the SQL snippet. The snippets are stored using the SVN which will also enhance updating for professional users and will allow us to have regular auto-builds over night so that the dev server is always up to date.
This needs a lot more thought as it will even tie back into packaging, install scripts, etc. Potentially this is better done in the Wiki once we know what we are talking about. Feel free to start this as a new page or tie it to a Trac ticket.
More information about the Mapbender_dev