Advantages of Memory based sqLite databases

Bob Sneidar bobsneidar at iotecdigital.com
Thu Apr 21 23:25:22 EDT 2022


I made a client server proof of concept which encrypted messages before sending and decrypted them on the other end. The upshot was that I can send an encrypted query string from the client to the server, the server which handles the database connection stuff performs the query, then returns the data as an encoded array, also encrypted of course. It worked a peach. It can be used for anything. Sending Files to a remote server for example. It uses simple sockets for the connection, and I use a unique method for poisoning the payload so it cannot be cracked without having the poison pill, or the antidote as it were. And if you have that, I am likely dead. 

Sent from my iPhone

> On Apr 21, 2022, at 20:04, doc hawk via use-livecode <use-livecode at lists.runrev.com> wrote:
> 
> The difference between :memory: and the local hard disk is, in itself, stunning.
> 
> I initially set up with mysql, and (iirc) disk sqlite.
> 
> Whether it’s mysql or livecode’s fault, it isn’t (wans’t?) possible to to do a compound transaction to a mysql server.
> 
> So when I opened a “file” (a couple of tables per debtor for my software), it took *minutes* on a remote server to do what took a couple of seconds for a local sqlite file.
> 
> And an in-memory database was instantaneous.
> 
> If you need remote, there is a very many to one difference between Postgres (which can handle a transaction of several hundred queries at once) and mysql (which requires several hundred queries in sequence, with full latency applied to each one).
> 
> And another huge boost for going to in-memory sqlite.  (Don’t believe the bit about simultaneous access to sqlite files, it doesn’t quite work!).
> 
> So I settled on a remote Postgres, in which I stored the commands to update the in-memory sqlite.
> 
> The catch, of course, is that livecode never implemented the encrypted connection that Postgres supports out off the box.
> 
> If I was going to continue, I’d probably go to a local Postgres server on each machine with REPLICATE, and stay with in-memory sqlite—but barring any surprises, I’ll just retire instead.
> 
> 
> 
> _______________________________________________
> use-livecode mailing list
> use-livecode at lists.runrev.com
> Please visit this url to subscribe, unsubscribe and manage your subscription preferences:
> http://lists.runrev.com/mailman/listinfo/use-livecode


More information about the use-livecode mailing list