Closed benbjohnson closed 1 year ago
Yep! Those would remove almost all needs for the app to know about LiteFS. In case where writes need to happen for GETs (like updating a session expiration time), the application would need to replay. But the vast majority would be handled by what you've suggested. I'd love to have that.
Would probably be good to make some things comfortable (like the methods and maybe even URLs or something).
Thanks!
Currently, applications that use LiteFS need to write some LiteFS-specific code to redirect requests to the primary and to maintain consistency with the TXID after a write. It'd be useful if LiteFS could provide its own thin HTTP proxy in front of the application that would do the following:
With these features along with write forwarding (#56), most applications should not need to have any knowledge about LiteFS.
@kentcdodds Can you think of any other LiteFS-specific application code we could get rid of with a thin proxy?