문제

When I try to call a RPC function, which generated from an IDL file by midl tool, it blocks around 20 seconds (at the NdrGetBuffer function) if the IP bound in its RPC_BINDING_HANDLE is unreachable.

I tried to call RpcMgmtSetComTimeout function with RPC_C_BINDING_MIN_TIMEOUT value on its RPC_BINDING_HANDLE before calling that RPC function, but no help, still need to wait ~20 seconds.

Is there any way to shorten the timeout wait time on this case? Thanks a lot!

Elliott

도움이 되었습니까?

해결책

I haven't tried this, but this link suggests that RpcSetBindingOption with RPC_C_OPT_CALL_TIMEOUT should allow you to set the callout.

However, there's still a 20 second timeout on the first call (so the server can start).

라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 StackOverflow
scroll top