Comments (5)
Just confirmed. Without using the Agent
everything works as expected. Incase it matters we use Caddy
as SSL Proxy infront of our Authentication. I'm not even sure if we want to use Agent
as the auth connection will only be used once per login into the gameserver.
from ureq.
@Songtronix @xMAC94x Thanks for your help in this! I'm going to close this specific issue since I captured what's going on in #124
from ureq.
from ureq.
Hi @jsha relevant snippet of code isn't that easy as we only detected it for our full setup. Let me try to explain:
Veloren_Gameserver +
+ ^ +-----------------> HTTPS Proxy(Caddy) +-------> Authentication Server
| |
| | ^
v + |
Veloren_Client +-------------------------+
We have our Gameserver and our Client, that tries to connect to the Gameserver to join a normal multiplayer game.
In the cloud we have a central authentication server behind a HTTPS Reverse proxy.
Both the Veloren_Client and Veloren_Gameserver need to access the Authentication Server for the login procedure. Both are using ureq
as a client while we use rouille
as the Authentication server.
We noticed that the server can get reproduceable a syntetic error. I spend yesterday to improve our error Reporting so that it's easier to test for you :)
The relevant code (that runs in both Veloren_Client and Veloren_Gameserver) is this: https://gitlab.com/veloren/auth/-/blob/93c5819c502bd912cca6fc2fff9d9817564b1de1/authc/src/lib.rs
It's doing all the ureq
code we have.
If you want to reproduce the error for yourself, clone our game repository: https://gitlab.com/veloren/veloren/ and start it with cargo run
. you have to create yourself an account at https://account.veloren.net/ (just some dummy values, but remember it good, as we don't have a email recovery yet).
In the game now execute the following steps
- enter
pftclan.de
as server address and enter username and pass - click the Multiplayer button.
2a. It works and you come to an character screen: Logout and wait 5 minutes (use a clock to be sure it's 5 mins) and repeat step 2.
2b: You get an error "Auth error on server: Request failed, connection error with text Failed to read status line". WhereFailed to Read Status line
is theureq
error. continue! - Login again, NOW it will work guranteed. You see the character screen
- Logout again.
- Wait 5 minutes(use a clock).
- Jump to step 2. and repeat. (you will get the same error again, guaranteed).
The fact that we only get the error after 5 mins, leads us to the hint that it might be a timeout killing the HTTPS connection which then leading to a read status line
error. But we are no experts here. (the same ureq::Agent is reused from here: https://gitlab.com/veloren/veloren/-/blob/master/server/src/login_provider.rs)
We would be super happy if you can verify the behavior yourself and can confirm that it's some strange bug.
Have a nice day :)
from ureq.
@xMAC94x Thanks for the very detailed report!
It sounds like we might have a bug in ureq::Agent
where a pooled connection fails after lying dormant in the Agent for a while.
Just to verify that theory, could you temporarily stop using an Agent and just use ureq::get
/ureq::post
etc at each call site to cut out the pooling?
from ureq.
Related Issues (20)
- Timeout not working when having packet losses HOT 1
- Support Multipart Forms HOT 1
- Timeout not always respected HOT 5
- Invalid transformation to http::Response<Vec<u8>> for non utf8 response bodies HOT 3
- Example of requesting a continuous stream HOT 1
- Timeout not taking in consideration TimeoutConnect HOT 2
- ureq 2.9.3 fails to compile with errors in `hoot` HOT 3
- `ureq` 2.9.3 compilation fails due to `hoot` requiring rustc 1.65 HOT 4
- Keep-alive is disabled when using SOCKS HOT 1
- Update requirement of `url=2.3.1` HOT 3
- hootbin is a required dependency HOT 2
- Stream panics in drop during test
- Redirect history not available HOT 2
- Add support for configuring default headers in AgentBuilder HOT 1
- Potential to modify ordering for IS_TEST in lib module HOT 1
- Change `send_json` `data` argument HOT 4
- Add `Error::as_response` HOT 3
- Middleware cannot modify query string parameters? HOT 2
- Decide what to do about rustls defaulting to aws-lc-rs instead of ring HOT 12
- Agent should be able to accept `http::Request` HOT 2
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 ureq.