On 22 Dec 2006 20:02:31 -0800, Carl Banks <[EMAIL PROTECTED]> wrote: ... > There is much room for improvement. For example, can requests come in > fast enough to spawn another load_data before the first had ended? You > should consider trying to acquire a threading.Lock in load_data and > waiting and/or returning immediately if you can't. Other things can go > wrong, too. Using threads requires care. But hopefully this'll get > you started. >
Thanks, Carl. That gives me a lot to consider. I won't be able to work on this project more until Wed. but I'll probably run into some follow up questions then. A few more details if it helps ... That module deals with accessing data from QuickBooks, marshaling it, and providing methods to access the marshaled data. Having the server program keep that module and all of its data in memory makes the server run really fast, but yeah, it does get complicated now that it's storing 100's of MB of data. I guess most people go to a database at this point? It's just so easy to store the data in the Python objects I already need them in instead of converting to tables in a DB and then converting back. So maybe this threading will work for me. Thanks again, Greg -- http://mail.python.org/mailman/listinfo/python-list