vlcn-io / vite-starter

scaffold for a vitejs based vlcn project
34 stars 7 forks source link

add litefs deployment to the example #19

Closed tantaman closed 1 year ago

tantaman commented 1 year ago

if we're going to do this it is unclear if we can actually use the websocket server.

The reason is that writes to litefs must go to the primary. litefs supports a proxy (https://fly.io/docs/litefs/proxy/) to route non-get requests to the primary.

If we're on websocket, however, we can't use this (from what I can tell so far).

tantaman commented 1 year ago

Looks like we can check this file before issuing our write in the websocket server:

https://fly.io/docs/litefs/primary/

There is also this: https://github.com/superfly/litefs/issues/56

but apparently it isn't good for cases with a high write volume.

tantaman commented 1 year ago

This'll need to wait on LiteFS support in the Vulcan websocket server -- https://github.com/vlcn-io/js/pull/7