atmospherical

Save Records as PDF during PSoS causes server script engine crash...

Discussion created by atmospherical on Jan 12, 2018
Latest reply on Sep 18, 2018 by TSGal

... *sometimes*.

 

Here's the deal: I've got a solution with a main office and a remote office. Both sites are well outside of a metro area, so they don't have fast internet access available. One of the commonly used functions of the solution is generating a multi-page PDF and then re-inserting it into a container field. At the remote office it was taking 1.5 - 2 minutes to upload the file.

 

Got them to move to v16 so I could re-work this function using PSoS. 98% of the time it works great and reduces PDF generation/upload to just a few seconds. The other 2% of the time it stalls the server's script engine.

 

I put in some logging to try to find the cause. Got it narrowed down to the Save Records as PDF step. The target path is generated using Get ( TemporaryPath ). The Save Records as PDF step never completes, so no error code is generated. Looking at examples of success v. failure I am at a loss to explain the difference. It doesn't seem to be related to character count or illegal characters. I thought maybe Get ( TemporaryPath ) accidentally called the same folder in a subsequent session, so I appended a few random characters to avoid the "disk full" error when the file already exists. Still happens.

 

Here are examples of the file path/name from 4 PSoS sessions:

 

Failure: /C:/Windows/Temp/S677/Indue-Bid-4072-long-2018 Winter Projects-12-28-2017-F9116.pdf

 

Success: /C:/Windows/Temp/S17/Indue-Bid-4072-long-2018 Winter Projects-12-28-2017-4D5FC.pdf

 

Failure: /C:/Windows/Temp/S357/Indue-Bid-4082-long-Additional Patching in Batch Room-1-5-2018-82682.pdf

 

Success: /C:/Windows/Temp/S17/Indue-Bid-4082-long-Additional Patching in Batch Room-1-5-2018-F737A.pdf

 

Any thoughts as to why two of these sessions worked while the other two didn't? Any other information I can provide to assist?

Outcomes