microsoft / botframework-sdk

Bot Framework provides the most comprehensive experience for building conversation applications.
MIT License
7.48k stars 2.44k forks source link

[Feature Request] User-configurable Direct Line timeout duration #3220

Closed nwhitmont closed 5 years ago

nwhitmont commented 7 years ago

As a user of the Bot Connector REST API, aka Direct Line, I would like to have the ability to configure the timeout length in seconds.

Thumbs up this comment to vote.

RodrigoRVieira commented 7 years ago

I have opened an issue that also refers to the 15 seconds timeout. With the direct line channel you can send the message you want to the user when a timeout occurs...

If we at least could send a better message than "POST to xxxBot timed out after 15s" when using channels like Telegram and Facebook.

nwhitmont commented 7 years ago

relates to #3122

BelvedereHenrique commented 7 years ago

I'm having some trouble with that. Since there is no way to configure the timeout, DirectLine keep sending double, sometimes even triple messages to my bot. Seens like it's trying again because the bot took too long to respond. Is there any workaround on that for now?

eanders-ms commented 6 years ago

@Ma3yTa What are you trying to accomplish? (Also, it is better to open a new issue than piggyback this one)

wladneto commented 6 years ago

Any good solution?

benbrown commented 5 years ago

Thank you for opening an issue against the Bot Framework SDK v3. As part of the Bot Framework v4 release, we’ve moved all v3 work to a new repo located at https://github.com/microsoft/botbuilder-v3. We will continue to support and offer maintenance updates to v3 via this new repo.

From now on, https://github.com/microsoft/botbuilder repo will be used as hub, with pointers to all the different SDK languages, tools and samples repos.

As part of this restructuring, we are closing all tickets in this repo.

For defects or feature requests, please create a new issue in the new Bot Framework v3 repo found here: https://github.com/microsoft/botbuilder-v3/issues

For Azure Bot Service Channel specific defects or feature requests (e.g. Facebook, Twilio, Teams, Slack, etc.), please create a new issue in the new Bot Framework Channel repo found here: https://github.com/microsoft/botframework-services/issues

For product behavior, how-to, or general understanding questions, please use Stackoverflow. https://stackoverflow.com/search?q=bot+framework

Thank you.

The Bot Framework Team

liamkernighan commented 5 years ago

@benbrown the same problem exists within v4. There is unnecessary messages about POST to endpoint failed (in Facebook and Telegram) with no way to suppress these messages or increase the timeout. Should I open a new issue, or is it better to reopen this one?

Kadae commented 4 years ago

Hahaha, 100500 years of this issues exists and Microsoft still closing eyes on this.

Kadae commented 3 years ago

The year is 2021. Still no fixes on this and issue is closed.

source5loo

EricDahlvang commented 3 years ago

Hi @Kadae

The 15 second timeout is a Direct Line service timeout. I'm not aware of plans to ever make this configurable in the future. This is not a bug, but is by design.

Some guidance for performing long operations within a bot can be found in this doc: https://docs.microsoft.com/en-us/azure/bot-service/bot-builder-howto-long-operations-guidance

If you require further assistance, please direct questions to Stack Overflow using the #botframework tag.

Kadae commented 3 years ago

Hello, @EricDahlvang!

Ok, don't touch 15 seconds timeout, but just make it silent and visible for developers only, not to the users. I just want to catch and hide this 500, 504, 503 errors from bot's messages, but I can't. All what I have is "onTurnErrorHandler", but I can't hide timeout errors...

Why bot SENDING THIS timeout message to the user? Why bot report this back to the client right to the chats? This is a only one problem for me in BotFramework, and this problem for me exists almost 4 years and looks like only one option is simple - just don't use BotFramework with Azure...

EricDahlvang commented 3 years ago

I do not understand. I am not aware of a problem which has existed for four years but remains unsolved. The Bot Framework protocol is restful, with a maximum time per call determined by the service between the client and the bot. Not every activity type is a two way POST. In the case of 'invoke' activities, the processing through the pipeline is synchronous.

It sounds like the timeout errors you are referring to are from the service to the client? Which client are you using, and which SDK?

Some other, in process methods, for handling long running operations include this dotnet sample: https://github.com/microsoft/BotBuilder-Samples/tree/main/experimental/immediate-accept-adapter/csharp_dotnetcore

The javascript sdk provides an 'immediateAccept' parameter, for the Adapter: https://github.com/microsoft/botbuilder-js/pull/2950

These are not published in the documentation, because long running operations should not be performed within the bot's web application, but rather via an external process, as demonstrated in this doc: https://docs.microsoft.com/en-us/azure/bot-service/bot-builder-howto-long-operations-guidance?view=azure-bot-service-4.0

Kadae commented 3 years ago

image

EricDahlvang commented 3 years ago

Okay, thank you for the screenshot. This looks like an exception returned from the service when it cannot reach the bot.

For a feature request, or to file a bug against the channel service, please open an issue here:

https://github.com/microsoft/BotFramework-Services/issues

HZ-SA-DSAI commented 2 years ago

Hello, I'm now facing a similar issue with Direct Line Speech channel, where the bot times out after 15 seconds. Is there any way to configure this or any workaround available so that it doesn't time out? Thanks!

clearab commented 2 years ago

@HZ-MS-CSA This is a very old, closed, issue that may or may not have anything to do with what you're experiencing. I'm going to open a new issue for you, could you please add additional information in the new issue? Specifically, what is happening, what causes it to happen, and what you would expect to happen instead. Thanks!