David
David

Reputation: 5036

Anything similar to MySQL Proxy for PostgreSQL?

I am looking for something similar to MySQL Proxy. The purpose is to modify incoming queries on the server. I am not looking for alternative ways to achieve the same. My best guess at the moment is to modify GridSQL, but this adds complexity and it takes time. I have asked this question before in a vastly different way and got no relevant results, so I deleted that question and added this one.

Edit: It is important that the client can continue to utilize the PostgreSQL protocol, so the package I am looking for needs to communicate using it.

Upvotes: 8

Views: 5764

Answers (2)

samaitra
samaitra

Reputation: 774

You can refer to the following postgresql-aync driver project.

https://github.com/mauricio/postgresql-async

Upvotes: 1

John P
John P

Reputation: 15245

You might take a look at sqlrelay which has the ability to route and filter queries.

http://sqlrelay.sourceforge.net/sqlrelay/router.html

If you want to rewrite the queries I think sqlrelay falls short.

You might otherwise look into PostgreSQL's rules, which can be used to substitute or rewrite queries:

http://www.postgresql.org/docs/8.4/interactive/rules.html

Upvotes: 2

Related Questions