VL-WEB, SSL and pending request

This Q&A forum allows users to post and respond to "How Do I Do ....." questions. Please do not use to report (suspected) errors - you must use your regional help desk for this. The information contained in this forum has not been validated by LANSA and, as such, LANSA cannot guarantee the accuracy of the information.
Post Reply
kno_dk
Posts: 131
Joined: Tue Feb 23, 2016 12:00 am

VL-WEB, SSL and pending request

Post by kno_dk » Thu Dec 19, 2019 10:54 pm

Hi.

I have a weird issue. I have for the past several years had a customer running a VL-WEB application on port 8080 on an IBM I. Now we have added a new http-server on the same box, with the same VL-WEB application but now with HTTPS. It works most of the time perfect.
But if I open the application, select an item group in the menu and then show the items and I then do not touch the application for e.g. 10 minutes and then select some other item groups the request to the server will get in a status pending in the browser console for nearly 1 minute - see the attached image
PendingRequest.PNG
PendingRequest.PNG (74.54 KiB) Viewed 1101 times
.

If I use the application, then it response nearly every time below 1 sec. I have also tried to use the application on iPhone/iPad and there when I left it untouched for a e.g. 10 minutes the application fails when I try to use it again. Here is the error:
1D324209-D40F-4F64-84D0-D0B3602F53C5.png
1D324209-D40F-4F64-84D0-D0B3602F53C5.png (65.72 KiB) Viewed 1101 times
I have tried it on an android phone there is the same pending, but it does not fail. I have tried it in the LANSA Mobile application also, and there it also fails when the response time is too long.

I cannot force the same behavior in the old port 8080 http-server.

There are not errors on the IBM I.

Is there anybody who have a suggestion what the error could be?

/Klaus

JamesDuignan
Posts: 81
Joined: Thu Nov 26, 2015 1:43 pm

Re: VL-WEB, SSL and pending request

Post by JamesDuignan » Fri Dec 20, 2019 8:46 am

Hi Klaus,

This is a failed request to the server. Most likely your session has timed out and is not being handled.

Look in your server module for a #com_owner.startsession command, by default this is set to 300 seconds, which can be increased by adding a value for the time out parameter. e.g. #com_owner.startsession timeout(600)
https://docs.lansa.com/14/en/lansa016/p ... ession.htm
https://docs.lansa.com/14/en/lansa017/c ... 3_0075.htm

Also, it is worthwhile adding in a global catch for server failures, this way you can handle them from your application thus stopping the nasty failed paged, produce a message or directive for the user (e.g. make them login again to obtain a new session) and help you in trying to debug the issue.

https://docs.lansa.com/14/en/lansa016/p ... failed.htm

Code: Select all

Evtroutine Handling(#SYS_WEB.RequestFailed) Handled(#Handled) Request(#Request) Reason(#Reason)

#sys_web.Console.Log( ('Routine &1 failer for reason: &2').Substitute( #Request.Routine #Reason ) )

#Handled := True

Case (#Reason)

When (= 'ServerError')

#com_owner.uHandleServerError

When (= 'SessionInvalid')

#com_owner.uHandleSessionTimeOut

When (= 'LicenseInvalid')

#com_owner.uHandleInvalidLicense

Endcase

Endroutine
Regards,
James

kno_dk
Posts: 131
Joined: Tue Feb 23, 2016 12:00 am

Re: VL-WEB, SSL and pending request

Post by kno_dk » Fri Dec 27, 2019 10:53 pm

Hi.

I have this in my ValidateLogin srvroutine: #COM_OWNER.StartSession Timeout(604800)

The strange thing is that this is only a problem on the HTTP-server which has enabled SSL. It is the same application, it is the same LANSA installation, same set of data - the only difference is the SSL.

I will try to setup the RequestFailed and see what that will tell me.

/klaus

kno_dk
Posts: 131
Joined: Tue Feb 23, 2016 12:00 am

Re: VL-WEB, SSL and pending request

Post by kno_dk » Sun Dec 29, 2019 9:56 pm

Hi.

I have now tested with the RequestFailed. The status I get back is ServerError. There is not joblog on the IBM I, No x_err.log.

I do not get the nasty error message on the screen anymore because I add some error handling on the page.

But It is strange that the HTTPS part is still ending up with this ServerError and long responstime (sometimes), but the HTTP is not.

Is there any PTF's for the SSL/HTTPS part of the HTTP-server on the IBM I?

Any suggestions?

/Klaus

JamesDuignan
Posts: 81
Joined: Thu Nov 26, 2015 1:43 pm

Re: VL-WEB, SSL and pending request

Post by JamesDuignan » Thu Jan 09, 2020 8:11 am

Hi Klaus,

I have never set up SSL on an IBM i, but it could possibly be the SSL setting for IBM i itself has timed out.
Have you checked whether there is an SSL IO timeout setting on the IBM i side?

Regards,
James

Post Reply