ivmarkov / rust-esp32-std-demo

Rust on ESP32 STD demo app. A demo STD binary crate for the ESP32[XX] and ESP-IDF, which connects to WiFi, Ethernet, drives a small HTTP server and draws on a LED screen.
Apache License 2.0
784 stars 105 forks source link

HTTP server issues #100

Closed flyaruu closed 2 years ago

flyaruu commented 2 years ago

Hi, got the demo working without trouble, but the httpd server seems flakey, I seem to have two issues:

I see a seemingly related post: https://www.esp32.com/viewtopic.php?t=10179 (but not in Rust)

I've followed the suggested solutions (purging LRU, reducing # of sessions and sockets, to no avail:

    let mut conf: esp_idf_svc::http::server::Configuration = Default::default();
    conf.lru_purge_enable = true;
    conf.max_open_sockets = 1;
    conf.max_sessions = 1;
    let mut server = esp_idf_svc::http::server::EspHttpServer::new(&conf)?;

Any ideas?

ivmarkov commented 2 years ago

I'll close this as another user has identified and fixed the issue in esp-idf-svc main/master branch. Not released yet though.

The user identified another issue unfortunately, related to how response headers are processed. This one has to wait for the upcoming HTTPD server rework, which will significantly change the shape of the traits.

flyaruu commented 2 years ago

Great news, thanks for following up, I'll make sure to follow that repo as well.

flyaruu commented 2 years ago

I see that the 'running out of sockets' problem has been fixed, but I can not connect from curl or Postman at all. Firefox seems to work. I'll create a new issue for that.