Login | Register For Free | Help
Search for: (Advanced)

Mailing List Archive: Zope: CMF

Adapterizing CMFCore.WorkflowTool redux

 

 

Zope cmf RSS feed   Index | Next | Previous | View Threaded


l at lrowe

Sep 23, 2010, 3:18 PM

Post #1 of 4 (1008 views)
Permalink
Adapterizing CMFCore.WorkflowTool redux

Some time ago I made a branch to adapterize workflow storage lookups
(then forgot about it):
http://www.mail-archive.com/zope-cmf [at] lists/msg04888.html

I've updated that to the current trunk and the result is here:
svn+ssh://svn.zope.org/repos/main/Products.CMFCore/branches/adapterize-wfstatus-wfhistory

This functionality is already well covered by tests in
Products.CMFCore.tests.test_WorkflowTool.WorkflowToolTests and
Products.DCWorkflow.tests.test_DCWorkflow.DCWorkflowDefinitionTests
(without the adapters registered several tests fail or break).

If there are no objections I shall merge the changes back to trunk.

Laurence
_______________________________________________
Zope-CMF maillist - Zope-CMF [at] zope
https://mail.zope.org/mailman/listinfo/zope-cmf

See https://bugs.launchpad.net/zope-cmf/ for bug reports and feature requests


charlie.clark at clark-consulting

Sep 25, 2010, 8:26 AM

Post #2 of 4 (951 views)
Permalink
Re: Adapterizing CMFCore.WorkflowTool redux [In reply to]

Am 24.09.2010, 00:18 Uhr, schrieb Laurence Rowe <l [at] lrowe>:

> If there are no objections I shall merge the changes back to trunk.

+1 from me. Please update changes.txt

From your original post:

* I currently adapt based on (IContentish, IWorkflowDefinition) should
this be made more general, i.e. (Interface, IWorkflowDefinition)? Does
anyone workflow anything that is not IContentish?

Shouldn't only IWorkflowAware be adapted?

* Is deprecating getStatusOf, setStatusOf, getHistoryOf desirable? I'm not
sure it would serve any particular purpose.

Looking at the implementation the question I would ask myself is, what are
the alternatives? In general I'd agree with yuppie on less tool methods
and more adapters but not with the current spelling for multiadapters.

Charlie
--
Charlie Clark
Managing Director
Clark Consulting & Research
German Office
Helmholtzstr. 20
Düsseldorf
D- 40215
Tel: +49-211-600-3657
Mobile: +49-178-782-6226
_______________________________________________
Zope-CMF maillist - Zope-CMF [at] zope
https://mail.zope.org/mailman/listinfo/zope-cmf

See https://bugs.launchpad.net/zope-cmf/ for bug reports and feature requests


l at lrowe

Sep 27, 2010, 11:33 AM

Post #3 of 4 (920 views)
Permalink
Re: Adapterizing CMFCore.WorkflowTool redux [In reply to]

On 25 September 2010 16:26, Charlie Clark
<charlie.clark [at] clark-consulting> wrote:
> Am 24.09.2010, 00:18 Uhr, schrieb Laurence Rowe <l [at] lrowe>:
>
>> If there are no objections I shall merge the changes back to trunk.
>
> +1 from me. Please update changes.txt
>
>  From your original post:
>
> * I currently adapt based on (IContentish, IWorkflowDefinition) should
> this be made more general, i.e. (Interface, IWorkflowDefinition)? Does
> anyone workflow anything that is not IContentish?
>
> Shouldn't only IWorkflowAware be adapted?

I've changed it to adapt (IWorflowAware, IWorkflowDefinition) now.
I've also made a change so that objects are possibly adapted to
IWorkflowAware before calling notifyWorkflowCreated so this may be
implemented as an adapter instead of a mixin.

> * Is deprecating getStatusOf, setStatusOf, getHistoryOf desirable? I'm not
> sure it would serve any particular purpose.
>
> Looking at the implementation the question I would ask myself is, what are
> the alternatives? In general I'd agree with yuppie on less tool methods
> and more adapters but not with the current spelling for multiadapters.

I don't think it really serves any purpose at this time. I'll merge to
trunk later this week assuming no objections.

Laurence
_______________________________________________
Zope-CMF maillist - Zope-CMF [at] zope
https://mail.zope.org/mailman/listinfo/zope-cmf

See https://bugs.launchpad.net/zope-cmf/ for bug reports and feature requests


l at lrowe

Oct 19, 2010, 8:18 AM

Post #4 of 4 (806 views)
Permalink
Re: Adapterizing CMFCore.WorkflowTool redux [In reply to]

On 27 September 2010 19:33, Laurence Rowe <l [at] lrowe> wrote:
> On 25 September 2010 16:26, Charlie Clark
> <charlie.clark [at] clark-consulting> wrote:
>> Am 24.09.2010, 00:18 Uhr, schrieb Laurence Rowe <l [at] lrowe>:
>>
>>> If there are no objections I shall merge the changes back to trunk.
>>
>> +1 from me. Please update changes.txt
>>
>>  From your original post:
>>
>> * I currently adapt based on (IContentish, IWorkflowDefinition) should
>> this be made more general, i.e. (Interface, IWorkflowDefinition)? Does
>> anyone workflow anything that is not IContentish?
>>
>> Shouldn't only IWorkflowAware be adapted?
>
> I've changed it to adapt (IWorflowAware, IWorkflowDefinition) now.
> I've also made a change so that objects are possibly adapted to
> IWorkflowAware before calling notifyWorkflowCreated so this may be
> implemented as an adapter instead of a mixin.
>
>> * Is deprecating getStatusOf, setStatusOf, getHistoryOf desirable? I'm not
>> sure it would serve any particular purpose.
>>
>> Looking at the implementation the question I would ask myself is, what are
>> the alternatives? In general I'd agree with yuppie on less tool methods
>> and more adapters but not with the current spelling for multiadapters.
>
> I don't think it really serves any purpose at this time. I'll merge to
> trunk later this week assuming no objections.

Merged in 117773

Laurence
_______________________________________________
Zope-CMF maillist - Zope-CMF [at] zope
https://mail.zope.org/mailman/listinfo/zope-cmf

See https://bugs.launchpad.net/zope-cmf/ for bug reports and feature requests

Zope cmf RSS feed   Index | Next | Previous | View Threaded
 
 


Interested in having your list archived? Contact Gossamer Threads
 
  Web Applications & Managed Hosting Powered by Gossamer Threads Inc.