Load Balancer

Differences Between Layer 4 and Layer 7 Load Balancing -  Layer 4 load balancing operates at the intermediate transport layer, which deals with delivery of messages with no regard to the content of the messages. Transmission Control Protocol (TCP) is the Layer 4 protocol for Hypertext Transfer Protocol (HTTP) traffic on the Internet. Layer 4 load balancers simply forward network packets to and from… Continue reading Load Balancer


Proxy Pattern

This is not same as Bridge Pattern. “Provide a surrogate or placeholder for another object to control access to it” is the intent provided by GoF.   When to use this pattern? Proxy pattern is used when we need to create a wrapper to cover the main object’s complexity from the client. Types of proxies Remote… Continue reading Proxy Pattern

Facade Pattern

The Law of Demeter (LoD) or principle of least knowledge is a design guideline for developing software, particularly object-oriented programs. In its general form, the LoD is a specific case of loose coupling. The guideline was proposed by Ian Holland at Northeastern University towards the end of 1987, and can be succinctly summarized in each of the following ways: Each unit should have only… Continue reading Facade Pattern

Mysql – Having

As per SQL standard - The HAVING clause without a GROUP BY clause acts like the WHERE clause. If the HAVING clause contains no aggregate functions, use the WHERE clause for faster performance. SO Link here's an example of a SQL statement where we use HAVING: select column1 from table1 where condition1 having condition2; isn't it the same exact thing if we do this: select column1 from… Continue reading Mysql – Having

PHP 7 New Features

Link, Lynda.com VideoLynda.com Video Major Feature Scalar type hints Type hints have been available in PHP for while now. Unfortunately they were restricted to classes, arrays and callables. As of PHP 7, the scalar types (integers, floating point numbers, booleans and strings) can also be used as type hints. By default “coercive mode” is enabled. This restricts PHP from throwing a type… Continue reading PHP 7 New Features

PHP Magic Method

Link __set and __get PHP provides a pair of magic methods that deal with non-existent or private property access: The __get() method is called whenever you attempt to read a non-existing or private property of an object. The __set() method is called whenever you attempt to write to a non-existing or private property of an object. Code __call  Similar… Continue reading PHP Magic Method