學術及資源的交流園地 ^_^

selinux

 

 

11. iterator

 

 

varnish

介紹

varnish 是一個 CDN 級的 Web Reverse Proxy. 它的設計是在 64-bit multi-core 的環境運作的.

它有兩個特點

  1. 用 kernel 的 swap 去管理 memory
  2. shared memory log

Home Page:

https://www.varnish-cache.org

 

12. keyword: with ... as vars

 

介紹

The with statement is used to wrap the execution of a block with methods defined by a context manager. (try...except...finally)

https://www.python.org/dev/peps/pep-0343/

The with statement guarantees that if the __enter__() method returns without an error, then __exit__() will always be called.

Thus, if an error occurs during the assignment to the target list, it will be treated the same as an error occurring within the suite would be.

寫法:

with expression [as variable]:
    with-block

 

RSS feed