Le Sun, 19 Dec 2010 14:42:13 +0100, Cédric Krier <[email protected]> a écrit :
> Hi, > > As we discussed previously [1], we are going to start to work on this > feature. But we got one technical issue which is the communication > between tryton process on the same host. > > Here is the way opening URI should goes: > > - click on URI > - start a new tryton process with URI as arguments > - for each other tryton running: > - check if it is connected to the URI server and database > - if find one: > - send the URI to the process > - other process open URI > - stop > - else: > - start GUI > - ask for login to the database > - open URI > - GTK loop > > So we need to get a way to find others running tryton client on the > host (this is not too complicated). > But we need to have a way to communicate with those running client > and this communication should work on every OS's (Unix (Linux, > MacOSX) and Windows). > > We already thought about some solutions: > > - use a TCP socket on localhost for a range of port > - not really secure > - could have firewall issue > - limit the number of running client > > - use a file in .config directory for each processes > - need to lock writing/reading operation on the file > - could be slow to use filesystem > > Any others ideas? > what about sending a signal to the process to tell him to check the file: http://docs.python.org/library/signal.html (seems to work on all platforms). -- Bertrand Chenal B2CK SPRL Rue de Rotterdam, 4 4000 Liège Belgium Tel: +32 472 54 46 59 Email: [email protected] Website: http://www.b2ck.com/ -- [email protected] mailing list
