I have seen this issue many many times throughout my career so i thought it might be worth to go through it in details and help others.
If you have international content in your database and suddenly you see things like "Ã©" or missing characters like "?" instead of "è" you may be in trouble. It is a symptom of lack of consistency in the ways you write, read and store unicode characters.
I hope my explanation, even that lengthy, will shed some light on the core of the problem and possible solutions :)
That is just a quick hint about an issue i had today. I wasted so much time trying to find the cause of it when at the end it was just no space on the device!
If you have issue with ftp_get or ftp_nb_get and all you see in log is "ftp_get(): Transfer aborted. Broken pipe,,PHP code: 2" then it might be as in my case no space left for the target file!
Just a quick hint if anyone else has the same problem :)
I have moved to a new place and I was experiencing strange network issues on mu linux.
It seemed like internet was working but some websites just would not load. I noticed that it was especially bad on google products and other larger sites. Many sites would never load when on SSL!
Just a very quick tip on how to test for warnings that may happen in functions like fopen. PHP does not treat errors in unified way some of them rise warnings, some of them throws exceptions others return 0,false or -1 or some other value to indicate an error. How do you deal with them in PHP Unit?
I guess most of people have heard of address space randomization and linux kernel patches that provide that. PAX is a project that has been running for years and it is an awesome way to reduce risk of buffer overflow attacks on your linux server. The great thing about it is that it makes it harder to execute most common buffer overflows system-wide.
It is funny how often you can get caught by surprise that PHP is not Java. I have been using type hints in PHP for a long time but somehow i did not came across that for a long time.
If you have a method that type hints the parameter you wont be able to pass null in as in PHP null is not just unknown value but it is also a type.
Just a very short tip as it was a big surprise to me :) If you have xdebug enabled SoapClient will not throw an exception but cause a fatal error.
All you have to do is disable xdebug or make sure that soap service is available.
This is a funny problem that took forever to figure out! unreal!
Friend committed new component into the revision control system i checked it out and my maven builds would get stuck on compilation. It would take like 20 minutes to run the compilation!
Compilation with javac would take forever no matter if there was error or not. Importing any net.xxxx package would make builds stall forever.
Java applications that use ssl to consume web services via jax-ws or use HTTP clients may check the SSL certificate of the server in runtime. In case if your certificate is self signed or Common Name of the certificate does not match the domain name you will get connection errors.
To be able to develop applications you may need to run them on dev/qa servers and then allow your Java application consume these services. To do it you will need to import their SSL certificates into your local Java keyring (the same way you add exception rules into your browser).
Even after years in the business you still get these moments: "Ok, why is this not working? wtf?". It happened to me recently while moving applications between hosts. I did not notice that one of the settings for the application was using php_admin_value.
The difference is described in details here: php configuration settings
About the author
Hi, my name is Artur Ejsmont,
welcome to my blog. I am a passionate software engineer living in Sydney and working for Yahoo!
If you are into technology, you can order my book Web Scalability for Startup Engineers on Amazon. I would love to hear what are your thoughts so please feel free to drop me a line or leave a comment.