Zope-Beans Resurrection

The trick that keeps giving for 20 years.

March 12 2021

My posting from 20 years ago (Sun, 04 Mar 2001)

Paul T
Sun, 04 Mar 2001 13:51:33 -0800

    Previous message: [Zope] BOFs
    Next message: [Zope] ANNOUNCE. Zope Beans v 0.1
    Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]

Experimental version:

Genbean.py v 0.1
Tested with Zope 2.3.0

The big picture is described in the paper "Zope: How To Win Big". 

What is Zope Bean? 

Zope Bean is a simplified plug & play product for Zope.
Zope Bean encapsulates a set of properties and methods. 
Zope Bean has one creation screen, one configuration 
screen and one information screen.

Zope Bean is not Zope Component. 

Zope Component is experimental new feature in Zope. 
I have not seen it implemented yet. However, from the paper: 
"Components need not be persistent, nor provide a management 
interface." Zope Beans are persistent and they provide a 
management interface. 

Zope Bean is not exactly Zope Product. 

Zope Products are hard to create and hard to maintain. 
If you're Python/Zope pro who is used to write complex 
Zope Products, the chances are that you may have 
no need in Zope Beans - you're already a magician. 
However, Zope Beans enforce loose coupling design 
(something to think about).

The biggest difference between Zope Bean and Zope Product 
is that Zope Bean is extremely easy to create and to maintain 
even you have no experience with Zope Products at all. If you 
know a bit of Python - you can write and use Zope Beans.

Next version of Zope Beans may provide more functionality 
(like complex types of properties, one-bean-cooperating-with-other-bean, 
Global Bean Distribution Network, e t.c.) The purpose of this
version is to show that writing plug & play Zope Products 
could be significantly easier than it is now.

Comments welcome.


First a bit history. The one thing that's been neglected last couple decades is M4.
One can do a lot with M4. Basically, M4 is C macroprocessor, as a stand alone component.
Here is a bit more on gods and C.

I do know how to improve on M4 ( Here is some stuff I run in production ), but that's complex topic.
For example, I myself can not decide should the DL be mixed in or left alone (here is a bit more on DL)

But this page is not about M4. It's about a shortcut. There is a shortcut (through YAML). Shortucts are easy so we take them all the time.

The first was Ansible. The guy took the shortcut, but lost the way. Actually, before YAML and Ansible was my XSLScript.
Here is my posting from Y 2000

Subject: ANN. XSLScript v 0.5.
From: Paul Tchistopolskii 
Date: Fri, 28 Jul 2000 00:15:55 -0700
ANN. XSLScript v 0.5.


The source code + plug&play .jar distribution of 
XSLScript is available at  http://www.pault.com/ XSLScript/index.html

XSLScript is a terse notation for writing complex XSLT stylesheets.

To execute XSLScript script: 
    xsls some.xml some.xsls

The XSLScript script (some.xsls) will be compiled into appropriate 
XSLT stylesheet and then generated XSLT stylesheet will be 
applied to the file some.xml (no temporary file is created, this 
all happens in the memory). The actual XSLT transformation 
is performed by XT. 

To generate the XSLT stylesheet out of XSLScript script: 
    xslsdump some.xsls

Why XSLScript ? 

   One of the reasons is that I got tired typing 3 (or more) lines 
to invoke foo(bar). I doubt I'll now write too much plain XSLT code - 
I found it much easier to write and read XSLTScript. In the case 
I have to write XSLT code (for example - on client side), I can debug 
it in XSLScript and then I can generate the XSLT stylesheet.

 I see some more improvements. If you like the idea and 
have some other XSL 'meta-constructions' in mind - feel
free to ask me for implementing your requests in next version
of XSLScript. ( There may be at least one more release 
of XSLScript when I'l plug it into Ux  ( http://www.pault.com/Ux/ ).


 XSL-List info and archive:  http://www.mulberrytech.com/xsl/xsl-list

XSLScript was no shortcut, though. It had a grammar (to parse XPath) and it was heavy lifting.
I put it public domain, but can not find it now. Internets does not keep the good stuff for long.

Zope-Beans was a shortcut. XML descriptor - generation.
Same was my Fish is Selenium replacement - YAML based, because YAML exists now. In times of Zope-Beans there was only XML

And now I see a clear way to do Solidity Beans using the same trick. So the trick just keeps giving for 20 years.
That's why this page.