Repository navigation
fix: own Feishu WebSocket readiness and resource lifecycle - #659
Merged
Merged
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Feishu's SDK
start()returns after initiating the connection; it does not block for the socket lifetime. The adapter currently treats that return as a disconnect, while SDKclose()leaves its executors alive. Quiet channels can also be restarted solely because no business message arrived.This PR makes the adapter the single owner of reconnect scheduling and waits for the SDK handshake before reporting CONNECTED. Transport health uses protocol ping/pong and synchronized SDK connection-state reads, so quiet channels do not trigger reconnects. Permanent stop cancels the transport and closes SDK/HTTP executors, including startup races and exceptional SDK shutdown.
Changes
Duration.ZERO; ERROR recovery and other adapter thresholds stay active.devbot identity/CardKit behavior. No Web/WebChat implementation or dependency changes.Compatibility
The pinned SDK has no public disposal/transport-status APIs. The wrapper uses a version-bound reflection bridge for
executor,httpClientandconn, with field-type checks and real SDK regression coverage. SDK upgrades require rechecking these contracts. The old Feishusilent_disconnect_threshold_secondssetting no longer causes reconnects; actual protocol/transport health replaces message-age detection. Details are indocs/compatibility/feishu-websocket-lifecycle.md.Validation
The JVM option matches application startup for existing Feishu HTTP tests. All fixtures use synthetic credentials and loopback peers. No live Feishu messages or production changes; these tests do not establish real-user delivery or multi-day reliability.