Httpclient.Timeout after 100 second
-
ShakeebAhmed
- Posts: 22
- Joined: Wed Nov 12, 2014 2:22 pm
Httpclient.Timeout after 100 second
Hello,
We are getting Httpclient.Timeout error after 100 second while loading large dataset. How to increase that httpclient timeout? Below are the details what we are using.
Version - 2025.4.3
Stimulsoft.Data.GraphQL - 2025.4.3 --> Seems like problem is somewhere here as we uses graphql query and that get's timeout.
Tech - .Net core, Angular
We are trying to export the report which uses datasource of graphql and it does works well with 10K records but when I change it to 100K, it throws the timeout error in our custom export feature "report.Render(false)". Tried to extend timeout of viewer but it didn't works.
Thanks.
We are getting Httpclient.Timeout error after 100 second while loading large dataset. How to increase that httpclient timeout? Below are the details what we are using.
Version - 2025.4.3
Stimulsoft.Data.GraphQL - 2025.4.3 --> Seems like problem is somewhere here as we uses graphql query and that get's timeout.
Tech - .Net core, Angular
We are trying to export the report which uses datasource of graphql and it does works well with 10K records but when I change it to 100K, it throws the timeout error in our custom export feature "report.Render(false)". Tried to extend timeout of viewer but it didn't works.
Thanks.
Re: Httpclient.Timeout after 100 second
Hello
For web requests please use (seconds)
For web requests please use
Code: Select all
StiAngularViewerOptions options.Server.RequestTimeout-
ShakeebAhmed
- Posts: 22
- Joined: Wed Nov 12, 2014 2:22 pm
Re: Httpclient.Timeout after 100 second
Hello Vadim,
Sorry for being late on the response but unfortunately it didn't works after updating RequestTimout as it still get expired after 100 seconds.
What we wanted to achieve here is:
1. Our report uses graphQL as an datasource, data may get's vary depending on the query hence we want the report to wait till they receive data to fill show report but it does not wait and throws timeout error.
2. To avoid this, what we did was try to export the pdf, excel, html of that report instead of viewer to make it easy for processing but we did notice issues in that too. Like if you below code where we are trying to setup data sources for report so that we can handle timeout if api requires more time to return the result set and it does works too but when we did set that result in the report data it still hit the data source to get it when we did Not sure what we are missing here.
Getting Report Object ready:
Fetching manual data and setting up datasource of report:
Export pdf code:
Notes:
- In report.RegData("NAME",table); NAME is the same data source name in designer that we have.
- I did tried to remove Datasource from dictionary and it returns blank report
- Did tried Dictionary synchronize too but still it didn't works.
The issue we are facing is even if we are setting up datasouce to report it still try to fetch the data again when we do. How can we stop that and also is it the right way of setting up datasource? (Ref.) Attached picture of report designer to just let you know what we did so far.
Thanks. Sorry for long message but trying to explain all key things so that you can help us.![Image]()
Sorry for being late on the response but unfortunately it didn't works after updating RequestTimout as it still get expired after 100 seconds.
What we wanted to achieve here is:
1. Our report uses graphQL as an datasource, data may get's vary depending on the query hence we want the report to wait till they receive data to fill show report but it does not wait and throws timeout error.
2. To avoid this, what we did was try to export the pdf, excel, html of that report instead of viewer to make it easy for processing but we did notice issues in that too. Like if you below code where we are trying to setup data sources for report so that we can handle timeout if api requires more time to return the result set and it does works too but when we did set that result in the report data it still hit the data source to get it when we did
Code: Select all
report.Render(false);Getting Report Object ready:
Code: Select all
var report = new StiReport();
var data = _context.GetReportById(id);
report.LoadPackedReportFromString(data.PacakedDataString);Code: Select all
var gql = report.Dictionary.DataSources.OfType<StiGraphQLSource>().First();
if (gql != null)
{
var gqlQuery = ((Stimulsoft.Report.Dictionary.StiGraphQLDatabase)gql.Dictionary.Databases.Items[0]).Query;
var gqlUrl = ((Stimulsoft.Report.Dictionary.StiGraphQLDatabase)gql.Dictionary.Databases.Items[0]).EndPoint;
// Execute GraphQL manually
var result = await ExecuteGraphQL(
endpoint: gqlUrl,
query: gqlQuery,
variables: null,
timeoutSeconds: 1200
);
//report.Dictionary.DataSources.Remove(gql);
//var gqlDb = report.Dictionary.Databases.OfType<StiGraphQLDatabase>().FirstOrDefault();
//if (gqlDb != null)
// report.Dictionary.Databases.Remove(gqlDb);
var items = (JArray)result[gql.Name]["items"]; // depends on your API
var table = ToDataTable(items);
//report.RegBusinessObject("Connection", result);
//report.RegBusinessObject($"{gql.Name}_Items", items);
report.RegData($"{gql.Name}_Items", table);
//report.Dictionary.Synchronize();
}Code: Select all
var service = new StiPdfExportService();
service.ExportPdf(report, stream, settings);- In report.RegData("NAME",table); NAME is the same data source name in designer that we have.
- I did tried to remove Datasource from dictionary and it returns blank report
- Did tried Dictionary synchronize too but still it didn't works.
The issue we are facing is even if we are setting up datasouce to report it still try to fetch the data again when we do
Code: Select all
report.Render(false);Thanks. Sorry for long message but trying to explain all key things so that you can help us.
- Attachments
-
- Report_Designer_Sample.png (238.52 KiB) Viewed 361 times
Re: Httpclient.Timeout after 100 second
Hello
Maybe you should extend Query Timeout for database?
Maybe you should extend Query Timeout for database?
-
ShakeebAhmed
- Posts: 22
- Joined: Wed Nov 12, 2014 2:22 pm
Re: Httpclient.Timeout after 100 second
Hello,
We are not using MySQL as we do uses GraphQL (we manage connection timeout of DB request and stuff). We need to understand how do I stop report data fetching mechanism and use my data that I assign to it as it is currently calling report data while we are doing report.Render().
Thanks.
We are not using MySQL as we do uses GraphQL (we manage connection timeout of DB request and stuff). We need to understand how do I stop report data fetching mechanism and use my data that I assign to it as it is currently calling report data while we are doing report.Render().
Thanks.
-
ShakeebAhmed
- Posts: 22
- Joined: Wed Nov 12, 2014 2:22 pm
Re: Httpclient.Timeout after 100 second
Kind Reminder
-
ShakeebAhmed
- Posts: 22
- Joined: Wed Nov 12, 2014 2:22 pm
Re: Httpclient.Timeout after 100 second
Hello Vadim,
Is there any updates on this?
Thanks.
Is there any updates on this?
Thanks.
Re: Httpclient.Timeout after 100 second
Hello
You can't stop data fetching during report generation.
Can you send us full error stack trace?
You can't stop data fetching during report generation.
Can you send us full error stack trace?
-
ShakeebAhmed
- Posts: 22
- Joined: Wed Nov 12, 2014 2:22 pm
Re: Httpclient.Timeout after 100 second
Hello,
We are getting "Timeout error after 100 sec" if report data fetching exceeded the time limit. As we are using "report.Render(false)" method to render report and then export it, 99% times our dataset is in large scale and would take approx. 5-10 min to load them. Hence we tried to load them by ourself so that we can assign it to report dictionary to use it instead of re-loading again during rendering. Is there any way to extend time in graphql request if we can't stop report to fetching data calls?
Thanks.
We are getting "Timeout error after 100 sec" if report data fetching exceeded the time limit. As we are using "report.Render(false)" method to render report and then export it, 99% times our dataset is in large scale and would take approx. 5-10 min to load them. Hence we tried to load them by ourself so that we can assign it to report dictionary to use it instead of re-loading again during rendering. Is there any way to extend time in graphql request if we can't stop report to fetching data calls?
Thanks.
-
Lech Kulikowski
- Posts: 7568
- Joined: Tue Mar 20, 2018 5:34 am
Re: Httpclient.Timeout after 100 second
Hello,
There are no timeout settings for GraphQL in the designer. Try to check the IIS timeout settings.
Thank you.
There are no timeout settings for GraphQL in the designer. Try to check the IIS timeout settings.
Thank you.