This section contains frequently asked questions about Wasmer Edge. These questions were either asked on Discord or were felt to be important to include.

Does traffic ever get sent to more-geographically distant nodes that are already active ?

Traffic currently is always handled in the initial region (aka data center) the user is assigned to. There will soon be a way to restrict your apps to only run in specified regions, though.

What is threshold for 'spill over' when nodes are overloaded? Are allocations to edge nodes based on vCPU or request volume ?

The system will load balance dynamically based on server load - this is not something that you should assume any functional transparency about. Edge will dynamically determine how many instances of your app to start up in a given region/server. Note that we will add configuration for this, eg: you will be able to specify that you want at most X instances in a given region, or that each instance of your app should handle at most X concurrent requests, with new instances launched dynamically if that threshold is exceeded.

How long is the 'short idle period' before server termination. If post-request server-side processing is required, how can we prevent a shutdown? Is this determined by CPU usage, a timeout post-last request, or perhaps an interceptor in the WASIX VM monitoring for specific IO syscalls, such as accept4 ?

Currently this is a fixed value of a few minutes, but this can not be assumed, it may change at any time, and workloads can get evicted under contention. What we will add a graceful termination flow like on Linux: instances will receive a SIGTERM , and will have some time to clean up and finish remaining work, with hard termination only happening after a well-known grace period.

Do we need utilities like pgBouncer ?

It would probably be advisable. It's possible for multiple versions of your app to run on multiple servers in the same region, and for a bunch of new instances to get spawned , so you might have quite bursty connection counts. If you need more control, one of the features that we hope to finish in this quarter (before end of year) is persistent instances, which will keep running , and won't be dynamically spawned or terminated.

A note about database locality: We will have configuration that allows you to restrict your app to certain regions, so if you want to keep your instances close to the location of your database, that will be possible.