By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
424,952 Members | 1,732 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 424,952 IT Pros & Developers. It's quick & easy.

Dividing (load-balancing) db entries among backend servers

P: n/a
Hello,

I am in the process of designing the following kind of system --

A MySQL database holds hundreds of thousands of entries. All of these
entries are periodically processed by a set of backends. Whenever an
entry is processed, its related fields are updated.

The approaches I am considering for load-balancing are:

1. Have a backend-id associated with each entry. Each backend server
is given
a range of backend-ids it should process. I don't like this for the
reason that
if someone messes up backend-id range allocation among backends, some
entries may not get processed at all (or, could get processed multiple
times).

2. No backend-ids. Each backend server grabs a bunch of unprocessed
entries by
updating a status field. Once it is done processing all of them, it
again updates the status to signal the completion of the processing.
This approach results in two updates to every record in a processing
cycle. Also, it is tricky
to grab unprocessed records (since they may have just been processed
by other backend).

Do I have any other choices apart from above? I would highly
appreciate any ideas.

Thanks,
KP.
Jul 19 '05 #1
Share this question for a faster answer!
Share on Google+

This discussion thread is closed

Replies have been disabled for this discussion.