Is there a DBI proxy that handles SQL restrictions and transactions?
I am looking for a DBI (or similar) proxy that supports both SQL restrictions and transactions. The two I know about are:
The problem I have found with DBD::Proxy is that its server, DBI::ProxyServer, doesn't just restrict queries coming in over the network (which I want), but it also restricts queries generated internally by the database driver. So, for example, with DBD::Oracle, ping no longer works, as well as many other queries it issues itself.
I can't just allow them, because:
- That is quite a bit of internal knowledge of DBD::Oracle and would be quite fragile.
- The whitelist is query_name => 'sql', where query_name is the first word of whatever is passed to prepare. DBD::Oracle has a lot of internal queries, and the first word of many of them is select (duh).
So, it doesn't seem I can use DBD::Proxy
I haven't tried DBD::Gofer, because the docs seem to tell me that I can't use transactions through it:
You can’t use transactions
AutoCommit only. Transactions aren’t supported.
So, before I write my own application-specific proxy (using RPC::PLServer ?), is there code out there that solves this problem?
This question would be best asked on the DBI Users mailing list, email@example.com. Sign up at http://dbi.perl.org/
I'm not sure what you mean about DBD::Proxy restricting queries. On the only occasion I've used it, it didn't modify the queries at all.