none
The call was disconnected while the following operation was in progress: 'None'. RRS feed

  • Question

  • We recently caught the following exception in a speech workflow:

     

    System.InvalidOperationException: The call was disconnected while the following operation was in progress: 'None'.

    [source = Microsoft.SpeechServer]

    [method call = Close]

    [stack trace =    at Microsoft.SpeechServer.Dialog.SpeechCompositeActivity.Close(Object sender, AsyncCompletedEventArgs e)

       at System.Workflow.ComponentModel.ActivityExecutorDelegateInfo`1.ActivityExecutorDelegateOperation.Run(IWorkflowCoreRuntime workflowCoreRuntime)

       at System.Workflow.Runtime.Scheduler.Run()]

     

    Anyone know what could be causing this?

     

    Thursday, July 19, 2007 5:22 PM

Answers

  • I apologize for not responding earlier.

     

    I attached to VS debugger to the w3wp process and made a call, but still the only exception I could reproduce was the CallDisconnectedException.

     

    Tuesday, August 7, 2007 2:11 PM

All replies

  • I reviewed our logs some investigating this.

     

    We attempted to do a transfer in a custom activity and got this error in the TransferCompleted event handler:

    System.InvalidOperationException: The original telephony session from which this session was created is not in the connected state.  The original session state is 'Disconnected'.

     

    Then we try to close the activity and that's what caused the above exception:

    System.InvalidOperationException: The call was disconnected while the following operation was in progress: 'None'.

     

     

    Should we not close the activity?  Or is there another way around this?

    Thursday, July 19, 2007 5:57 PM
  • When you call Close on your custom activity, are you passing the exception? If so, this is by design. The idea is that if your activity fails (due to an exception), it cleans itself up (closes) and then throws the exception so that the workflow can handle it. If you want to handle this exception locally, put your custom activity inside a SpeechSequenceActivity, and add a FaultHandlerActivity that catches the exception you're expecting.

     

    Dan

     

    Thursday, July 19, 2007 6:27 PM
  • No, I'm actually sending a null, because I don't want exceptions like this to bubble up.

     

    Also, the exception that is eventually caught by the FaultHandlerActivity is different from the one in the TransferComplete event handler.

    Thursday, July 19, 2007 6:46 PM
  • Can you confirm that it is actually your code that is calling Close(null) in this case? (I am wondering if another exception is being hit and the workflow is attempting to cancel things.)

     

    When you call Close(null), we do throw an exception if the call is no longer connected, but it would be a CallDisconnectedException.

     

    If you can repro this in the VS debugger, you could set VS to break on first-chance managed exceptions, in order to see the call-stack when it's thrown.

     

    Dan

    Thursday, July 19, 2007 8:44 PM
  • When I try to repro this in the debugger, I get the CallDisconnectedException.
    Thursday, July 19, 2007 9:45 PM
  • Can you just attach VS to the correct w3wp.exe process? Attach only for managed debugging (not for workflow debugging.) If you don't know which w3wp it is, use the command "iisapp". You want the instance of w3wp that is running your IIS application pool.
    Thursday, July 19, 2007 11:18 PM
  • Sectrean,

    Can you let us know the status of your issue?

    Wednesday, August 1, 2007 10:38 PM
  • I apologize for not responding earlier.

     

    I attached to VS debugger to the w3wp process and made a call, but still the only exception I could reproduce was the CallDisconnectedException.

     

    Tuesday, August 7, 2007 2:11 PM