News Feed
Jobs Feed
Sections



Recent Jobs

News Archive
feed this:

ServerGrove Blog:
How to Create a Cache Warmer in Symfony2
April 19, 2012 @ 09:09:56

In this new post from the ServerGrove blog Ismael Ambrosi shows how to create a "cache warmer" for a Symfony2 application - a handy tool that can pre-populate your applications cache with data you specify before it's needed by the app.

The cache is a very important part of your Symfony application as it helps your web server to perform better by not executing unnecessary code on every request, this is especially true if your server is running with limited resources. Cache warming allows you to cache specific data in your application through the use of a CacheWarmer. Symfony 2 includes a cache warmer that helps you to store parts of your application in cache, before the application becomes available to the user.

He shows how to create the "warmup" in an object extending the CacheWarmer to pull in content (in his case, just a text string) and write it out to a cache file automatically. Also included is the config updates you'll need to make to tell the Service Container about the Warmer.

0 comments voice your opinion now!
symfony2 framework cache warmer tutorial



NetTuts.com:
Turbocharge your Website with Memcached
February 07, 2012 @ 10:06:40

On the NetTuts.com site there's a new tutorial showing you how to introduce the Memcached tool to your application - a quick and easy way to cache data and optimize performance.

Your latest PHP/MySQL website is finally online. And it's awesome. But it's not as fast as you want it to be, because of the many SQL queries running every time a page is generated. And above that, you have the feeling it will not scale well under heavy loads. And you are most likely right. In this tutorial, we will see how you can greatly improve your website's responsiveness [...] by implementing a cache layer between your code and your database. The good news is it is fairly easy, and can be done in a few minutes!

They help you get the memcached server installed (a one-liner in most linux distributions) and how to install the memcached extension using PECL. Code is included showing you how to connect to the server, store data into the cache based on a generated key and how to pull the same data back out.

0 comments voice your opinion now!
memcached cache data tutorial introduction


Leaseweb Labs Blog:
POC Flexible PHP Output Caching
February 02, 2012 @ 12:10:21

On the Leaseweb Labs blog there's a recent post looking at using the POC framework to work with flexible output caching. The tool makes it easy to create a new object and push cache content into it, automatically caching the data to sources like the file system, a Redis instance or a MongoDB database.

Last year at the Symfony conference in Paris I have heard a really good quote: "There are only two hard things in Computer Science: cache invalidation and naming things" - Phil Karlton. I agree with it and it gave me a boost to keep evolving the concept.

He includes an introduction to the caching features of the framework complete with sample code showing first how to cache to the default file system and a more complex example that uses unique caches and page blacklists. Other features planned for the caching tool include edge-side includes, using Twig for templating and statistics recorded to a database.

0 comments voice your opinion now!
poc framework cache output flexible


Mike Wallner's Blog:
Dropping server load with HTTP caching
January 27, 2012 @ 09:43:04

Mike Wallner has shared a quick and easy HTTP caching technique in a new post to his blog today. The key is in using the PEAR HTTP_Header package.

Ever watched youself browsing e.g. a web forum? Noticed that you viewed the same page several times? Well, this means extraordinary and useless load for your server if there's no caching mechanism implemented in the web application. Even if there is some file or db cache you can still improve performance with implementing some http cache.

With a few simple lines of code using HTTP_Header, you can tell your scripts how long to set the "expires" header to on your requests. This increment (in seconds) is relayed to the browser to tell it when to next fetch the page and not reload from cache.

0 comments voice your opinion now!
http cache pear package httpheader tutorial


Ulf Wendel's Blog:
PHP mysqlnd query cache plugin quickstart is online!
January 18, 2012 @ 12:12:21

In a new post to his blog Ulf Wendel has pointed out that the mysqlnd query cache plugin quickstart is posted on the docs.php.net site.

New in the PHP manual: a quickstart for the mysqlnd query cache plugin. PECL/mysqlnd_qc, the mysqlnd query cache plugin, is transparent and ease to use. But, how? Some pointers have been given in assorted presentations, here on my blog and in some, few examples from the manual. Fixed. You can now browse a quickstart to gain a quick overview.

The query cache plugin can replace the query caching MySQL does and can help with things like multiple storage options (memory, APC, Memcache, etc) and almost no changes to your application. There's also a method (mysqlnd_qc_get_query_trace_log) that comes with the plugin that gives you a "stack trace" of every query run through the MySQL interface.

0 comments voice your opinion now!
mysqlnd query cache quickstart performance stacktrace


Kevin Schroeder's Blog:
Call for webinars (Zend)
January 18, 2012 @ 11:50:07

Kevin Schroeder is looking for suggestions. He wants to know what the PHP community wants to hear about in upcoming webinars from Zend.

