rt-box Posted May 9, 2006 Share Posted May 9, 2006 Hi allI'm currently designing a PHP app that should be subject to intense peaks of connections once it is in place. I'm therefore pondering whether to implement some kind of caching system. Full HTML output caching is out of question, as the app is divided into different parts that can evolve at different paces depending on the kind of activity they receive. The main constraint is that data from the different parts can be needed in to display other parts, or to display some user-defined page.So my choice is the following:(a) just don't cache, hope the servers will hold, and grab the data from the database when needed and compute the HTML output every time;OR(b) set up an intermediary data storage in XML for each module, and when loading a module inside a page, just check the data has not been modified (through a track number in the database) and insert it into a main XML document representing the page, to be transformed into HTML.The idea of using XML also seems interesting as it allows reusing cached data anywhere in the app.So the big deal is whether (b) is really better than (a) in terms of performance, knowing that the database queries we are talking about can be very different across modules - loops through forum posts or just grabbing one record from a table.There's a also subsidiary question to choice (b) : should the XML file we get in the end representing the page be transformed with XSLT server-side or client-side ? I mean, does anyone know whether many users could end up not seeing the page as they should because their browser doesn't know about transforming XML ?Thanks for any comments.RT Quote Link to comment https://forums.phpfreaks.com/topic/9383-cache-in-question/ Share on other sites More sharing options...
rt-box Posted May 9, 2006 Author Share Posted May 9, 2006 *bump*please help Quote Link to comment https://forums.phpfreaks.com/topic/9383-cache-in-question/#findComment-34659 Share on other sites More sharing options...
448191 Posted May 10, 2006 Share Posted May 10, 2006 I find your post very interesting, but I don't think I fully understand. How does writing/reading data to/from XML reduce server load or increase stability?The way I see it, the opposite is true. But then again, I might just not understand. Quote Link to comment https://forums.phpfreaks.com/topic/9383-cache-in-question/#findComment-34887 Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.