"Brad Jorsch (Anomie)" <[email protected]> wrote: >> That may be true if you only want to connect to one wiki's databasse. But > what >> if you want to connect to all of them, one ofter the other, or maybe just > a >> handful, as needed?
> Keep a hash/dict/assoc/map of IP address to db connection, and reuse the > existing connection if you already have one for that IP? That would require a) that you do the name resolution your- self, and b) that MySQL never introduces something like HTTP/1.1's Host header/Labs never sets up a central DB proxy that relays the connections based on database names. I really don't think that we should encourage such low-level programming. If developers want to cache/group DB connec- tions and there is a super simple way to do so that has been proven to be working for some years now, I'm much more inclined to replicate that compared to almost anything else, especially if it is more complicated :-). Tim _______________________________________________ Labs-l mailing list [email protected] https://lists.wikimedia.org/mailman/listinfo/labs-l