Just wrapped up a call working on our webinar schedule for the year. We've got a bunch of ideas but we'd like to also get your input as well. Yes, I know y'all want ZF2 webinars. We have that down. I would also like to do an HTML5 and mobile webinar but I need an SME (Subject Matter Expert) for that. [...] I would also love to have webinars on how to use various API's, even if there is not native PHP support. So, what kinds of webinars do you want?

Leave your suggestions in his comments along with one already suggesting a "Why PHP?" checklist of sorts to help encourage companies/employers to go with the language.

0 comments voice your opinion now!
opinion webinar share zend zf2 html5 api


7php.com:
PHP Interview With Enrico Zimuel Senior Software Engineer At Zend Technologies
January 16, 2012 @ 11:30:04

On 7php.com there's a new interview posted with Enrico Zimual of Zend - "Everything is an Array in PHP".

In this edition, I talked with Enrico Zimuel a computer geek since he was 9yrs old. He has written a couple of books namely "Secrets, Spies and Cipher Codes" published by Apogeo in 1999 and the recent "How to use the digital sign" published by Tecniche Nuove in 2010. Enrico has a pretty impressive 'geek' path. He also speaks at many international conferences [...]. You can find his presentations on slideshare.

Questions in the interview include:

  • How do you find PHP now as compared to when you first started?
  • Based on your experience, what are the good and bad parts of PHP?
  • To someone who wants to become a better PHP developer, what is your advice?
  • What are some good PHP blog or resources you highly recommend?

Read the full interview here.

0 comments voice your opinion now!
interview enricozimuel zend software engineer community


Dave Marshall's Blog:
Defending against Cache Stampedes
January 13, 2012 @ 13:13:08

Dave Marshall has a new post to his blog showing one method for defending against cache stampedes from assaulting your caching servers and (possibly) bringing them down.

I've recently had a problem with a rather large operation (that could probably be optimised considerably, but nevermind), where by if the cached result of the operation expired, several web server threads would attempt the operation, causing some major headaches for our database and web servers. This is something I've come across before, and is commonly(?) known as a Cache Stampede. This is bad, this post describes the basics of what I've done to deal with it.

His example uses a Zend_Cache interface to Memecache, but it could be applied in other places too. His method uses a binary semaphore to check and see if there's a "lock" and sleep for a bit before checking again. Sample code is included showing how to create this system and how to refresh the data with a new expiration on a cache miss.

0 comments voice your opinion now!
cache stampede zendcache tutorial binary semaphore miss prevention


PHPMaster.com:
Zend Job Queue
January 13, 2012 @ 08:37:31

In this most recent post to PHPMaster.com Alex Stetsenko takes a look at the Zend Job Queue functionality, a part of the Zend Server installation. He talks about some basic usage to make HTTP requests and a more extended example showing report generation.

Web applications usually follow a synchronous communication model. However, non-interactive and long-running tasks (such as report generation) are better suited for asynchronous execution. One way to off-load tasks to run at a later time, or even on a different server, is use the Job Queue module available as a part of Zend Server 5 (though not as part of the Community Edition). Job Queue allows job scheduling based on time, priority, and even dependencies

In his two examples, he shows the code involved to create a new Queue object and define a HttpJob in it. The first just calls a "sample.php" script that's exposed as a part of your external-facing site and shows how you can get the current status of the job. The more advanced example shows a call to a "report.php" script with a set of options defining things like "type", "length" and "priority". He also points out some other options that can do similar things like Gearman, NodeJs and RabbitMQ.

0 comments voice your opinion now!
zend job queue zendeserver tutorial task status


Zend:
Zend Takes The Pulse Of Developers In The APP Economy
January 12, 2012 @ 12:56:15

In this new press release Zend has announced the posting of the results from their "Zend Developer Pluse" survey - a survey taken of developers world-wide about their habits, preferences and desires.

Zend Technologies addresses [the question of how a new demand for a new generation of apps] in Zend Developer Pulse, a new survey series that takes the pulse of a vibrant community of developers from around the world. The company's first developer survey conducted in late November 2011 offers insights on emerging technology and career trends captured from 3,335 respondents. The findings are summarized in a report now available at [http://www.zend.com/topics/zend-developer-pulse-survey-report-0112-EN.pdf].

The press release mentions some of the details from the survey including that 66% of developers will be working with mobile app development projcts, that next-generation UI deveopment scored high in skillsets, there was a strong interest in cloud development and that there's been a strong rise in the need for PHP development skills in the last year.

You can read the entire report here.

0 comments voice your opinion now!
zend survey pulse results developer



Community Events





Don't see your event here?
Let us know!


introduction symfony2 zendframework2 testing database api application phpunit voicesoftheelephpant language community opinion interview podcast release zendframework conference unittest development framework

All content copyright, 2012 PHPDeveloper.org :: info@phpdeveloper.org - Powered by the Solar PHP Framework