-
Notifications
You must be signed in to change notification settings - Fork 276
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
If ACL Handler response error,satck.root_state_accessor_stub.get_object_by_path() will not return #247
Comments
There are details of this operation rep_path and object
|
From the processing logs of the acl handler, the error return inside this ts-sdk is not returned to the internal cyfs-stack, probably because there is a problem with the js layer, which causes the request to be blocked and needs to wait for a timeout before it returns Details
[2023-04-28 20:14:26.293909 +08:00] INFO [ThreadId(4)] [component\cyfs-stack\src\non_api\handler\handler.rs:71] non acl handler resp: chain=acl, category=acl, req=/qa_test_token/share-9tGpLNniyP36axfCsdgDe9ogScdL4mcqXyb31gwsLh4L, action: Response, response: action: Accept |
@weiqiushi If DynamicTokenHandler.call() return cyfs.Err() has the some issuse. |
The processing logic here is: When the call() of Routine returns cyfs.Err(), it means that an error occurred in the processing function itself, and this error will not be returned to the calling end. The above processing logic is common to all handlers back to this issue, you MUST return Ok({action: cyfs.AclAction.Reject}) when you want caller recv a acl reject error. |
The current user layer registered Handler, in the case of return Err (), is equivalent to the SDK internal processing error, this case does not do a timely response to the caller, so need to wait for a timeout before returning, this is not very friendly, need to improve Consider in the ws-based event system, the unified introduction of such errors error packet to deal with, that the event response side of the error, so that the upper layer can receive timely feedback and continue the subsequent process |
…state_accessor_stubget_object_by_path-will-not-return' into main
This logical improvement: In the case that the handler callback returns Err(e), the processing is considered to have failed, which is equivalent to the failure of the entire processing logic of the callback, using the default action of the handler's registration as the processing result To handle this case, a CYFS/src/component/cyfs-lib/src/base/protocol.rs Lines 33 to 34 in 3888288
|
@lurenpluto cyfs ts-sdk reported an error when codec.encode_string
|
This issuse has been fixed,it will return error success.
|
…ckroot_state_accessor_stubget_object_by_path-will-not-return' into main
Describe the bug
If I set ACL handler event return response : cyfs.Err(cyfs.BuckyError.new_dec_error(match_response_error,"request set response_error")), the function will satck.root_state_accessor_stub.get_object_by_path() will not return
zone-simulator_133340_rCURRENT.log
Details
The text was updated successfully, but these errors were encountered: