Grails: managing static data

I am looking for a good solution for managing static data in a Grails application i.e. data in infrequently changing tables such as a list of countries.

My requirements:

  • It should be easy to internationalize the data.
  • Should provide a means to load static data into the database (e.g. from an XML file) when running unit / integration tests
  • Should provide a means of synchronizing static data with the database when the server starts
  • Should provide a taglib for displaying static data (e.g. list of countries)
  • Should provide a view for manually viewing / modifying static data

lookups and ref code plugins try to solve this problem. Does anyone have experience with these plugins or are there other options?

+2


source to share


1 answer


I wrote about the lookups plugin in the May issue of GroovyMag. ( http://groovymag.com ) It will handle requirements 1, 4, and 5. I don't think there is anything out there that all 5 will do, but the other requirements shouldn't be very hard to implement. Perhaps you could get the source for one of these existing plugins and expand on it. Sounds like a fun project.



Dave

+2


source







All Articles