Hi there,

I was meaning to ask you all about the 'proper' way to use AMP in regards to 
two–way communication. The problem I am facing is quite simple, I am building a 
simple peer–to–peer network in which the user:

a) When sent a handshake, returns a handshake,
b) When asked for fingerprints of posts in the local, returns it, and then asks 
for the same thing,
and finally, c) If any of the fingerprints do not match posts, request those 
posts with the fingerprint.

The only non–symmetric step I have in my protocol is the last one.

My question is, should I send my responses over the same AMP command as a 
response to the command requested, or should I just return an ACK (a boolean 
value of true, to confirm receipt) and then initiate a separate AMP request 
from local to the same remote? 

That would mean I would need to handle my open–connections pool by myself, to 
prevent posts from a non–initiated machine being accepted into the local 
machine, but I do need to implement that anyway due to the complexity of my 
business rules. At that point, it seems that I am (Am I?) just using AMP as a 
remote method header I don't strictly need, and I could just use 
LineReceiver—all my data is text—to do my bidding. 

Am I missing anything AMP is doing silently for me? Am I using it the correct 
way?

Thanks in advance,

Best,
Burak





On Aug 20, 2013, at 8:47 AM, Laurens Van Houtven <_...@lvh.io> wrote:

> Hi Matt,
> 
> 
> Loved the story, excited about the prospects. Just one nitpick: after one of 
> Glyph's rants on gender-neutral words, I got tripped up by Ronnie not being 
> referred to as "they" ;-)
> 
> cheers
> lvh
> _______________________________________________
> Twisted-Python mailing list
> Twisted-Python@twistedmatrix.com
> http://twistedmatrix.com/cgi-bin/mailman/listinfo/twisted-python

Attachment: smime.p7s
Description: S/MIME cryptographic signature

_______________________________________________
Twisted-Python mailing list
Twisted-Python@twistedmatrix.com
http://twistedmatrix.com/cgi-bin/mailman/listinfo/twisted-python

Reply via email to