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/03/07 17:36:04 UTC
Re: svn commit: r383910 - in
/lenya/trunk/src/modules/opendocument:config/cocoon-xconf/
config/menus/java/ java/src/ java/src/org/java/src/org/apache/
java/src/org/apache/lenya/java/src/org/apache/lenya/cms/
java/src/org/apache/lenya/cms/site/java/src...
[...]
>> - the resource type can be asked for the path to read the document from
>> (or maybe it is sufficient to ask the resource type for the
>> file extension)
>
> I dunno understand, can you explain a bit more.
We have a circular dependency:
- The resource type is stored in the meta data.
- The location of the meta data is determined by the DocIdToPathMapper.
- The DocIdToPathMapper should be determined by the resource type.
That's why we have to break a dependency. The easiest one
to break is the dependency from the meta data location to
the DocIdToPathMapper. We could use a generic location for
meta files, without using the mapper. Just something like
{document-id}.{language}.meta
This way, we can
- read the meta file
- determine the resource type
- call resourceType.getPathMapper().getPath(document)
which will return /foo/bar/index_en.odt for the ODT resource type.
-- Andreas
--------------------------------------------------------------
Andreas Hartmann andreas.hartmann@wyona.com +41 1 272 9161
Wyona AG, Hardstrasse 219, CH-8005 Zurich
Open Source CMS http://www.wyona.org http://www.wyona.com
--------------------------------------------------------------
---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@lenya.apache.org
For additional commands, e-mail: dev-help@lenya.apache.org
Re: svn commit: r383910 - in /lenya/trunk/src/modules/opendocument:config/cocoon-xconf/
config/menus/java/ java/src/ java/src/org/java/src/org/apache/
java/src/org/apache/lenya/java/src/org/apache/lenya/cms/ java/src/org/apache/lenya/cms/site/java/src...
Posted by Andreas Hartmann <an...@apache.org>.
Michael Wechner wrote:
> Andreas Hartmann wrote:
>
>> [...]
>>
>>
>>
>>>> - the resource type can be asked for the path to read the document from
>>>> (or maybe it is sufficient to ask the resource type for the
>>>> file extension)
>>>>
>>> I dunno understand, can you explain a bit more.
>>>
>>
>> We have a circular dependency:
>>
>> - The resource type is stored in the meta data.
>> - The location of the meta data is determined by the DocIdToPathMapper.
>> - The DocIdToPathMapper should be determined by the resource type.
>>
>> That's why we have to break a dependency. The easiest one
>> to break is the dependency from the meta data location to
>> the DocIdToPathMapper. We could use a generic location for
>> meta files, without using the mapper. Just something like
>>
>> {document-id}.{language}.meta
>>
>>
>
> why not have something like
>
> .lenya/meta/{document-id}
>
> whereas the ".lenya" would be configurable?
The best would be to use UUIDs, otherwise the meta data files
have to be moved when documents are move.
> (this path could also be used within a JCR repo)
>
> It seems to me that SVN shows how nicely this can be
> done and how clear it separates ones data from the managing
> system.
Good point. The hidden directories certainly make sense.
-- 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: r383910 - in /lenya/trunk/src/modules/opendocument:config/cocoon-xconf/
config/menus/java/ java/src/ java/src/org/java/src/org/apache/
java/src/org/apache/lenya/java/src/org/apache/lenya/cms/ java/src/org/apache/lenya/cms/site/java/src...
Posted by Andreas Hartmann <an...@apache.org>.
Michael Wechner wrote:
> Andreas Hartmann wrote:
>
>> [...]
>>
>>
>>
>>>> - the resource type can be asked for the path to read the document from
>>>> (or maybe it is sufficient to ask the resource type for the
>>>> file extension)
>>>>
>>> I dunno understand, can you explain a bit more.
>>>
>>
>> We have a circular dependency:
>>
>> - The resource type is stored in the meta data.
>> - The location of the meta data is determined by the DocIdToPathMapper.
>> - The DocIdToPathMapper should be determined by the resource type.
>>
>> That's why we have to break a dependency. The easiest one
>> to break is the dependency from the meta data location to
>> the DocIdToPathMapper. We could use a generic location for
>> meta files, without using the mapper. Just something like
>>
>> {document-id}.{language}.meta
>>
>>
>
> why not have something like
>
> .lenya/meta/{document-id}
>
> whereas the ".lenya" would be configurable?
> (this path could also be used within a JCR repo)
Just FYI: The JCRSourceNode uses JCR properties to store the
meta data, so no special path is needed.
-- 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: r383910 - in /lenya/trunk/src/modules/opendocument:config/cocoon-xconf/
config/menus/java/ java/src/ java/src/org/java/src/org/apache/
java/src/org/apache/lenya/java/src/org/apache/lenya/cms/ java/src/org/apache/lenya/cms/site/java/src...
Posted by Michael Wechner <mi...@wyona.com>.
Andreas Hartmann wrote:
>[...]
>
>
>
>>>- the resource type can be asked for the path to read the document from
>>> (or maybe it is sufficient to ask the resource type for the
>>> file extension)
>>>
>>>
>>I dunno understand, can you explain a bit more.
>>
>>
>
>We have a circular dependency:
>
>- The resource type is stored in the meta data.
>- The location of the meta data is determined by the DocIdToPathMapper.
>- The DocIdToPathMapper should be determined by the resource type.
>
>That's why we have to break a dependency. The easiest one
>to break is the dependency from the meta data location to
>the DocIdToPathMapper. We could use a generic location for
>meta files, without using the mapper. Just something like
>
> {document-id}.{language}.meta
>
>
why not have something like
.lenya/meta/{document-id}
whereas the ".lenya" would be configurable?
(this path could also be used within a JCR repo)
It seems to me that SVN shows how nicely this can be
done and how clear it separates ones data from the managing
system.
Michi
>This way, we can
>
>- read the meta file
>- determine the resource type
>- call resourceType.getPathMapper().getPath(document)
>
>which will return /foo/bar/index_en.odt for the ODT resource type.
>
>-- Andreas
>
>--------------------------------------------------------------
>Andreas Hartmann andreas.hartmann@wyona.com +41 1 272 9161
> Wyona AG, Hardstrasse 219, CH-8005 Zurich
>Open Source CMS http://www.wyona.org http://www.wyona.com
>--------------------------------------------------------------
>
>---------------------------------------------------------------------
>To unsubscribe, e-mail: dev-unsubscribe@lenya.apache.org
>For additional commands, e-mail: dev-help@lenya.apache.org
>
>
>
>
--
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