Selecting backend based on the user connecting
Hi,
I have a situation that I believe MySQL proxy should be able to handle, but as far as I can see it can't at the moment.
Let me describe what it is I need to do.
I have a DB server with a few thousand databases on it used by a few thousand different users.
I need to reduce the number of databases on the server - basically I need to move half the databases to a different physical server. The problem with this is that updating all the client code is out of the question, so after moving half the databases to a different physical server with a new ip/hostname half my users would no longer work. This is where I need the proxy.
Basically I need to setup the proxy on a machine with the IP/hostname of the original DB server so that is what clients connect to. Then I need to send clients to the appropriate backend server where their database is located based on their username.
The problem is that at the point where I can select a backend server (connect_server()) I don't know the username yet. I can't just pick a random backend server since I may be sending the client to a backend that doesn't hold his auth info.
As I see it, what I need is for the proxy to initially pretend to be the backend server and ask the client for authentication, then once I've recieved the auth info I can lookup what backend this user belongs to, then I need to initiate the connection with the appropriate backend and when I recieve the auth request I send the info I already recieved from the client and then send the reply back to the client.
Is this already possible and am I just not finding the functionality in the current svn code? If it's not possible, is it a planned feature?
Kind regards,
Jesper Juhl
Subject
Views
Written By
Posted
Selecting backend based on the user connecting
3546
August 13, 2007 03:42AM
2772
August 13, 2007 04:05AM
2595
August 13, 2007 04:11AM
2502
August 13, 2007 04:27AM
2508
August 13, 2007 05:29AM
2476
August 13, 2007 06:17AM
2664
August 20, 2007 05:47AM
2607
August 20, 2007 09:06AM
2631
August 22, 2007 07:45AM
2543
August 13, 2007 04:16AM
2540
August 13, 2007 04:25AM
2342
August 13, 2007 05:57AM
2427
August 13, 2007 06:20AM
2602
August 13, 2007 09:03AM
2353
October 11, 2007 02:31AM
Sorry, you can't reply to this topic. It has been closed.
Content reproduced on this site is the property of the respective copyright holders.
It is not reviewed in advance by Oracle and does not necessarily represent the opinion
of Oracle or any other party.