Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix: serverTimeout default to 0 (no timeout) #5325

Merged
merged 1 commit into from
Jun 7, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion config/config.default.js
Original file line number Diff line number Diff line change
Expand Up @@ -359,7 +359,7 @@ module.exports = appInfo => {
config.workerStartTimeout = 10 * 60 * 1000;

/**
* server timeout in milliseconds, default to 2 minutes.
* server timeout in milliseconds, default to 0 (no timeout).
*
* for special request, just use `ctx.req.setTimeout(ms)`
*
Expand Down
6 changes: 3 additions & 3 deletions index.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -330,7 +330,7 @@ declare module 'egg' {
* @property {Number} queryString.parameterLimit - parameter number limit, default 1000
* @property {String[]} enableTypes - parser will only parse when request type hits enableTypes, default is ['json', 'form']
* @property {Object} extendTypes - support extend types
* @property {String} onProtoPoisoning - Defines what action must take when parsing a JSON object with `__proto__`. Possible values are `'error'`, `'remove'` and `'ignore'`. Default is `'error'`, it will return `403` response when `Prototype-Poisoning` happen.
* @property {String} onProtoPoisoning - Defines what action must take when parsing a JSON object with `__proto__`. Possible values are `'error'`, `'remove'` and `'ignore'`. Default is `'error'`, it will return `400` response when `Prototype-Poisoning` happen.
*/
bodyParser: {
enable: boolean;
Expand All @@ -352,7 +352,7 @@ declare module 'egg' {
form: string[];
text: string[];
};
/** Default is `'error'`, it will return `403` response when `Prototype-Poisoning` happen. */
/** Default is `'error'`, it will return `400` response when `Prototype-Poisoning` happen. */
onProtoPoisoning: 'error' | 'remove' | 'ignore';
};

Expand Down Expand Up @@ -532,7 +532,7 @@ declare module 'egg' {
onClientError(err: Error, socket: Socket, app: EggApplication): ClientErrorResponse | Promise<ClientErrorResponse>;

/**
* server timeout in milliseconds, default to 2 minutes.
* server timeout in milliseconds, default to 0 (no timeout).
*
* for special request, just use `ctx.req.setTimeout(ms)`
*
Expand Down
Loading