Comments (3)
I believe #90 has fixed this, by setting it automatically. @jbolila , any chance you could give master
a try and see if wrk
works?
from simple-server.
On master, examples/server.rs
's response now looks like
< HTTP/1.1 200 OK
< content-length: 11
<
so it does include the content length and curl doesn't produce * no chunk, no close, no size. Assume close to signal end
anymore.
But the Date
and Connection
fields are still missing. Date
would be nice and easy to add. I'm not sure what would need to change to make keep-alive
work though.
about wrk:
In my tests, since wg/wrk@522ec60 (~3 yrs ago) wrk will compute Req/Sec even without the Content-Length
header.
The server will invariably crash after wrk finishes though. Cause is a broken pipe error here
Lines 265 to 266 in 10103f5
from simple-server.
Oh. but there still isn't Content-Length
for these errors:
Lines 318 to 321 in 10103f5
Lines 341 to 343 in 10103f5
Lines 378 to 380 in 10103f5
from simple-server.
Related Issues (20)
- Allow closures in Server::new HOT 2
- body() sometimes returns zeroed slice HOT 9
- Allow changing uid/gid after binding HOT 2
- When serving static files, they always must be in `public` directory. HOT 1
- Prepare 0.4 release
- Option to disable serving static files? HOT 4
- Send Date response header HOT 1
- Make error handling more convenient
- Only one connection being handled at a time HOT 3
- 93-byte limit for request body? HOT 2
- Terminating the server
- Request body is empty while making post request from "reqwest" HOT 1
- thread '<unnamed>' panicked at 'attempt to subtract with overflow' HOT 3
- README has 0.1.0 HOT 6
- Support `/` as `index.html` in static file serving HOT 1
- Location header seems to not be working HOT 2
- Since Server::listen blocks forever should it be marked diverging? HOT 1
- Allow serving in places other than the current working directory
- A method that listens on a TcpListener.
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from simple-server.