IT_Architect
Verified User
- Joined
- Feb 27, 2006
- Messages
- 1,094
I developed some code that ran perfectly on the development machine with a default installation of PHP 5.3. Oddly, it didn't run on a DA machine that I had recently upgraded from PHP 5.2 to 5.3. I discovered that DA installs libmysql, rather than the new, and default for 5.3+, mysqlnd. (MySQL Native Driver) I'm proposing that mysqlnd be the new default driver for the following reasons:
1. All current PHP development efforts have been in coordination with the mysqlnd driver. libmysql has a license problem. The MySQL-provided library is released under the GPL. The PHP license is not compatible with the GPL, so distributing PHP binaries compiled against GPL code is BIG problem. That's a problem for more than just PHP. It turns libmysql's future into a dead end road.
2. Unlike libmysql, mysqlnd runs under the control of the Zend Engine. There are a thousand tricks the PHP developers can play because of that.
3. One of the new features added in 5.3 is asynchronous queries. This is HUGE! This is where I ran into trouble with the DA configuration. After much hair pulling, traced it down to DA using the older libmysql.
4. Other features that 5.3 + mysqlnd adds is persistent connections under mysqli, read-only variables so it can assign pointers instead of copying buffers, etc.
5. As PHP versions increment, and add features, the expectation on the part of developers will be that those features work. That is already a problem for libmysql, and will grow with each release.
Summary: There may be valid reasons why DA is not using the default mysqlnd. I'd ask if those reasons trump the advantages of using it. Before I post a simple "How To" to switch to mysqlnd, I wanted to see if DA has any plans to change to mysqlnd soon, in which case "How To" visitors would be better served if I didn't post it, and I would be happy to delete this thread as well if the change to msqlnd is imminent.
Thanks!
1. All current PHP development efforts have been in coordination with the mysqlnd driver. libmysql has a license problem. The MySQL-provided library is released under the GPL. The PHP license is not compatible with the GPL, so distributing PHP binaries compiled against GPL code is BIG problem. That's a problem for more than just PHP. It turns libmysql's future into a dead end road.
2. Unlike libmysql, mysqlnd runs under the control of the Zend Engine. There are a thousand tricks the PHP developers can play because of that.
3. One of the new features added in 5.3 is asynchronous queries. This is HUGE! This is where I ran into trouble with the DA configuration. After much hair pulling, traced it down to DA using the older libmysql.
4. Other features that 5.3 + mysqlnd adds is persistent connections under mysqli, read-only variables so it can assign pointers instead of copying buffers, etc.
5. As PHP versions increment, and add features, the expectation on the part of developers will be that those features work. That is already a problem for libmysql, and will grow with each release.
Summary: There may be valid reasons why DA is not using the default mysqlnd. I'd ask if those reasons trump the advantages of using it. Before I post a simple "How To" to switch to mysqlnd, I wanted to see if DA has any plans to change to mysqlnd soon, in which case "How To" visitors would be better served if I didn't post it, and I would be happy to delete this thread as well if the change to msqlnd is imminent.
Thanks!
Last edited: