Another one of those popular online tech debates that started over a year ago when PHP7 launched. PHP didn’t take much time to become one of the biggest assets for open source development. But PHP5 eventually got a rival in the form of HHVM (HipHop Virtual Machine), a virtual tool developed by Facebook that can execute PHP code far more effectively than other tools.

The contest took a turn when the latest version of PHP – PHP7 arrived. It outclassed its predecessor in many ways.

And so the showdown began. To come to a conclusion, we need to see what the contenders brought to the table.
 

HHVM

 
Developed by tech giant Facebook in 2010, and released in 2011, the main purpose of HHVM was to reduce server resources so as to deliver a better experience for Facebook users. It does just that by converting PHP code into machine code quickly and efficiently. However, there are merits and demerits that we need to consider.

Merits

  • Just in Time (JIT) compiler – the main reason how HHVM surpassed PHP5 in performance
  • Any developer can install and work with it
  • Doesn’t require much memory space to execute requests
  • Hack – an internally developed programming language that allows programmers to use static as well as dynamic typing. Considerably improves compilation speed.
  • Reliable community support for the developers to keep improving the tool.
  • Websites can run faster in most situations due to dynamic translation.

Demerits

  • Custom extensions should be converted prior to adding them
  • Does not support all WordPress plugins and themes
  • Designed for high-end machines, and will not work on 32 bit operating systems
  • Requires a lot of memory. The machine running it will need at least 2 GB RAM.
  • If Facebook ceases HHVM support, the large development community will soon disappear.

 

PHP7

 
PHP6 development took too long, and was riddled with many issues consequently giving it a bad reputation before its release. PHP6 eventually ended up in the trash, and was replaced by PHP7 that delivered a massive performance boost over PHP5.

Merits

  • Many new programming language features including new operators, return type hinting, uniform variable syntax etc.
  • Streamlined internal data handling made it almost 4 times more memory efficient than PHP5.6
  • Established communities that offer technical support and troubleshooting assistance.
  • Quicker response to requests with double the request handling limit compared to PHP5.6

Demerits

  • Lacks support for many PHP4 features
  • HHVM is better when it comes to certain performance metrics
  • Does not support some application plugins and themes
  • Not recommended for high-traffic websites

Now, let’s get ready to rumble.

You can find performance comparisons of the two all over the internet. But it probably won’t help you get to a conclusion. Both contenders definitely outperform the older PHP versions. However, in certain instances one is better than the other. The methodology should be the critical factor here when you are assessing benchmarks.

The way they interpret PHP code is fundamentally poles apart. PHP7 uses PHP interpreter to translate and execute PHP codes. HHVM converts PHP code to HipHop bytecode, which is then interpreted and optimized as machine code and executed.

Benchmark tests by Kinsta in WordPress showed HHVM processing and executing 624 requests per second while PHP7 managed to execute only 604 requests. However, PHP7 had a more distinct advantage in Drupal 8, evident from the benchmark test. PHP7 managed 37% more server requests per second than HHVM. [Source: Kinsta]

Tests on various CMSs including Magento 2 community edition, Pyro CMS etc. indicated that HHVM is a better performer than PHP7. PHP7 was faster in Laravel 5.1 though.

When it comes to reduced overall memory usage, PHP7 takes the prize. HHVM demands comparatively more memory, in turn constraining server selection. Nevertheless, HHVM WordPress websites still consumed fewer CPU resources. However PHP and HHVM showed evenly matched performance on site load time tests.
 

Conclusion and Verdict

 
If you have used PHP5, you will easily notice the performance improvements in PHP7. However, your choice will ultimately depend on your requirements and your capacity. For high traffic websites running on multi-core servers, HHVM is the right choice. If you are just looking for something significantly better than PHP5, PHP7 is the way to go.

Software development is at its best if it helps a lot of people or a huge community. Keeping that in mind, HHVM basically is a more selfish alternative. It’s not shared much for the community to use it the way they want to. PHP, on the other hand, is a tool that’s constantly being improved for everyone to use, and is a more generous alternative. Experts claim that the support PHP is getting now, and the small pieces of incremental enhancements should help PHP7 emerge the victor of this bout eventually in terms of performance.

Verdict: HHVM wins for now. But a future rematch will most likely have different results.

Written by: Ajeesh Azhakesan

Containers play a vital role in software development for getting the software to run reliably in various computing environments; from a developer’s computer to a test environment, and staging and production. In addition to this, container technology is mostly adopted at present by companies to achieve developer efficiency.

When it comes to container technology, Docker is still the most popular choice. However, Kubernetes isn’t that far behind either. The open source project continues to be a reliable choice for container orchestration and management. The most recent version of the container cluster manager includes a plethora of beneficial features that will help teams optimize container usage in organizations.

Brian Gracely, Red Hat’s Director of Product Strategy, says the present state of containers has hit a tipping point, prompting the need for businesses to be faster and more responsive as to what’s going on in the market. Companies end up relying on individuals to keep the systems secure, update, and scale them appropriately. Kubernetes aims to automate this according to Gracely.

He also added that after leveraging out of big global web-scale cloud providers, Kubernetes has become applicable to lots of vertical industries and businesses. Companies can either apply Kubernetes to a new project or find a way to add it to their portfolios.
 

Key features of Kubernetes 1.5

 
According to the Kubernetes team, version 1.5 will benefit those who want to run a distributed database on Kubernetes. It will include solutions that could help guarantee application disruption service-level objectives (SLO) for stateful and stateless applications. Kubernetes 1.5 is also unique because PodDisruptionBudget and StatefulSet moved into beta.

The Kubernetes team mentioned that these features will make it easier to deploy and scale stateful applications, and perform cluster operations like node upgrade without violating application disruption service-level objectives.

Basically, with StatefulSet, organizations can use applications in a Kubernetes environment and run them in containers, while customers will have a consistent platform without compromise in functionality. In addition, users will not be forced to rewrite applications while using containers.

The PodDisruptionBudget beta is simply an API object that’s meant to specify the minimum percentage (or number) of replicas of a collection of pods that must be up. It basically allows the application deployer to make sure that the cluster operations don’t voluntarily evict too many pods simultaneously so as to cause data loss or service degradation.

Another promising feature is ‘Federation’ which essentially allows the user to pair an individual Kubernetes environment with another (or multiple) Kubernetes environment making them appear as a single pool of resources. This allows organizations to enable their data centers to make use of additional public cloud resources, also allowing them to explore environments beyond their data centers while having control and visibility over what those environments should look like.
 

Limitations of Kubernetes 1.5

 
Certain features including StatefulSet are still in beta, though development is progressing rapidly. The company also doesn’t want to trouble users by releasing upgrades every three months, and is currently figuring out a reliable upgrade process.

Written by: Ajeesh Azhakesan

Technology plays a critical role in web stacks. Web stacks have always evolved in parallel with technology, over the years. We will be discussing LAMP stack and MEAN stack today.

LAMP stands for Linux, Apache, MySQL, and PHP/Python/Perl.

MEAN is an acronym for MongoDB, Express.js, Angular.js, and Node.js

There still seems to be a confusion when faced with a choice of MEAN or LAMP stacks for web development. The backend languages, server environment and databases are different for both.

Let’s discuss the pros and cons of MEAN and LAMP stacks with respect to 3 key areas – Web server, database and operating system.
 

The Web Server

 
Apache provides the web server for LAMP stack while Node.js holds that responsibility in the MEAN stack. LAMP stack has been there for a long time. And that is also one of the reasons why Apache is considered a mature technology, where you can get new extensions when they are available.

As for Node.js, it’s a relatively new technology. While you still get quite a few active plug-ins, you will still have to write your own plug-ins to cover those areas missing necessary functionalities. Node.js is event-based and also locks codes on the web server into JavaScript. This can complicate things when you try to convert a sophisticated back-end program.
 

Database

 
LAMP uses MySQL or other relational databases while MEAN works with MongoDB, a non-relational database. If you are in a situation where you have to translate the data in an existing SQL database, you will soon find it tiresome to remove redundant object attributes, and may have to rely on a custom software for this purpose.

Relational databases are comparatively easier to work with but is on the verge of becoming outdated. MongoDB features faster data retrieval and is more scalable though.
 

The Operating System

 
LAMP stack locks the operating system to Linux and its variants. There are no such restrictions in MEAN, as you can run it in any OS compatible with Node.js. Linux isn’t your only option if you are using MEAN stack, though it is still considered to be the best OS for a server environment.

Both LAMP and MEAN have pros and cons in all 3 key areas. Let’s assess a few more facts before concluding.
It is said that you can only master MEAN stack once you have mastered JavaScript. It’s going to be a tad tedious, but worth it. However, LAMP stack works with front-end JavaScript and back-end PHP, just comfortable enough for developers to develop an application without much worries.

While MEAN stack is faster and more scalable, LAMP is a tried-and-tested web stack with a secure infrastructure and a large support community.
 

Conclusion

 
Although many developers claim that MEAN stack will eventually replace LAMP stack, there are others who still believe in the latter’s potential. LAMP is time-tested, stable and sturdy, with tons of online tutorials and support availability. Its back-end architecture allows you to do whatever you want to do on the front-end. MySQL is still one of the most widely used databases.

MEAN stack features a single language from top to bottom, in addition to flexible deployment and faster data retrieval capabilities. You are free from micromanaging schemas and migrations in the database as it uses a non-relational NoSQL database. With JavaScript gaining popularity, MEAN stack is attracting more developers every year.

Deciding between LAMP and MEAN will mostly depend on the organizations you work for and the projects under development.

Written by: Ajeesh Azhakesan
Page 6 of 6« First...3456