fix(PortProxy): Improve timeout handling for port proxy connections
This commit is contained in:
parent
59625167b4
commit
942e0649c8
@ -1,5 +1,11 @@
|
|||||||
# Changelog
|
# Changelog
|
||||||
|
|
||||||
|
## 2025-02-21 - 3.9.2 - fix(PortProxy)
|
||||||
|
Improve timeout handling for port proxy connections
|
||||||
|
|
||||||
|
- Added console logging for both incoming and outgoing side timeouts in the PortProxy class.
|
||||||
|
- Updated the timeout event handlers to ensure proper cleanup of connections.
|
||||||
|
|
||||||
## 2025-02-21 - 3.9.1 - fix(dependencies)
|
## 2025-02-21 - 3.9.1 - fix(dependencies)
|
||||||
Ensure correct ordering of dependencies and improve logging format.
|
Ensure correct ordering of dependencies and improve logging format.
|
||||||
|
|
||||||
|
@ -3,6 +3,6 @@
|
|||||||
*/
|
*/
|
||||||
export const commitinfo = {
|
export const commitinfo = {
|
||||||
name: '@push.rocks/smartproxy',
|
name: '@push.rocks/smartproxy',
|
||||||
version: '3.9.1',
|
version: '3.9.2',
|
||||||
description: 'a proxy for handling high workloads of proxying'
|
description: 'a proxy for handling high workloads of proxying'
|
||||||
}
|
}
|
||||||
|
@ -279,8 +279,14 @@ export class PortProxy {
|
|||||||
to.on('error', handleError('outgoing'));
|
to.on('error', handleError('outgoing'));
|
||||||
socket.on('close', handleClose('incoming'));
|
socket.on('close', handleClose('incoming'));
|
||||||
to.on('close', handleClose('outgoing'));
|
to.on('close', handleClose('outgoing'));
|
||||||
socket.on('timeout', handleError('incoming'));
|
socket.on('timeout', () => {
|
||||||
to.on('timeout', handleError('outgoing'));
|
console.log(`Timeout on incoming side from ${remoteIP}`);
|
||||||
|
cleanupOnce();
|
||||||
|
});
|
||||||
|
to.on('timeout', () => {
|
||||||
|
console.log(`Timeout on outgoing side from ${remoteIP}`);
|
||||||
|
cleanupOnce();
|
||||||
|
});
|
||||||
socket.on('end', handleClose('incoming'));
|
socket.on('end', handleClose('incoming'));
|
||||||
to.on('end', handleClose('outgoing'));
|
to.on('end', handleClose('outgoing'));
|
||||||
};
|
};
|
||||||
|
Loading…
x
Reference in New Issue
Block a user