FileServices.getWebAppRootFilePath() returns null

Post any questions you have about using the Verj.io Studio, including client and server-side programming with Javascript or FPL, and integration with databases, web services etc.

Moderators: Jon, Steve, Ian, Dave

Segi
Ebase User
Posts: 649
Joined: Mon Dec 09, 2013 6:37 pm

FileServices.getWebAppRootFilePath() returns null

#1

Postby Segi » Mon May 18, 2015 7:52 pm

I found a strange bug that occurs in one of my scripts. When I load the form normally, FileServices.getWebAppRootFilePath() returns the correct path of my eBase installation (which I verify by printing to the eBase console). When I run the form using ebasetrigger to trigger a scheduled task, FileServices.getWebAppRootFilePath() returns a null value. Whats even stranger is that another schedule task that calls the same function does work correctly.

I restarted the eBase server and this problem still persists.

Update: I found the source of the problem which I don't see documented anywhere. In the scheduler, Synchronous execution was not checked for this scheduled task but is for the other task that is working correctly. I can verify that when Synchronous execution is not checked, FileServices.getWebAppRootFilePath() will return null. When you check it again, it does correctly return the full file path.

It might be a good idea to reflect this in the documentation on this page:

ufs/doc/scheduler.htm#_Synchronous_and_asynchronous
0 x

Jon
Moderator
Moderator
Posts: 1342
Joined: Wed Sep 12, 2007 12:49 pm

#2

Postby Jon » Tue May 19, 2015 9:04 am

This bug has been fixed but has not yet been released. It will be included in the next V4.5 service pack or V5, whichever is earlier.
0 x


Who is online

Users browsing this forum: No registered users and 14 guests