XState V5 [currently Alpha]
Feature request
The next version of xstate (V5) seems geared towards server environments, so it might be an ergonomic (and OSS) approach to supabase workflows. Some things I'd like to put in my shopping cart:
- ensured edge functions compatibility
- actor.send() resolution to a machine stored in supabase
- viewing a workflow persisted to a JSONB field in supabase ui using the xstate visualizer
- cron / delayed transitions built-in
- automatic logging / events table I can subscribe to / subscribing to specific machine events from the supabase client
server environments
interesting. Do you know if they will be building a multi-tenant runtime? (eg, serve multiple customers with a single server)
That's our typical constraint at supabase - it's very hard to host a server per customer now
multi-tenant runtime
So I suppose normally splitting schemas is enough, not in your case right?
that's a start (generally it would be a different database for security reasons though, and with supabase that config would live inside their database)
the trick here is that the server needs to hold open a connection to thousands of databases, and Node isn't great for that sort of thing (compared to, say, elixir). Then you get spiky workloads, noisy neighbors, excecution isolation, etc.
it's not impossible, but we'd need to make sure it's an explicit goal of XState (which I doubt many people will be asking for)
This is an interesting integration of Xstate and temporal https://github.com/Devessier/temporal-electronic-signature