Menu

#2 Caching xajax objects

open
None
5
2009-01-25
2008-04-29
No

Caching xajax objects would improve performance because you had to call registerFunction() only once at the beginning of a session.

If you initialize a new xajax object with "new xajax(..)" there is not only the object instantiated but also GET and POST variables are being processed. This makes it impossible to cache xajax objects in a session or apc_cache.

It's also confusing that there is data being processed if you create a new object with "new xajax(..)". The method processRequest() which looks like the processing method in fact only calls the callback method. So it would be better if initialization and processing are separated.

Discussion

  • Joseph Woolley

    Joseph Woolley - 2009-01-25
    • assigned_to: nobody --> calltoconstruct
     
  • Joseph Woolley

    Joseph Woolley - 2009-01-25

    I agree for the most part. Currently the GET and POST will be processed when the xajaxArgumentManager is instantiated (so they are processed only once per request). We will review and include an update in a future release as needed.

     

Log in to post a comment.