Skip to content
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

feat: custom timeout and contextTimeout flag in response #4022

Merged
merged 2 commits into from
Nov 29, 2023

Conversation

nityanandagohain
Copy link
Member

Fixes #4021

Custom timeout can be set by setting the timeout header.
timeout:120
Added it in header as I don't want to unmarshal the payload in middleware.

If context timeout occurs, the response looks like

{
    "status": "success",
    "data": {
        "contextTimeout": true,
        "contexTimeoutMessage": "Result might contain incomplete data due to context timeout, set timeout header for setting custom timeout in seconds eg:- timeout:120",
        "resultType": "",
        "result": [
 .........

let me know if you have any suggestions.

@nityanandagohain nityanandagohain merged commit 7451e88 into develop Nov 29, 2023
11 checks passed
@nityanandagohain nityanandagohain deleted the issue_4021 branch November 29, 2023 03:40
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Allow custom timeout and set a flag if the response contains partial data.
2 participants