You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@jackrabbit.apache.org by flopsi73 <fl...@flopsi.org> on 2008/09/05 13:51:34 UTC
Indexing configuration ignored?!?
Hello everybody,
i use an index configuration like this...
<?xml version="1.0"?>
<!DOCTYPE configuration SYSTEM
"http://jackrabbit.apache.org/dtd/indexing-configuration-1.0.dtd">
<configuration xmlns:jcr="http://www.jcp.org/jcr/1.0"
xmlns:nt="http://www.jcp.org/jcr/nt/1.0">
<index-rule nodeType="nt:resource">
<property>jcr:data</property>
</index-rule>
</configuration>
...assuming that now only the jcr:data property of nt:resource nodes is
indexed. But debugging into Jackrabbit (e.g. setting a breakpoint in
NodeIndexer.addStringValue, which should IMO never be touched anymore, but
in fact is) makes me think still all properties of all nodes are indexed.
Looking at the code i also cannot find where 'Indexing rules defined for a
base type also apply to sub types'
(http://wiki.apache.org/jackrabbit/IndexingConfiguration) is implemented.
So my questions are: Am i wrong in either configuration or interpretation of
code? Is the mentioned inheritance really implemented?
Thanx, best regards
Flo
--
View this message in context: http://www.nabble.com/Indexing-configuration-ignored-%21--tp19329602p19329602.html
Sent from the Jackrabbit - Dev mailing list archive at Nabble.com.
Re: Indexing configuration ignored?!?
Posted by flopsi73 <fl...@flopsi.org>.
Hi Marcel,
first thanks for quick answer!
I tried adding the second tag, but still NodeIndexer.addStringValue is
called for different node types and properties. By the way, having looked at
http://www.nabble.com/Regarding-IndexingConfiguration-td14454838.html
i thought
<index-rule nodeType="nt:resource">
<property>jcr:data</property>
</index-rule>
should be enough...
Best regards
Flo
Marcel Reutegger wrote:
>
> Hi Flo,
>
> when a node is indexed and no index-rule applies, then all properties are
> indexed. if you want to disable indexing for all nodes except nt:resource
> you
> need to add a second index-rule after the one for nt:resource:
>
> <index-rule nodeType="nt:base">
> </index-rule>
>
> this rule always applies because all nodes are of type nt:base.
>
> regards
> marcel
>
> flopsi73 wrote:
>> Hello everybody,
>> i use an index configuration like this...
>>
>> <?xml version="1.0"?>
>> <!DOCTYPE configuration SYSTEM
>> "http://jackrabbit.apache.org/dtd/indexing-configuration-1.0.dtd">
>> <configuration xmlns:jcr="http://www.jcp.org/jcr/1.0"
>> xmlns:nt="http://www.jcp.org/jcr/nt/1.0">
>> <index-rule nodeType="nt:resource">
>> <property>jcr:data</property>
>> </index-rule>
>> </configuration>
>>
>> ...assuming that now only the jcr:data property of nt:resource nodes is
>> indexed. But debugging into Jackrabbit (e.g. setting a breakpoint in
>> NodeIndexer.addStringValue, which should IMO never be touched anymore,
>> but
>> in fact is) makes me think still all properties of all nodes are indexed.
>>
>> Looking at the code i also cannot find where 'Indexing rules defined for
>> a
>> base type also apply to sub types'
>> (http://wiki.apache.org/jackrabbit/IndexingConfiguration) is implemented.
>>
>> So my questions are: Am i wrong in either configuration or interpretation
>> of
>> code? Is the mentioned inheritance really implemented?
>>
>> Thanx, best regards
>> Flo
>>
>
>
>
--
View this message in context: http://www.nabble.com/Indexing-configuration-ignored-%21--tp19329602p19330700.html
Sent from the Jackrabbit - Dev mailing list archive at Nabble.com.
Re: Indexing configuration ignored?!?
Posted by Marcel Reutegger <ma...@gmx.net>.
Hi Flo,
when a node is indexed and no index-rule applies, then all properties are
indexed. if you want to disable indexing for all nodes except nt:resource you
need to add a second index-rule after the one for nt:resource:
<index-rule nodeType="nt:base">
</index-rule>
this rule always applies because all nodes are of type nt:base.
regards
marcel
flopsi73 wrote:
> Hello everybody,
> i use an index configuration like this...
>
> <?xml version="1.0"?>
> <!DOCTYPE configuration SYSTEM
> "http://jackrabbit.apache.org/dtd/indexing-configuration-1.0.dtd">
> <configuration xmlns:jcr="http://www.jcp.org/jcr/1.0"
> xmlns:nt="http://www.jcp.org/jcr/nt/1.0">
> <index-rule nodeType="nt:resource">
> <property>jcr:data</property>
> </index-rule>
> </configuration>
>
> ...assuming that now only the jcr:data property of nt:resource nodes is
> indexed. But debugging into Jackrabbit (e.g. setting a breakpoint in
> NodeIndexer.addStringValue, which should IMO never be touched anymore, but
> in fact is) makes me think still all properties of all nodes are indexed.
>
> Looking at the code i also cannot find where 'Indexing rules defined for a
> base type also apply to sub types'
> (http://wiki.apache.org/jackrabbit/IndexingConfiguration) is implemented.
>
> So my questions are: Am i wrong in either configuration or interpretation of
> code? Is the mentioned inheritance really implemented?
>
> Thanx, best regards
> Flo
>