Nginx Module Reference Manual: Memcached module (Memcached)

Source: Internet
Author: User
Keywords nginx memcached Module
Tags aliyun caching compiled configuration configure data default default value

These modules are all compiled into Nginx by default unless a module is manually specified to be excluded in configure.

Use this module to simply process caching.
Sample configuration:

server {location/{set $memcached _key $uri; memcached_pass http://www.aliyun.com/zixun/aggregation/11696.html ">name : 11211; Default_type html; Error_page 404 =/fallback; } location =/fallback {Proxy_pass backend;}}

Instructions

Memcached_pass

Syntax: Memcached_pass [Name:port]
Default value: None
Working with fields: HTTP, server, location
The backend needs to set some data in the memcached, memcached key is "/uri?args".
After version 0.5.9, memcached key is stored in the variable $memcached_key.

Memcached_connect_timeout

Syntax: memcached_connect_timeout [TIME]
Default value: 60s
Working with fields: HTTP, server, location
The timeout for connecting the memcached service in seconds.
You can specify a time unit to avoid confusion, and the supported time units have "s" (seconds). MS "(milliseconds)," Y "(year)," M "(month)," W "(week)," D "(Day)," H "(hour), and" M "(minutes).

Memcached_read_timeout

Syntax: memcached_read_timeout [TIME]
Default value: 60s
Working with fields: HTTP, server, location
Timeout for reading memcached data in seconds.
You can specify a time unit to avoid confusion, and the supported time units have "s" (seconds). MS "(milliseconds)," Y "(year)," M "(month)," W "(week)," D "(Day)," H "(hour), and" M "(minutes).

Memcached_send_timeout

Syntax: memcached_send_timeout [TIME]
Default value: 60s
Working with fields: HTTP, server, location
Timeout for sending memcached data in seconds.
You can specify a time unit to avoid confusion, and the supported time units have "s" (seconds). MS "(milliseconds)," Y "(year)," M "(month)," W "(week)," D "(Day)," H "(hour), and" M "(minutes).

Memcached_buffer_size

Syntax: memcached_buffer_size [size]
Default value: GetPageSize (2)
Working with fields: HTTP, server, location
The size of the sent/received buffer, in bytes.

Memcached_next_upstream

Syntax: memcached_next_upstream [ERROR | timeout | invalid_response | not_found | off]
Default Value: Error timeout
Working with fields: HTTP, server, location
Specifies in which error state the request will be forwarded to a different load-balancing server, only if the Memcached_pass has two or more than two values.

Variable

$memcached _key

The value of the Memcached key.

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.