At ClusterCS, we have always focused on automation, flexibility and ease of use. The Speed engine is a traffic router for the web services that can deliver your website content. The Speed section interface offers an intuitive rule builder for sending and resolving web requests with the desired web service based on various conditions. The same logic applies to single servers and complex server clusters managed by ClusterCS. For more information on the ClusterCS Speed engine concepts please read the < ClusterCS Speed Engine – Concepts > section.
The Speed engine functionality is available for setups that utilize the HAproxy service as the web domain entry point. Services that can be utilized for traffic routing include Apache, NGINX, Lighttpd and Varnish, given that their settings have enabled HAproxy as the upper layer 7 load balancer. The default “Smart LAMP” setup provides this entire functionality out of the box. For custom setups, please make sure you follow the guidelines above.
A speed rule is composed of conditions and associated action. If the conditions are met for a request, the selected action is performed. It is very important to remember that the order of the rules matters. If a certain rule meets the criteria, its action will be executed, and remaining rules will no longer be evaluated.
If none of the rules match the received request, it will be forwarded to the web service assigned as default in Speed.
The rule conditions contain the following test types
- Path – the component of the URL following the domain name and before ‘?query’ Eg: for http://example.org/example_path/?qs , the path component will be “/example_path/”url_sub and not_url_sub (negation) tests will perform searches across the entire URL (including what is after ‘?’)
- Scheme – the URL scheme type (http or https)
- Cookie – cookie tests will be performed on the entire cookie header string
- IP – the source IP of the entity making the web request (client IP)
- Method – http request method (GET, POST, etc.)
- Host – matches on the domain name.Important: since the rule is created logically under a domain name, tests for the domain names and aliases are always performed so this rule is evaluated under the correct context. However certain tests require specific matches on the domain name such as tests for www. components or alias only tests – these can be easily performed with the Host tests
- Referrer – web request http referrer
- User Agent – web request user agent (eg: browser detection)
The actions contain the following options:
- Speed Engine – Serve With – select one of the load balanced web services to handle the request, this reflects your currently set up services
- Speed Engine – Cache With – select a caching capable web service to proxy the request through
- Speed Engine – Clear Cache– define and protect a clear cache URL that can be used for refreshing a cache
- Speed Engine – SEO Redirect – ability to do HTTP/HTTPS changes, www to non-www and vice versa redirects
- Speed Action – Rate Limit – an antispam solution which allows you to set a number of requests in a certain time period from an IP
- Speed Action – Require Authentication – secure a webpage or certain links with a username and password in order to add an extra layer of security.
- Speed Action – URL Redirect –webserver’s functionality to send a user from one URL to another one
- Speed Engine – Proxy – reverse-proxy to any IP and Port, locally or on an external server
- Caching on WordPress using nginx – more speed, a better experience for your visitors, for SEO, or any personal reason
- Caching on WordPress using Varnish– more speed, a better experience for your visitors, for SEO, or any personal reason
- Block – allows rejecting a request to protected resources defined by conditions (eg. Admin area)
- End with HTTP code – like Block but can end the execution with various status codes