Perform Script On Server: Faster Calendars

Perform Script On Server (PSOS): Overview

The “Perform Script on Server” script step was introduced in FileMaker Server 13 to let clients of a hosted file run scripts on the server. So with some careful planning, you can have the server do a lot of the heavy lifting the client machine would normally have to do (finding, sorting, processing, other data manipulation, etc.). This means you can sometimes avoid moving large amounts of data over the network, which is what normally happens when the client machine runs a Perform Find or an SQL query on a hosted file.

Using PSOS can result in dramatic performance improvements in these types of operations when opening your file from outside your local network. Our tests with the Pro Calendar showed refresh times 10-40 times faster when using PSOS from outside the network (your mileage may vary).

You’ll likely not see any improvement when you’re ON the local network.

PSOS in SeedCode Calendar Pro

Perform Script on Server in SeedCode CalendarThe new upgrade for SeedCode Calendar adds a switch for using PSOS on the calendar’s settings tab. Developers can turn this on for just their session while they’re testing or they can make it the default by editing the comment for PSOS in the calendar’s “Load Settings” script.

Why wouldn’t everyone want PSOS on?

The speed improvements in PSOS are most dramatic when you’re far away from your FileMaker Server. But it does come with a trade off: scripts run under PSOS don’t cache their results the way scripts running locally would. So if your server is close enough, you may not want PSOS running because you’d rather have the caching.

Here is an exaggerated example:

  • Without PSOS, opening your calendar from another state takes 9 minutes to move from month to month. But once you’ve been to a given month, going back to that month takes only a couple seconds.
  • With PSOS on, it only takes 5 seconds to go from month to month… but it always takes 5 seconds. Going back to a previously visited month is no faster than going to a new month.

Going Further

If you want to learn more about PSOS I highly recommend this article by Vince Menanno: 100x Faster – Flight Testing FileMaker 13. Very well done. Vince rightly points out that there are a lot of things to manage with Perform Script on Server because the server doesn’t have the same state (globals, found sets, the current record, etc.) as the client. We’ve scripted all that for you in the calendar’s PSOS queries.

We hope you find it useful.

[ba-box background=”#778899″ border=”#708090″ textcolor=”#F7F7F7″][jetpack_subscription_form][/ba-box]

Featured Posts

Follow Along

Stay up to date with the latest news & examples from SeedCode

Leave a Reply

Your email address will not be published. Required fields are marked *

Check out some of our other posts ...

Improved Resource Selection

We’ve made some big changes to how you filter and assign resources when editing events in DayBack. These changes will make it much easier to

Suggesting Appointment Slots

Show Available Slots that Match Multiple Criteria Schedulers often look for gaps in their schedules to find the open resources for each opportunity. But sometimes,

Introducing Draft Settings Mode

Following up on this idea that people stretch themselves when they feel a little safer, we’ve been very focused on the customization experience for DayBack



Stay up to date with the latest news & examples from SeedCode

© 2024 SeedCode, Inc.