You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@lenya.apache.org by Andreas Hartmann <an...@apache.org> on 2006/02/27 09:35:29 UTC
Re: svn commit: r381035 - in /lenya/trunk/src/java/org/apache/lenya/cms:
publication/Publication.java publication/PublicationImpl.java repository/SourceNode.java
Hi Michi,
thanks for this!
michi@apache.org wrote:
> Author: michi
> Date: Sat Feb 25 16:39:52 2006
> New Revision: 381035
> --- lenya/trunk/src/java/org/apache/lenya/cms/publication/Publication.java (original)
> +++ lenya/trunk/src/java/org/apache/lenya/cms/publication/Publication.java Sat Feb 25 16:39:52 2006
> @@ -171,6 +171,13 @@
> String getInstantiatorHint();
>
> /**
> + * Returns the content dir.
> + * If the publication does not specify a content dir, then <code>null</code> is returned.
> + * @return A base directory where all the content is located.
> + */
> + String getContentDir();
Would you mind adding some more information to the javadocs?
- is it an absolute or relative path?
- if relative, where does it start from?
Actually I think this method is not appropriate, because it assumes
file-based storage, which is rather a responsibility of the SourceNodeFactory.
I'd propose to add the configuration option to the SourceNodeFactory:
<node-factories>
<component-instance name="source" class="...">
<content-directory src="..."/>
</component-instance>
</node-factories>
-- Andreas
--
Andreas Hartmann
Wyona Inc. - Open Source Content Management - Apache Lenya
http://www.wyona.com http://lenya.apache.org
andreas.hartmann@wyona.com andreas@apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@lenya.apache.org
For additional commands, e-mail: dev-help@lenya.apache.org
Re: svn commit: r381035 - in
/lenya/trunk/src/java/org/apache/lenya/cms: publication/Publication.java
publication/PublicationImpl.java repository/SourceNode.java
Posted by Thorsten Scherler <th...@wyona.com>.
El lun, 27-02-2006 a las 10:08 +0100, Andreas Hartmann escribió:
> Michael Wechner wrote:
> > Andreas Hartmann wrote:
>
> [...]
>
> >> <node-factories>
> >>
> >> <component-instance name="source" class="...">
> >> <content-directory src="..."/>
> >> </component-instance>
> >>
> >> </node-factories>
> >
> >
> > the problem I see here is that it is publication specific ...
>
> OK, I see.
>
> The SourceNodeFactory could maintain a different directory for each
> publication. The configuration could be added using an XPatch file
> provided by the publication:
>
> <xconf xpath="/cocoon/node-factories/component-instance
> [@class = '...SourceNodeFactory']">
>
> <content-dir publication="..." src="..."/>
>
> </xconf>
>
>
> The problem is that this isn't compatible with publication templating.
> Maybe we could add a wildcard for the publication ID?
>
> <content-dir publication="..." src="/content/@PUBLICATION@/"/>
>
> This would implicate that all instances store their content
> using this declaration.
Hmm, the problem I see on this and the related thread is that location
properties should really go into a higher level configuration file.
It cannot be that we need to change millions of different files in
different locations to make lenya work.
The nicest solution I see is to use the locationmap for this.
I will write now a proposal to implement it.
salu2
--
Thorsten Scherler
COO Spain
Wyona Inc. - Open Source Content Management - Apache Lenya
http://www.wyona.com http://lenya.apache.org
thorsten.scherler@wyona.com thorsten@apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@lenya.apache.org
For additional commands, e-mail: dev-help@lenya.apache.org
Re: svn commit: r381035 - in /lenya/trunk/src/java/org/apache/lenya/cms:
publication/Publication.java publication/PublicationImpl.java repository/SourceNode.java
Posted by Andreas Hartmann <an...@apache.org>.
Michael Wechner wrote:
> Andreas Hartmann wrote:
[...]
>> <node-factories>
>>
>> <component-instance name="source" class="...">
>> <content-directory src="..."/>
>> </component-instance>
>>
>> </node-factories>
>
>
> the problem I see here is that it is publication specific ...
OK, I see.
The SourceNodeFactory could maintain a different directory for each
publication. The configuration could be added using an XPatch file
provided by the publication:
<xconf xpath="/cocoon/node-factories/component-instance
[@class = '...SourceNodeFactory']">
<content-dir publication="..." src="..."/>
</xconf>
The problem is that this isn't compatible with publication templating.
Maybe we could add a wildcard for the publication ID?
<content-dir publication="..." src="/content/@PUBLICATION@/"/>
This would implicate that all instances store their content
using this declaration.
-- Andreas
--
Andreas Hartmann
Wyona Inc. - Open Source Content Management - Apache Lenya
http://www.wyona.com http://lenya.apache.org
andreas.hartmann@wyona.com andreas@apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@lenya.apache.org
For additional commands, e-mail: dev-help@lenya.apache.org
Re: svn commit: r381035 - in /lenya/trunk/src/java/org/apache/lenya/cms:
publication/Publication.java publication/PublicationImpl.java repository/SourceNode.java
Posted by Michael Wechner <mi...@wyona.com>.
Andreas Hartmann wrote:
>
> Hi Michi,
>
> thanks for this!
>
>
> michi@apache.org wrote:
>
>> Author: michi
>> Date: Sat Feb 25 16:39:52 2006
>> New Revision: 381035
>
>
>
>> ---
>> lenya/trunk/src/java/org/apache/lenya/cms/publication/Publication.java
>> (original)
>> +++
>> lenya/trunk/src/java/org/apache/lenya/cms/publication/Publication.java
>> Sat Feb 25 16:39:52 2006
>> @@ -171,6 +171,13 @@
>> String getInstantiatorHint();
>>
>> /**
>> + * Returns the content dir.
>> + * If the publication does not specify a content dir, then
>> <code>null</code> is returned.
>> + * @return A base directory where all the content is located.
>> + */
>> + String getContentDir();
>
>
> Would you mind adding some more information to the javadocs?
>
> - is it an absolute or relative path?
> - if relative, where does it start from?
makes sense
>
> Actually I think this method is not appropriate, because it assumes
> file-based storage,
agreed
> which is rather a responsibility of the SourceNodeFactory.
>
> I'd propose to add the configuration option to the SourceNodeFactory:
>
> <node-factories>
>
> <component-instance name="source" class="...">
> <content-directory src="..."/>
> </component-instance>
>
> </node-factories>
the problem I see here is that it is publication specific ...
Michi
>
>
>
> -- Andreas
>
>
>
--
Michael Wechner
Wyona - Open Source Content Management - Apache Lenya
http://www.wyona.com http://lenya.apache.org
michael.wechner@wyona.com michi@apache.org
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@lenya.apache.org
For additional commands, e-mail: dev-help@lenya.apache.org