Servermodule call- Performance

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: 221
Joined: Tue Feb 23, 2016 12:00 am

Servermodule call- Performance

Post by kno_dk »

Hi.

I have some servermodules which calls a Function to get prices, stock. etc. I have looked at the time the call takes and I was think about if this is the best way (performance) to get the information. The application is running on IBM I and LANSA V14.
Should I put all the servermoduls into one huge servermodule and then have all the subroutines and srvroutines inside that or can I call another serverroutine or should I create a RP?

Has anybody tested this and want to share the result?

/Klaus
kno_dk
Posts: 221
Joined: Tue Feb 23, 2016 12:00 am

Re: Servermodule call- Performance

Post by kno_dk »

Update:
The srvroutine found 63 items so the function was call 63 times. the time spent was 5.65 seconds.

I then moved all the logic from the function I was calling into the serverModule. I did the same call as above and now the time was 286 milliseconds. :D
performance.PNG
performance.PNG (18.21 KiB) Viewed 6841 times
jimwatterson
Posts: 56
Joined: Thu Jul 09, 2020 8:31 am

Re: Servermodule call- Performance

Post by jimwatterson »

Back in the days of RDML a function could be flagged as *HEAVYUSAGE which translated in RPG as don't turn on *LR. For a function calling another function many times this provided an enormous performance boost - almost as quick as subroutine call. RDMLX of course doesn't use RPG so I'm not sure that *HEAVYUSAGE does anything.

Whatever, RDMLX call performance is nowhere near as good as RDML *HEAVYUSAGE. The same is true for RP invocations. I have often found that I replaced an old school *HEAVYUSAGE BIF with RP doing the same thing I've had to pull the RP code inline to get acceptable performance.

I know that RPs on the iSeries are *SRVPGM so are ILE components and I know that there are different options available for binding these to other components but I have no idea how LANSA has implemented these and whether its possible to improve the performance in some way.

Jim
Post Reply