I am writing a Datamapper-on-Sqlite3 application that wants to be able
to restart itself, reopen all its sockets and database connections
etc. As part of the startup my app does:
DataMapper.setup(:default, @config[:database])
DataMapper.auto_upgrade!
create_a_temporary_table
i.e. I want to auto-upgrade the tables, AND do a CREATE TEMP VIEW
after every connection. The problem is that, the second time I run
this code, the auto-upgrade tries to meddle with the view (which
didn't exist on the first setup), and Sqlite throws an exception as a
result. I couldn't find a way of telling DataMapper to shut down a
connection, and wasn't sure of my way through the abstractions to be
able to hack one in. I just want to be able to tell it to destroy a
connection so it is back to a blank slate. Any suggestions?
--
Matthew
--
You received this message because you are subscribed to the Google Groups
"DataMapper" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to
[email protected].
For more options, visit this group at
http://groups.google.com/group/datamapper?hl=en.