[Zope-CMF] Re: [dev] GenericSetup: more refactoring - a small proposal
yuppie wrote: I can see use cases like that, but I'd prefer a more decentralized solution. Using the setup tool for tasks like that makes it too complex and if I want to modify a single tool I don't want to switch to the setup tool and perform many steps to get my import. Possible alternatives: - A modified tool factory could allow adding pre-configured tools in a similar way as the 'CMF Action' and '* Type Information' factories on the trunk (that allow to choose presettings from profiles). - Tools could have an import/export tab that allows to load settings from an XML file. I don't understand, in the CMF 1.5 framework I'm using that doesn't make sense. Things go through portal_setup. Maybe in CMF 2.0 and the updated GenericSetup that's different but I'm not there yet. The new I/O adapters don't depend on the setup tool. Using the setup tool is only necessary if we want to use the snapshots in it. The add form for TypeInfos in CMF 2.0 is an example how a modified tool factory could work. If individual tools have Export/Import tabs that do the I/O, fine, but I don't see any code that does that today. You're proposing that we modify every single tool's implementation, instead of having things in portal_setup? Yes. But the code could be quite generic. AFAICS the only change that would be necessary in every single tool's implementation (or in a shared base class) is adding the new tab to 'manage_options'. Everything else could be a shared view. Anyway I've put this proposal on hold. No need to find a consensus now. So that I'm clear, I'm not against your proposal,as long as there's still a way to simply I/O individual tools. Florent -- Florent Guillaume, Nuxeo (Paris, France) CTO, Director of RD +33 1 40 33 71 59 http://nuxeo.com [EMAIL PROTECTED] ___ Zope-CMF maillist - Zope-CMF@lists.zope.org http://mail.zope.org/mailman/listinfo/zope-cmf See http://collector.zope.org/CMF for bug reports and feature requests
[Zope-CMF] Re: [dev] GenericSetup: more refactoring - a small proposal
-BEGIN PGP SIGNED MESSAGE- Hash: SHA1 yuppie wrote: Hi! The setup handlers for adapter based import / export are just boilerplate. I'd like to move the complete responsibility for setting up tools to importToolset / exportToolset. - -1, if I understand correctly, because it assumes too much. I *want* to make each tool'w setup explicit, rather than guessing at it from the tool's ID toolset.xml already contains all the necessary information if we use the ID of the tool for computing the file names. catalog.xml would e.g. become portal_catalog.xml. GenericSetup would need some BBB code to handle CMF 1.5 profiles. Old-style tool handlers can still have their own registry step. I would rather avoid making yet another seismic shift to how GS works. This would make writing and maintaining tool handlers much simpler. On the other hand we loose some flexibility: Exactly. Lets work on getting all the handlers done, and generalize later. - import/export of selected tools from a bigger profile: don't think we really need that - handling import dependencies: currently the 'workflow' step depends on the 'typeinfo' step. AFAICS we can easily get rid of that dependency. Nevertheless I think the refactoring would be an improvement and if there are no objections I'll work on this change. I'll need a lot more detail on the proposal, in particular w.r.t. the timeframe I'm proposing for a 2.0 release. Tres. - -- === Tres Seaver +1 202-558-7113 [EMAIL PROTECTED] Palladion Software Excellence by Designhttp://palladion.com -BEGIN PGP SIGNATURE- Version: GnuPG v1.4.1 (GNU/Linux) Comment: Using GnuPG with Thunderbird - http://enigmail.mozdev.org iD8DBQFDee7a+gerLs4ltQ4RArpgAJoDojJgxCkGSFyqinUwfhxB2y7LzgCaAqj9 OsaPe+nhw79Gquwmeqcv8X0= =CpPG -END PGP SIGNATURE- ___ Zope-CMF maillist - Zope-CMF@lists.zope.org http://mail.zope.org/mailman/listinfo/zope-cmf See http://collector.zope.org/CMF for bug reports and feature requests
[Zope-CMF] Re: [dev] GenericSetup: more refactoring - a small proposal
Hi Tres! Tres Seaver wrote: The setup handlers for adapter based import / export are just boilerplate. I'd like to move the complete responsibility for setting up tools to importToolset / exportToolset. - -1, if I understand correctly, because it assumes too much. I *want* to make each tool'w setup explicit, rather than guessing at it from the tool's ID I can't see any guessing involved. The mapping from the tool ID to the ID of the XML file is well defined. Profiles would not contain an XML file for each tool. But that's nothing new: Import steps are currently skipped if the related XML file doesn't exist. And that's quite often the case in extension profiles. This would make writing and maintaining tool handlers much simpler. On the other hand we loose some flexibility: Exactly. Lets work on getting all the handlers done, and generalize later. My hope was that the proposed change would make it easier to write the handlers. But given the doubts raised by Florent and you I put this proposal on hold. There are other unresolved issues and discussing this proposal might be easier at a later point. [...] I'll need a lot more detail on the proposal, in particular w.r.t. the timeframe I'm proposing for a 2.0 release. 'alpha' has no special meaning to me in that context, we are in 'alpha' since 1.5 is branched. So the relevant date for getting things done is the 'beta' in mid December - that's one month from now. Right? Cheers, Yuppie ___ Zope-CMF maillist - Zope-CMF@lists.zope.org http://mail.zope.org/mailman/listinfo/zope-cmf See http://collector.zope.org/CMF for bug reports and feature requests
[Zope-CMF] Re: [dev] GenericSetup: more refactoring - a small proposal
yuppie wrote: The setup handlers for adapter based import / export are just boilerplate. I'd like to move the complete responsibility for setting up tools to importToolset / exportToolset. toolset.xml already contains all the necessary information if we use the ID of the tool for computing the file names. catalog.xml would e.g. become portal_catalog.xml. GenericSetup would need some BBB code to handle CMF 1.5 profiles. Old-style tool handlers can still have their own registry step. This would make writing and maintaining tool handlers much simpler. On the other hand we loose some flexibility: - import/export of selected tools from a bigger profile: don't think we really need that What do you mean by i/o of selected tools from a bigger profile ? Florent -- Florent Guillaume, Nuxeo (Paris, France) CTO, Director of RD +33 1 40 33 71 59 http://nuxeo.com [EMAIL PROTECTED] ___ Zope-CMF maillist - Zope-CMF@lists.zope.org http://mail.zope.org/mailman/listinfo/zope-cmf See http://collector.zope.org/CMF for bug reports and feature requests
[Zope-CMF] Re: [dev] GenericSetup: more refactoring - a small proposal
Florent Guillaume wrote: yuppie wrote: - import/export of selected tools from a bigger profile: don't think we really need that What do you mean by i/o of selected tools from a bigger profile ? Right now each tool has its own import step and export step. The 'Import' and 'Export' tab of the setup tool allow to select single steps and run them independently. If tools become part of the 'Required tools' step you can just select / deselect them en bloc. Cheers, Yuppie ___ Zope-CMF maillist - Zope-CMF@lists.zope.org http://mail.zope.org/mailman/listinfo/zope-cmf See http://collector.zope.org/CMF for bug reports and feature requests
[Zope-CMF] Re: [dev] GenericSetup: more refactoring - a small proposal
Hi Florent! Florent Guillaume wrote: yuppie wrote: - import/export of selected tools from a bigger profile: don't think we really need that Right now each tool has its own import step and export step. The 'Import' and 'Export' tab of the setup tool allow to select single steps and run them independently. If tools become part of the 'Required tools' step you can just select / deselect them en bloc. Hm I don't like it, I import/export tools individually all the time. -1 from me. What are your use cases? Adding tools and loading the settings from an existing profile? Resetting existing tools? Others? Do you import/export only single tools or big sets of tools at once? I can see use cases like that, but I'd prefer a more decentralized solution. Using the setup tool for tasks like that makes it too complex and if I want to modify a single tool I don't want to switch to the setup tool and perform many steps to get my import. Possible alternatives: - A modified tool factory could allow adding pre-configured tools in a similar way as the 'CMF Action' and '* Type Information' factories on the trunk (that allow to choose presettings from profiles). - Tools could have an import/export tab that allows to load settings from an XML file. - I've experimented a bit with configuring sites via WebDAV. I was able to reconfigure portal_catalog by uploading a modified XML file. But I'm stuck with 2 issues: 1.) tool IDs don't have an '.xml' suffix 2.) tools like portal_workflow and portal_types that are represented by a directory of XML files are hard to bootstrap via WebDAV. Would one of these features be a good alternative for your use cases? Cheers, Yuppie ___ Zope-CMF maillist - Zope-CMF@lists.zope.org http://mail.zope.org/mailman/listinfo/zope-cmf See http://collector.zope.org/CMF for bug reports and feature requests