[Twisted-Python] Perspective Broker vs AMP
dripton at ripton.net
Mon Mar 31 09:23:57 EDT 2008
On 2008.03.31 09:00:40 +0100, Simon Pickles wrote:
> As I understand PB, a client can get the root object of a
> PBServerFactory, thru which it can call methods with the 'remote_'
> prefix. I'm not clear how this can work in the other direction.
The mind argument to Realm.requestAvatar holds a reference to the client
object that the client passed to PBClientFactory.login You can stash
that reference somewhere on the server side, and call callRemote on it
> As for
> AMP, this seems similar - the client uses callRemote() to execute remote
> methods on the amp server.
And the server can use callRemote on a client's protocol object.
I have a simple AMP chat example that demonstrates this:
David Ripton dripton at ripton.net
More information about the Twisted-Python