Files
flutter_opencode_client/lib/hive/hive_adapters.g.yaml
GT610 d6e17ff58c feat: Added Port Forwarding Functionality (#1083)
* feat: Added Port Forwarding Functionality

Implemented port forwarding functionality, including the following major changes:
- Added a port forwarding configuration model and related state management
- Added a port forwarding page and interaction logic
- Implemented forwarding connections between local and remote ports
- Integrated into the server features menu
- Added necessary Hive adapters and storage support
- Updated plugin configurations across all platforms to support the new feature

* feat (Port Forwarding): Added multilingual support and optimized implementation

Added multilingual support for the port forwarding feature, including Chinese, English, and other languages

Optimized the port forwarding implementation by adding connection management and error handling

Fixed an issue with state persistence when updating port forwarding configurations

Updated related dependencies and submodules

* fix(port_forward): Fixed port forwarding error handling and redesigned the configuration dialog

Handled uncaught errors when port forwarding is disabled or during connection attempts

Extracted the configuration dialog into a standalone component and added port range validation

* fix(port_forward): Fixed issues with port forwarding connection management and UI layout

Fixed an issue where port forwarding connections were not closed properly; now uses `clientGetter` to delay the retrieval of `SSHClient`
Added cleanup logic when connections are closed to prevent memory leaks

Added a `mounted` check in `PortForwardPage` to prevent operations from executing after the component is unmounted

Wrapped the configuration dialog content in a `SingleChildScrollView` to prevent content overflow

* fix(port_forward): Fixed a concurrent modification exception that occurred when closing a port forwarding connection

Fixed a concurrent modification exception that could occur when closing a local forwarding entry by copying the connection list to prevent modifications to the collection during iteration. Also improved the UI by using theme colors and added error handling for configuration saving.

* fix(port_forward_provider): Fixed an issue where entries were not properly removed when port forwarding was stopped

When port forwarding is stopped, ensure that the corresponding entries are removed from the _forwards map. Additionally, before adding a new forwarding rule, check for and close any existing forwarding rules with the same ID to prevent resource leaks.

* refactor(l1n): Remove unused localization and remote host port translations

* fix(port_forward_provider): Handle errors when closing port forwarding

Add error handling to prevent the program from crashing due to exceptions when closing port forwarding

* refactor(port_forward): Refactor port forwarding state management to use serverId

Directly link port forwarding state management to the server ID to simplify parameter passing

Remove direct dependencies on Spi and use serverId as the core identifier instead

Update relevant providers and page logic to accommodate the new state structure

* fix(port_forward): Fixed a race condition issue in port forwarding operations

Added an _inFlight collection to prevent duplicate operations

Added a _saving state when saving configurations to prevent duplicate submissions

Automatically cleans up forwarding when changes in server connection status are detected

* refactor(port_forward_provider): Remove unnecessary concurrency control logic

Simplify the `toggleForward` method by removing concurrency control for the `_inFlight` collection, as it is not required in the current scenario
2026-03-23 19:38:58 +08:00

248 lines
3.8 KiB
YAML

# Generated by Hive CE
# Manual modifications may be necessary for certain migrations
# Check in to version control
nextTypeId: 11
types:
PrivateKeyInfo:
typeId: 1
nextIndex: 2
fields:
id:
index: 0
key:
index: 1
Snippet:
typeId: 2
nextIndex: 5
fields:
name:
index: 0
script:
index: 1
tags:
index: 2
note:
index: 3
autoRunOn:
index: 4
Spi:
typeId: 3
nextIndex: 16
fields:
name:
index: 0
ip:
index: 1
port:
index: 2
user:
index: 3
pwd:
index: 4
keyId:
index: 5
tags:
index: 6
alterUrl:
index: 7
autoConnect:
index: 8
jumpId:
index: 9
custom:
index: 10
wolCfg:
index: 11
envs:
index: 12
id:
index: 13
customSystemType:
index: 14
disabledCmdTypes:
index: 15
VirtKey:
typeId: 4
nextIndex: 45
fields:
esc:
index: 0
alt:
index: 1
home:
index: 2
up:
index: 3
end:
index: 4
sftp:
index: 5
snippet:
index: 6
tab:
index: 7
ctrl:
index: 8
left:
index: 9
down:
index: 10
right:
index: 11
clipboard:
index: 12
ime:
index: 13
pgup:
index: 14
pgdn:
index: 15
slash:
index: 16
backSlash:
index: 17
underscore:
index: 18
plus:
index: 19
equal:
index: 20
minus:
index: 21
parenLeft:
index: 22
parenRight:
index: 23
bracketLeft:
index: 24
bracketRight:
index: 25
braceLeft:
index: 26
braceRight:
index: 27
chevronLeft:
index: 28
chevronRight:
index: 29
colon:
index: 30
semicolon:
index: 31
f1:
index: 32
f2:
index: 33
f3:
index: 34
f4:
index: 35
f5:
index: 36
f6:
index: 37
f7:
index: 38
f8:
index: 39
f9:
index: 40
f10:
index: 41
f11:
index: 42
f12:
index: 43
shift:
index: 44
NetViewType:
typeId: 5
nextIndex: 3
fields:
conn:
index: 0
speed:
index: 1
traffic:
index: 2
ServerFuncBtn:
typeId: 6
nextIndex: 10
fields:
terminal:
index: 0
sftp:
index: 1
container:
index: 2
process:
index: 3
snippet:
index: 5
iperf:
index: 6
systemd:
index: 8
portForward:
index: 9
ServerCustom:
typeId: 7
nextIndex: 9
fields:
pveAddr:
index: 1
pveIgnoreCert:
index: 2
cmds:
index: 3
preferTempDev:
index: 4
logoUrl:
index: 5
netDev:
index: 6
scriptDir:
index: 7
pvePwd:
index: 8
WakeOnLanCfg:
typeId: 8
nextIndex: 3
fields:
mac:
index: 0
ip:
index: 1
pwd:
index: 2
SystemType:
typeId: 9
nextIndex: 3
fields:
linux:
index: 0
bsd:
index: 1
windows:
index: 2
PortForwardConfig:
typeId: 10
nextIndex: 8
fields:
id:
index: 0
name:
index: 1
localHost:
index: 2
localPort:
index: 3
remoteHost:
index: 4
remotePort:
index: 5
description:
index: 6
serverId:
index: 7