I am working on a project that uses PHP to create an 'complex' object with lots of references to other objects linking back to their parent objects etc...
The object structure is then serialized by the Zend AMF module and sent over to the flex application.
The problem is that serialization takes a lot of time (+10sec).
My question is thus: can anybody give me tips on how the serialization works and in what way I may be able to optimize the object structure in order to make serialization run faster?
Switching to JSON will help a great deal with this, as it allows easier caching.
APC will also help, just for the opcode-cache part, not for storing objects in memory.
How big is this object exactly? Could it be worth it not sending the entire thing? If you're just dealing with recordsets, you might be able to fix it in the frontend by only downloading only what the user can see, or will see in the near future.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With