|
111 | 111 | - [Sending a Pull Request](#sending-a-pull-request) |
112 | 112 | - [Benchmarks](#benchmarks) |
113 | 113 | - [Flags](#flags) |
114 | | -- [Changelog](#changelog) |
115 | | - - [v2.x](#v2x) |
116 | | - - [v1.x](#v1x) |
117 | | - - [v0.x](#v0x) |
| 114 | +- [Changelog](https://proxypy.rtfd.io/en/latest/changelog) |
| 115 | + - [v2.x](https://proxypy.rtfd.io/en/latest/changelog#v2x) |
| 116 | + - [v1.x](https://proxypy.rtfd.io/en/latest/changelog#v1x) |
| 117 | + - [v0.x](https://proxypy.rtfd.io/en/latest/changelog#v0x) |
118 | 118 |
|
119 | 119 | [//]: # (DO-NOT-REMOVE-docs-badges-END) |
120 | 120 |
|
|
128 | 128 | ```console |
129 | 129 | # On Macbook Pro 2019 / 2.4 GHz 8-Core Intel Core i9 / 32 GB RAM |
130 | 130 | ❯ ./helper/benchmark.sh |
131 | | - CONCURRENCY: 100 workers, TOTAL REQUESTS: 100000 req, QPS: 8000 req/sec, TIMEOUT: 1 sec |
| 131 | + CONCURRENCY: 100 workers, TOTAL REQUESTS: 100000 req |
132 | 132 |
|
133 | 133 | Summary: |
134 | | - Total: 3.1217 secs |
135 | | - Slowest: 0.0499 secs |
136 | | - Fastest: 0.0004 secs |
137 | | - Average: 0.0030 secs |
138 | | - Requests/sec: 32033.7261 |
| 134 | + Success rate: 1.0000 |
| 135 | + Total: 2.5489 secs |
| 136 | + Slowest: 0.0443 secs |
| 137 | + Fastest: 0.0006 secs |
| 138 | + Average: 0.0025 secs |
| 139 | + Requests/sec: 39232.6572 |
139 | 140 |
|
140 | | - Total data: 1900000 bytes |
141 | | - Size/request: 19 bytes |
| 141 | + Total data: 1.81 MiB |
| 142 | + Size/request: 19 B |
| 143 | + Size/sec: 727.95 KiB |
142 | 144 |
|
143 | 145 | Response time histogram: |
144 | | - 0.000 [1] | |
145 | | - 0.005 [92268] |■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■ |
146 | | - 0.010 [7264] |■■■ |
147 | | - 0.015 [318] | |
148 | | - 0.020 [102] | |
149 | | - 0.025 [32] | |
150 | | - 0.030 [6] | |
151 | | - 0.035 [4] | |
152 | | - 0.040 [1] | |
153 | | - 0.045 [2] | |
154 | | - 0.050 [2] | |
155 | | - |
| 146 | + 0.001 [5006] |■■■■■ |
| 147 | + 0.001 [19740] |■■■■■■■■■■■■■■■■■■■■■ |
| 148 | + 0.002 [29701] |■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■■ |
| 149 | + 0.002 [21278] |■■■■■■■■■■■■■■■■■■■■■■ |
| 150 | + 0.003 [15376] |■■■■■■■■■■■■■■■■ |
| 151 | + 0.004 [6644] |■■■■■■■ |
| 152 | + 0.004 [1609] |■ |
| 153 | + 0.005 [434] | |
| 154 | + 0.006 [83] | |
| 155 | + 0.006 [29] | |
| 156 | + 0.007 [100] | |
156 | 157 |
|
157 | 158 | Latency distribution: |
158 | | - 10% in 0.0017 secs |
159 | | - 25% in 0.0020 secs |
160 | | - 50% in 0.0025 secs |
161 | | - 75% in 0.0036 secs |
162 | | - 90% in 0.0050 secs |
163 | | - 95% in 0.0060 secs |
164 | | - 99% in 0.0087 secs |
| 159 | + 10% in 0.0014 secs |
| 160 | + 25% in 0.0018 secs |
| 161 | + 50% in 0.0023 secs |
| 162 | + 75% in 0.0030 secs |
| 163 | + 90% in 0.0036 secs |
| 164 | + 95% in 0.0040 secs |
| 165 | + 99% in 0.0047 secs |
165 | 166 |
|
166 | 167 | Details (average, fastest, slowest): |
167 | | - DNS+dialup: 0.0000 secs, 0.0004 secs, 0.0499 secs |
168 | | - DNS-lookup: 0.0000 secs, 0.0000 secs, 0.0000 secs |
169 | | - req write: 0.0000 secs, 0.0000 secs, 0.0020 secs |
170 | | - resp wait: 0.0030 secs, 0.0004 secs, 0.0462 secs |
171 | | - resp read: 0.0000 secs, 0.0000 secs, 0.0027 secs |
| 168 | + DNS+dialup: 0.0025 secs, 0.0015 secs, 0.0030 secs |
| 169 | + DNS-lookup: 0.0000 secs, 0.0000 secs, 0.0001 secs |
172 | 170 |
|
173 | 171 | Status code distribution: |
174 | | - [200] 100000 responses |
| 172 | + [200] 100000 responses |
175 | 173 | ``` |
176 | 174 |
|
177 | | - PS: `proxy.py` and benchmark tools are running on the same machine during the above load test. |
178 | | - Checkout the repo and try it for yourself. See [Benchmarks](#benchmarks) for more details. |
| 175 | + - See [Benchmark](https://github.com/abhinavsingh/proxy.py/tree/develop/benchmark#readme) for more details and how to run them locally. |
179 | 176 |
|
180 | 177 | - Lightweight |
181 | | - - Uses only `~5-20MB` RAM |
| 178 | + - Uses `~5-20 MB` RAM |
| 179 | + - Compressed containers size is `~18.04 MB` |
182 | 180 | - No external dependency other than standard Python library |
183 | 181 | - Programmable |
184 | 182 | - Customize proxy behavior using [Proxy Server Plugins](#http-proxy-plugins). Example: |
@@ -1627,21 +1625,11 @@ optional arguments: |
1627 | 1625 |
|
1628 | 1626 | ## Internal Documentation |
1629 | 1627 |
|
1630 | | -Code is well documented. Browse through internal class hierarchy and documentation using `pydoc3` |
1631 | | - |
1632 | | -```console |
1633 | | -❯ pydoc3 proxy |
1634 | | - |
1635 | | -PACKAGE CONTENTS |
1636 | | - __main__ |
1637 | | - common (package) |
1638 | | - core (package) |
1639 | | - http (package) |
1640 | | - main |
| 1628 | +Code is well documented. You have a few options to browse the internal class hierarchy and documentation: |
1641 | 1629 |
|
1642 | | -FILE |
1643 | | - /Users/abhinav/Dev/proxy.py/proxy/__init__.py |
1644 | | -``` |
| 1630 | +1. Visit [proxypy.readthedocs.io](https://proxypy.readthedocs.io/) |
| 1631 | +2. Build and open docs locally using `make lib-doc` |
| 1632 | +2. Use `pydoc3` locally using `pydoc3 proxy` |
1645 | 1633 |
|
1646 | 1634 | # Run Dashboard |
1647 | 1635 |
|
@@ -2028,7 +2016,9 @@ for list of tests. |
2028 | 2016 |
|
2029 | 2017 | # Benchmarks |
2030 | 2018 |
|
2031 | | -Simply run the following command from repo root to start benchmark |
| 2019 | +See [Benchmark](https://github.com/abhinavsingh/proxy.py/tree/develop/benchmark) directory on how to run benchmark comparisons with other OSS web servers. |
| 2020 | + |
| 2021 | +To run standalone benchmark for `proxy.py`, use the following command from repo root: |
2032 | 2022 |
|
2033 | 2023 | ```console |
2034 | 2024 | ❯ ./helper/benchmark.sh |
@@ -2216,30 +2206,3 @@ options: |
2216 | 2206 | Proxy.py not working? Report at: |
2217 | 2207 | https://github.com/abhinavsingh/proxy.py/issues/new |
2218 | 2208 | ``` |
2219 | | - |
2220 | | -# Changelog |
2221 | | - |
2222 | | -## v2.4.0 |
2223 | | - |
2224 | | -- No longer support `Python 3.6` due to `asyncio.run` usage in the core. |
2225 | | - |
2226 | | -## v2.x |
2227 | | - |
2228 | | -- No longer ~~a single file module~~. |
2229 | | -- Added support for threadless execution. |
2230 | | -- Added dashboard app. |
2231 | | -- Added support for unit testing. |
2232 | | - |
2233 | | -## v1.x |
2234 | | - |
2235 | | -- `Python3` only. |
2236 | | - - Deprecated support for ~~Python 2.x~~. |
2237 | | -- Added support multi core accept. |
2238 | | -- Added plugin support. |
2239 | | - |
2240 | | -## v0.x |
2241 | | - |
2242 | | -- Single file. |
2243 | | -- Single threaded server. |
2244 | | - |
2245 | | -For detailed changelog refer to release PRs or commit history. |
0 commit comments