cancel
Showing results for 
Search instead for 
Did you mean: 

RfcFunction.Invoke() is stuck when its session is destroyed

nobyk
Explorer
0 Kudos
130

We manage sessions implementing SAP.Middleware.Connector.ISessionProvider. I'm trying to cancel a session invoking SessionChanged event when the RFC call takes too long.

 

ISessionProvider.SessionChanged.Invoke(new RfcSessionEventArgs(RfcSessionManager.EventType.DESTROYED, sessionId))

 

I'm testing this cancellation logic using RFC_PING_AND_WAIT on 2 systems:

  • System A: Release:789 / KernelRelease:753 / PartnerRelease:750
  • System B: Release:789 / KernelRelease:781 / PartnerRelease:755

On the System A, it works as expected. RfcCommunicationCanceledException is thrown from CpicConnection.CpicReceive() with a message "Connection to (xxx.xxx.xxx.xxx,3300) with conversationID [xxxxxxx] was canceled".

However, the cancellation doesn't work on the System B. Besides, RfcFunction.Invoke() doesn't finish even after the wait time of RFC_PING_AND_WAIT passes. According to trace logs, it is stuck after obtaining a lock.

 

2024-06-13 11:41:50.601 [Thread 9] CpicConnection.CpicCancel requested lock for instance 30880833 of Object: System.Object

 

How can I make it work on the System B as well? If it is not possible, is there a way to know whether the destination supports the cancellation?

* It occurs on NCo 3.1.3.0, 3.1.4.0 and 3.1.4.3. I have not checked other versions.

View Entire Topic
MarkusTolksdorf
Product and Topic Expert
Product and Topic Expert
0 Kudos

Hello @nobyk , 

this is nothing that is to be discussed here. Please open a ticket, it could be a bug. It definitely requires a deeper analysis with traces of both cases. 

Best regards
Markus

nobyk
Explorer
0 Kudos
Thank you for your reply, @MarkusTolksdorf. Which channel is the best to open a ticket for the issue?
MarkusTolksdorf
Product and Topic Expert
Product and Topic Expert

A standard support ticket in SAP for me on component BC-MID-CON-NCO. See https://me.sap.com/

Best regards,
Markus