Yii Framework Forum: Memcache Application Object - Yii Framework Forum

Jump to content

Page 1 of 1
  • You cannot start a new topic
  • You cannot reply to this topic

Memcache Application Object Rate Topic: -----

#1 User is offline   Sepia 

  • Newbie
  • Yii
  • Group: Members
  • Posts: 18
  • Joined: 19-July 12

Posted 20 November 2012 - 10:05 AM

Has anyone used Memcache before to cache an entire application object with its components so it won't have to boot up during each request? I think this will help us a great deal saving the time to parse the config and load components.
0

#2 User is offline   Keith 

  • Elite Member
  • Yii
  • Group: Moderators
  • Posts: 1,561
  • Joined: 04-March 10
  • Location:UK

Posted 20 November 2012 - 10:19 AM

Bear in mind that memcached sets a limit of 1MB for each stored object by default because of performance concerns. I suspect that you'd be better off using an opcode cache such as EAccelerator, APC or XCache.
0

#3 User is offline   Sepia 

  • Newbie
  • Yii
  • Group: Members
  • Posts: 18
  • Joined: 19-July 12

Posted 20 November 2012 - 12:08 PM

View PostKeith, on 20 November 2012 - 10:19 AM, said:

Bear in mind that memcached sets a limit of 1MB for each stored object by default because of performance concerns. I suspect that you'd be better off using an opcode cache such as EAccelerator, APC or XCache.


Keith, would such caching engines be able to cache the entire application state?
0

#4 User is offline   Keith 

  • Elite Member
  • Yii
  • Group: Moderators
  • Posts: 1,561
  • Joined: 04-March 10
  • Location:UK

Posted 20 November 2012 - 12:45 PM

They don't cache state, they cache compiled code so that the files don't have to be interpreted in every request. It's one of the easier ways to speed up your application.
0

Share this topic:


Page 1 of 1
  • You cannot start a new topic
  • You cannot reply to this topic

1 User(s) are reading this topic
0 members, 1 guests, 0 anonymous users