gggeek/phpxmlrpc

[Question]: Is version 4.x faster than version 3.0?

Closed this issue · 2 comments

Hello,

I'm trying to justify updating the library and I was wondering if version 4.x faster than version 3.0? Are there any benchmarks?

Thanks!

Hello.

Distributed with the library there is a script, benchmark.php, which can be used for measuring performances of both encoding/decoding and doing http calls (to localhost).
I did not use it to make a proper comparison between versions, but anybody could easily do it.

Having said that, the goal of creating version 4 was not to improve performances, but rather to clean up the library and bring it in compliance with modern php standards and tooling, such as: namespace, composer, autoloading, more oop, better https support, use utf8 as default, use more recent phpunit, etc...
It also sports a fair number of bugfixes compared to the last version in the 3.x line, esp. in the area of character set support.

Last note: since the API has changed between the two versions, there is now a compatibility shim that exposes the old api on top of the new one. I would expect that shim to chew away a tiny bit of performance (again, not measured, just a gut feeling here), so, if you are interested in performance, it is probably a good idea to use the new API.

Thanks for your swift reply! I needed something to take to the rest of management. 😉