I'm wondering what techniques others typically use for persisting dynamic content info for the presentation tier of their web apps. E.g. My customer wants via an admin section to change a few images on the home page. One could create a database table for this of course, but it doesn't feel quite right to me. One, caching is an issue. Two, I prefer to reserve the DB for domain type data, not presentation data. Perhaps an xml file accessed via the infrastructure layer? Any other alternatives?
A:
If the software code is unique for several sites, and the customers edit its own page among others, I will tend to consider it as part of the business of the application, and then store images paths and (eventually) images files in database, levering caching in UI templates and for rendering. If the software code is unique for the one customer, or eventually if their is only one instance of the software by customer, I will then tend to consider customization as an integration step, and have every thing stored in UI layer using an XML file for paths (and I will probably have no administration page).
snowflake
2010-08-13 09:06:29