Hi Pierre!
SQLAlchemy doesn't do that, because it depends on the underlying
connection layer but I already had this question and made a solution.
You simply have to use another SQLite library, ASPW, -
https://code.google.com/p/apsw/
There are some material over the web (Stack Exchange) that shows how to
do it.
If you still can't do it, let me now that I can share some code with you.
Best regards,
Richard.
On 08/30/2013 11:46 AM, pr64 wrote:
Hi,
I'm currently running several python applications (each app using
sqlalchemy) accessing (read/write) a single SQLite database stored on
disk.
For performance reasons, I would like to store this db file in RAM
memory (ie, in my /dev/shm)
The applications would then access a shared in-memory db through
SQLAlchemy and a backup application would periodically make a hot copy
of the in-memory db to disk. Then, on a [power off, power on]
sequence, this backup app would copy the backed up db file from disk
to RAM before launching the other apps.
Before starting, I would like to know if you think it is feaseable. My
questions are:
1- Has SQLALchemy an API to do a hot copy? (based on
http://sqlite.org/backup.html for this particular db type)
2- If so, is this an actual hot copy, ie: the other apps will still
run without waiting for the backup app to finish he backup?
3- Is there a particular configuration in SQLAlchemy that enables
sharing an in-momory db from different apps (python processes)?
Thanks a lot for your feedback,
Pierre
--
You received this message because you are subscribed to the Google
Groups "sqlalchemy" group.
To unsubscribe from this group and stop receiving emails from it, send
an email to sqlalchemy+unsubscr...@googlegroups.com.
To post to this group, send email to sqlalchemy@googlegroups.com.
Visit this group at http://groups.google.com/group/sqlalchemy.
For more options, visit https://groups.google.com/groups/opt_out.
--
You received this message because you are subscribed to the Google Groups
"sqlalchemy" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to sqlalchemy+unsubscr...@googlegroups.com.
To post to this group, send email to sqlalchemy@googlegroups.com.
Visit this group at http://groups.google.com/group/sqlalchemy.
For more options, visit https://groups.google.com/groups/opt_out.