Re: [Twisted-Python] Is there pb documentation somewhere?

2014-08-04 Thread Glyph Lefkowitz

On Jul 27, 2014, at 7:26 PM, Daniel Sank  wrote:

> I've been trying to address ticket 7274
> 
> https://twistedmatrix.com/trac/ticket/7274
> 
> To do this, I am trying to understand the PB protocol. While I found a spec 
> for banana in twisted-daniel/docs/core/specifications/banana.rst, I have not 
> found anything similar for pb. I've been piecing it together by writing 
> little test scripts, but it is slow going. In particular, it is very 
> difficult to understand the meaning of verbs like "cook" and "preserve" and 
> nouns like "persistent store" without some global picture of what's going on.
> 
> 1. Is there some kind of narrative documentation on how pb works under the 
> hood?

I don't believe there is.

> 2. Is there a specification for the pb dialect of banana?

Beyond the code, no.

> 3. Is there anyone else out there interested enough in pb to want to work 
> with me to figure things out and produce documentation if there isn't any 
> currently?

I would be happy to answer questions, but obviously I'm not super responsive 
:).  Let me know what you need.

-glyph

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


Re: [Twisted-Python] Is there pb documentation somewhere?

2014-08-04 Thread Daniel Sank
glyph,

>> 2. Is there a specification for the pb dialect of banana?
>>
> Beyond the code, no.

Ok.

> I would be happy to answer questions, but obviously I'm not super
responsive :).
> Let me know what you need.

For two personal projects, I would like to have a reasonable remote objects
library in python. I need something which can announce state changes to
clients, and receive state change requests from clients. My solution:

1. Make server side class which can spawn Cacheables when it wants to tell
clients of its existence.
2. Give RemoteCaches to clients and use observe_* methods as appropriate.
3. Stuff a Viewable into the RemoteCaches so that clients can request state
changes.

Question #1: Is this a reasonable use of pb?

This all worked great until I ran into a bug. In trying to fix the bug, I
found that

1. pb code is really hard to understand
2. exarkun's thinks pb is bad and that I should implement what I need in
AMP.
3. exarkun thinks banana and jelly are reasonable.

Question #2: Would you recommend implementing a simplified replacement for
pb on top of banana/jelly, or starting over from AMP? I favor the
banana/jelly route because the protocol seems intrinsically flexible, but I
read your blog explaining why protocols like banana are bad, so I'm
confused about what I "should" do.

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


Re: [Twisted-Python] Is there pb documentation somewhere?

2014-08-04 Thread Daniel Sank
glyph

> I would be happy to answer questions, but obviously I'm not super
responsive :).
> Let me know what you need.

I am trying to understand jelly's serialization strategy:

1. In t.s.jelly._Jellier, what is the meaning of persistentStore?
2. In t.s.jelly._Jellier, what is the meaning of cooked? The comment here
doesn't make sense to me yet.
3. In t.s.jelly._Jellier, what is the meaning of cooker?

A short, narrative explanation of what _Jellier does would be very useful,
and if you provide it I will submit a patch to the documentation.

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