cancel
Showing results for 
Search instead for 
Did you mean: 

RESTful Webservice "Operation Timed Out."

Former Member
0 Kudos

Version BI4.1 SP4 Patch 4

Clustered Windows Environment

One WACS Service (default settings)

Using C# HTTPWebRequest and HTTPWebResponse for all the steps

Workflow

1. POST Login (using Enterprise)

2. PUT Refresh document no parameters (using docid)

3. GET Refreshed document - This Step Fails (Operation timed out)

4. POST Logoff - This step fails (Operation timed out)

The workflow fails about 90% of the tries. We also noticed that some of the steps take a long time to process. For example refreshing the document in Launchpad takes about 13 seconds, but using REST calls it varies from 30 to 120 seconds

When we do the same steps using a REST Client (in browser) we are able to process all the steps without failures. We did notice the same processing time as mentioned above.

Report in BI Launchpad works without any issues.

Please advise.

Accepted Solutions (0)

Answers (1)

Answers (1)

former_member197386
Active Contributor
0 Kudos

Hello Guru,

By default RESTful API retrieve LOV (List Of Values) for each parameters and that could be very expansive.

Could you try to add the query param "?lovInfo=false" on /parameters calls?

Regards,

Anthony

Former Member
0 Kudos

Anthony,

Implemented the changes suggested and we do see improvement in the refresh time.. But getting the report details after the refresh is still timing out.

Regards

Guru

former_member197386
Active Contributor
0 Kudos

Which call is going in timeout exactly?

Is it [GET] /documents/1234 for instance?

Is your document into an Inbox?

Anthony

Former Member
0 Kudos

Yes, the GET /documents/{docid}/reports/1 call after the refresh is what is timing out.. The document is not sent to an inbox..

In addition, I used the token generated in my code and used it in a REST client and I was able to retrieve the document without any issues.

Guru

former_member197386
Active Contributor
0 Kudos

In which format do you get the report ? Is it big?

Anthony

Former Member
0 Kudos

We are just reading it as XML for now.. It is not big.. Usually the report has about 10 records. max (20)

Following is the code snippet -

HttpWebRequest request = (HttpWebRequest) HttpWebRequest.Create("...../{docid}/reports/1");

request.Method = "GET";

request.Headers.Add("X-SAP-LogonToken",token);

request.ContentType = "application/xml";

HttpWebResponse response = (HttpWebResponse) request.GetResponse(); --> This is the step that fails with operation timed out.

... Reading the output in a StreamReader for further processing.

Regards,

Guru

former_member197386
Active Contributor
0 Kudos

Unfortunately, I'm not an expert in C#...

Normally, the HTTP header allowing to set the wished output format is "Accept".

"Content-Type" is to defined which is the format of the data you sent to the server (when you send data).

Not sure this can help...

Maybe fiddler trace could help?

Anthony

Former Member
0 Kudos

Anthony,

I did try your suggestion, but it did not matter when we had the Accept parameter or not.

Strangely, though we just stopped a couple of our servers and the timeout error has not occurred in the last 5 times I have run the same code.. And the responses are pretty quick too.

So, I am guessing that the processing time it is taking for the application to read the content from the repository/memory was not fast enough..

Now have to figure out why the system is slow when those servers were up and running.. . Oddly though we do not see that in the BI Launchpad..

You have been a great help and thank you soooo much for taking the time to look into the problem and all the support you provide to the SCN community..

Anthony you are AWESOME!!

Regards

Guru

former_member197386
Active Contributor
0 Kudos

You're welcome Guru.

You will find other people from our team here (Eric, Stéphane, Bogdan, Saritha, Dan, etc...)

Hope you will troubleshoot your last issue quickly, maybe with the help of SAP support?

Anthony

PS: you could mark the question as answered to close it

Former Member
0 Kudos

Hi,

i know this thread is old but recently I have implemented the same workflow in Java using RESTful.  My program:

1) login to BO

2) refreshes the document and sometimes applies the filter and save the content to excel/pdf file.

3) logoff

I am using Java HttpConnection using the default timeout.  In other words, I do not set any timeout and use whatever is default in HttpConnection.  I have noticed my program hung while refreshing the document at times.

I read the above comments and saw someone stating RESTful API retrieves all LOV.  Will there be any data missing to omit retrieving LOVs?

What do you think causes the refresh to hang and any thoughts how to resolve it?

Thank you.

eric_festinger
Contributor
0 Kudos

hello

Retrieving LOV is one specific task. Refreshing a report is another specific task.

In your workflow, you mention only the second one.

Moreover, we made some improvements while refreshing a report, but it depends on the version you have.

How long does it take before your programs hangs? And how long does it take to refresh the same document in BI LaunchPad?

Regards,

eric

Former Member
0 Kudos

Hi Eric,

Launch Pad has no problem refreshing the document, only RESTful API does.  It hangs for 24 hours and I ended up stopping my application.  I am using BO 4.1 SP 7.

Thank you.

daniel_paulsen
Active Contributor
0 Kudos

Hi Raghunath,

It sounds like there's a firewall or load balancer in front of your application that potentially times out a port if no response returns in X seconds.  If the port gets closed before the response can come back, it never will come back.  Is it possible that this is the case?  What's the average refresh time in BI Launchpad?  Are you able to test your code on the same server that BI Launchpad is running on?  My guess is that the report is refreshing, but gets blocked on the return trip.

Dan