You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@jackrabbit.apache.org by Ard Schrijvers <a....@hippo.nl> on 2007/12/21 13:37:22 UTC

Regarding IndexingConfiguration

Yesterday I tried to use 

<?xml version="1.0"?>
<!DOCTYPE configuration SYSTEM
"http://jackrabbit.apache.org/dtd/indexing-configuration-1.0.dtd">
<configuration xmlns:nt="http://www.jcp.org/jcr/nt/1.0">
  <index-rule nodeType="nt:unstructured">
    <property nodeScopeIndex="false">someProp</property>
  </index-rule>
</configuration>

and thought that this would mean that all properties would be nodescope
indexed, except 'someProp'. Perhaps I am wrong about my expectation, but
this index-rule results in that no property at all makes it to the
nodescope index. AFAICS, there is no easy way to exclude one single
property from the nodescope, without having to add *all* properties you
do want in the nodescope. Is this behavior correct and intentional? 

Regards Ard

RE: Regarding IndexingConfiguration

Posted by Ard Schrijvers <a....@hippo.nl>.
Hi Marcel

> 
> yes, this is correct and intended.
> 
> reason for this is, that I wanted people to explicitly 
> declare what they want to index, instead of a default that 
> includes everything (well, that actually is the default if 
> there is *no* configuration at all ;) ).

Ok. Not really a problem for me (would consider it a matter of taste
anyway), but I just had this usecase which I could not accomplish with
only configuring the indexing_configuration. I'll get around it. Thx for
the explanation,

Regards Ard

> 
> regards
>   marcel
> 

Re: Regarding IndexingConfiguration

Posted by Marcel Reutegger <ma...@gmx.net>.
Hi Ard,

Ard Schrijvers wrote:
> Yesterday I tried to use 
> 
> <?xml version="1.0"?>
> <!DOCTYPE configuration SYSTEM
> "http://jackrabbit.apache.org/dtd/indexing-configuration-1.0.dtd">
> <configuration xmlns:nt="http://www.jcp.org/jcr/nt/1.0">
>   <index-rule nodeType="nt:unstructured">
>     <property nodeScopeIndex="false">someProp</property>
>   </index-rule>
> </configuration>
> 
> and thought that this would mean that all properties would be nodescope
> indexed, except 'someProp'. Perhaps I am wrong about my expectation, but
> this index-rule results in that no property at all makes it to the
> nodescope index. AFAICS, there is no easy way to exclude one single
> property from the nodescope, without having to add *all* properties you
> do want in the nodescope. Is this behavior correct and intentional? 

yes, this is correct and intended.

reason for this is, that I wanted people to explicitly declare what they want to 
index, instead of a default that includes everything (well, that actually is the 
default if there is *no* configuration at all ;) ).

regards
  marcel