Re: [Zope3-Users] Looking for "best practice" in content indexing

2006-10-03 Thread Tom Dossis
Thierry Florac wrote:
>  - generally speaking, is it better to keep a single "big catalog", or a
> set of many catalogs, each of them indexing a smaller set of classes ? I
> suppose that querying is more simple with a single catalog, but what
> about general performances ??

With the hurry.query package it's just as easy to query across multiple
(named) catalogs.  I prefer to avoid monolithic catalogs with lots of
indexes.

>  - I have to index "main content", but also "reference" classes which
> are used to classify my main content (example : I describe "forests" in
> a first step and afterwards, my main contents can be affected to one or
> more forests). In such a case, I want to make queries concerning forests
> themselves, but also queries about main content concerning forests they
> are attached to (to get, for example, every subject attached to a given
> forest). In this case also, is it better to keep track of the reference
> itself (myContent.forest = myForest) or of an attribute of the reference
> (myContent.forestId = myForest.uniqueId) ??
>  - perhaps a stupid question, but what's the best method to get the
> equivalent of Zope2's "meta_type" indexing, to only get instances of a
> given class, when queried indexes are applied to several classes
> (example : I use adapters to handle workflow publication on a wide set
> of classes, and I want to retrieve contents of a given class in a given
> workflow step) ??

___
Zope3-users mailing list
Zope3-users@zope.org
http://mail.zope.org/mailman/listinfo/zope3-users


Re: [Zope3-Users] Looking for "best practice" in content indexing

2006-10-03 Thread Lennart Regebro

On 10/3/06, Thierry Florac <[EMAIL PROTECTED]> wrote:

 - generally speaking, is it better to keep a single "big catalog", or a
set of many catalogs, each of them indexing a smaller set of classes ? I
suppose that querying is more simple with a single catalog, but what
about general performances ??


That completely depends on what you are gonna do.

I would say that you should have one catalog, except for specail
cases, where you index a certain type only to do a certain type of
lookups. (In those cases, you often don't even need a whole catalog,
but a BTree is often enough).


 - I have to index "main content", but also "reference" classes which
are used to classify my main content (example : I describe "forests" in
a first step and afterwards, my main contents can be affected to one or
more forests). In such a case, I want to make queries concerning forests
themselves, but also queries about main content concerning forests they
are attached to (to get, for example, every subject attached to a given
forest). In this case also, is it better to keep track of the reference
itself (myContent.forest = myForest) or of an attribute of the reference
(myContent.forestId = myForest.uniqueId) ??


I'd go with the attribute, although I guess a field index should be
able to index the object directly (haven't tried though).


 - perhaps a stupid question, but what's the best method to get the
equivalent of Zope2's "meta_type" indexing, to only get instances of a
given class, when queried indexes are applied to several classes
(example : I use adapters to handle workflow publication on a wide set
of classes, and I want to retrieve contents of a given class in a given
workflow step) ??


Hmm. What a good question. :)

--
Lennart Regebro, Nuxeo http://www.nuxeo.com/
CPS Content Management http://www.cps-project.org/
___
Zope3-users mailing list
Zope3-users@zope.org
http://mail.zope.org/mailman/listinfo/zope3-users


[Zope3-Users] Looking for "best practice" in content indexing

2006-10-03 Thread Thierry Florac

  Hi,

I'm currently looking for a good content indexing method. 
I'm OK concerning general Catalog usage, but I still have a few
questions ; I just hope that my english will be good enough for you to
understand what I mean... :
 - generally speaking, is it better to keep a single "big catalog", or a
set of many catalogs, each of them indexing a smaller set of classes ? I
suppose that querying is more simple with a single catalog, but what
about general performances ??
 - I have to index "main content", but also "reference" classes which
are used to classify my main content (example : I describe "forests" in
a first step and afterwards, my main contents can be affected to one or
more forests). In such a case, I want to make queries concerning forests
themselves, but also queries about main content concerning forests they
are attached to (to get, for example, every subject attached to a given
forest). In this case also, is it better to keep track of the reference
itself (myContent.forest = myForest) or of an attribute of the reference
(myContent.forestId = myForest.uniqueId) ??
 - perhaps a stupid question, but what's the best method to get the
equivalent of Zope2's "meta_type" indexing, to only get instances of a
given class, when queried indexes are applied to several classes
(example : I use adapters to handle workflow publication on a wide set
of classes, and I want to retrieve contents of a given class in a given
workflow step) ??

Thanks for your advises,

  Thierry Florac
-- 
  Chef de projet intranet/internet
  Office National des Forêts - Département Informatique
  2, Avenue de Saint-Mandé
  75570 PARIS Cedex 12
  Mél : [EMAIL PROTECTED]
  Tél. : +33 01.40.19.59.64
  Fax. : +33 01.40.19.59.85

___
Zope3-users mailing list
Zope3-users@zope.org
http://mail.zope.org/mailman/listinfo/zope3-users