Re: At-SPI client and server running in different hosts



svs drozo wrote:

Hi,

I would need to set up an environment in which two different hosts have
the two parts of at-spi, I mean, the clients in one of them and the
server in the other, is that possible? How can I do it?
Hi:

If you only want the client to be on one host, and the applications and the at-spi registry daemon on the other, then all you need is for your AT client to have a reference to the remote registry. Instead of using the usual way of obtaining the at-spi registry (which uses bonobo-activation, and only finds registries on the local host), you can obtain the registry instance by creating a "stringified" version of the registry IOR, passing that string to your client's host somehow (how you do this is up to you), and then calling the "string_to_object()" method of your ORB. This means a little bit of extra coding on your part, but not much.

In python for example, you couldd use something like this on the at-spi-registry side to write the string to a file (shared over NFS perhaps?):

f = file('echo.ref', 'w+')
print >> f, orb.object_to_string(registry)
f.close()

Of course any way of getting a string from one host to another could be used. So on the server side you must write a small piece of code which does exactly this, obtains a reference (IOR) to the at-spi-registry in the "usual way", then exports it as a "stringified IOR".

Then on the AT client side, you need to make a small change; instead of using the usual bonobo-activation-based method for obtaining a reference to the at-spi-registryd Registry, you instead call a piece of code which
reads the string from the server-host and calls orb.string_to_object to get a valid IOR from that string.

From there on, everything should work as normal (as long as the client always uses this cached IOR for the registry,
obtained via this alternate means.

Hope that helps,

Bill


Thx.

Best regards.
_______________________________________________
gnome-accessibility-list mailing list
gnome-accessibility-list gnome org
http://mail.gnome.org/mailman/listinfo/gnome-accessibility-list




[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]