This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
"""Demo of streaming requests with Tornado. | |
This script features a client using AsyncHTTPClient's body_producer | |
feature to slowly produce a large request body, and two server | |
handlers to receive this body (one is a proxy that forwards to the | |
other, also using body_producer). | |
It also demonstrates flow control: if --client_delay is smaller than | |
--server_delay, the client will eventually be suspended to allow the | |
server to catch up. You can see this in the logs, as the "client |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// For all the confusing Prometheus configuration and | |
// regular expressions, | |
// explained in examples. | |
// Remember, there are default values for each item if it's missing. | |
// regex is (.*), | |
// replacement is $1, | |
// separator is ; | |
// ,and action is replace |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#include <stdio.h> | |
#include <stdlib.h> | |
#include <stdint.h> | |
#ifdef _MSC_VER | |
#include <intrin.h> /* for rdtscp and clflush */ | |
#pragma optimize("gt",on) | |
#else | |
#include <x86intrin.h> /* for rdtscp and clflush */ | |
#endif |