laravel / octane

Supercharge your Laravel application's performance.
https://laravel.com/docs/octane
MIT License
3.73k stars 289 forks source link

408 Request Timeout #835

Closed lahan212 closed 6 months ago

lahan212 commented 6 months ago

Octane Version

2.3

Laravel Version

10.0

PHP Version

8.2

What server type are you using?

Swoole

Server Version

nginx 1.21.4

Database Driver & Version

MySQL 5.7.40

Description

# map $http_upgrade $connection_upgrade { default upgrade; '' close; } server { listen 80; listen 443 ssl http2; server_name address.com; index index.php index.html index.htm default.php default.htm default.html; root /web_app/wwwroot/address.com/public/; if ($server_port !~ 443){ rewrite ^(/.*)$ https://$host$1 permanent; }

HTTP_TO_HTTPS_END

ssl_certificate    /www/server/panel/vhost/cert/address.com/fullchain.pem;
ssl_certificate_key    /www/server/panel/vhost/cert/address.com/privkey.pem;
ssl_protocols TLSv1.1 TLSv1.2 TLSv1.3;
ssl_ciphers EECDH+CHACHA20:EECDH+CHACHA20-draft:EECDH+AES128:RSA+AES128:EECDH+AES256:RSA+AES256:EECDH+3DES:RSA+3DES:!MD5;
ssl_prefer_server_ciphers on;
ssl_session_cache shared:SSL:10m;
ssl_session_timeout 10m;
add_header Strict-Transport-Security "max-age=31536000";
error_page 497  https://$host$request_uri;
charset utf-8;
#SSL-END

#ERROR-PAGE-START  Error page configuration, allowed to be commented, deleted or modified
#error_page 404 /404.html;
#error_page 502 /502.html;
#ERROR-PAGE-END

#PHP-INFO-START  PHP reference configuration, allowed to be commented, deleted or modified
include enable-php-82.conf;
#PHP-INFO-END

#REWRITE-START URL rewrite rule reference, any modification will invalidate the rewrite rules set by the panel
include /www/server/panel/vhost/rewrite/address.com.conf;
#REWRITE-END

# Forbidden files or directories
location ~ ^/(\.user.ini|\.htaccess|\.git|\.svn|\.project|LICENSE|README.md)
{
    return 404;
}

# Directory verification related settings for one-click application for SSL certificate
location ~ \.well-known{
    allow all;
}

location ~ .*\.(gif|jpg|jpeg|png|bmp|swf)$
{
    expires      30d;
    error_log /dev/null;
    access_log off;
}

location ~ .*\.(js|css)?$
{
    expires      12h;
    error_log /dev/null;
    access_log off; 
}
access_log  /www/wwwlogs/address.com.log;
error_log  /www/wwwlogs/address.com.error.log;

#octane
location /index.php {
    try_files /not_exists @octane;
}

location / {
    try_files $uri $uri/ @octane;
}

location = /favicon.ico { access_log off; log_not_found off; }
location = /robots.txt  { access_log off; log_not_found off; }
 location @octane {
    set $suffix "";

    if ($uri = /index.php) {
        set $suffix ?$query_string;
    }

    proxy_http_version 1.1;
    proxy_connect_timeout 21600;
    proxy_send_timeout 21600;
    proxy_read_timeout 21600;
    proxy_set_header Host $http_host;
    proxy_set_header Scheme $scheme;
    proxy_set_header SERVER_PORT $server_port;
    proxy_set_header REMOTE_ADDR $remote_addr;
    proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
    proxy_set_header Upgrade $http_upgrade;
    proxy_set_header Connection $connection_upgrade;

    proxy_pass http://127.0.0.1:8001$suffix;
}

} Screenshot 2024-02-06 115734 Screenshot 2024-02-06 115906 Screenshot 2024-02-06 120257

Steps To Reproduce

I created a function to display the data from MySQL into HTML with the server processing it for more than 2 minutes, and it always appears as 408 Request Timeout after 2 minutes.

lianmafutra commented 6 months ago

same issue , timeout 408 more than 120 seconds request ..

driesvints commented 6 months ago

Hey there,

Can you first please try one of the support channels below? If you can actually identify this as a bug, feel free to open up a new issue with a link to the original one and we'll gladly help you out.

Thanks!