cancel
Showing results for 
Search instead for 
Did you mean: 

Content is not being indexed by Lucene

nrk
Champ in-the-making
Champ in-the-making
Hi,

I'm unable to get Lucene to index content I place into the repository. I figure I'm doing something wrong but not able to locate where!

I have created a new type whose parent is "cm:content" since I have extra properties to fill up. I placed the contents of a word doc into the property "cm:content" but though Lucene indexing  seems to be enabled by default for this property nothing happens.

- Will indexing only work for content created directly of type "cm:content"?
- Is there any significance for the type (cm:content) and the property (cm:content) holding the actual content having the same name?

thanks!
4 REPLIES 4

andy
Champ on-the-rise
Champ on-the-rise
Hi

From what you have said things should be fine.
Can you post the the model changes you have made?

Indexing should work for all properties regardless of the type structure.
Indexing into the "full text" magic bucket for content is only done for properties of type d:content. They are also indexed in their own right.

It may be worth reading the data dictionary documentation on the wiki to make sure you are not missing something.

Regards

Andy

nrk
Champ in-the-making
Champ in-the-making
sorry, I goofed up!

The content type was "octect stream" and I'm assuming Alfresco might ignore types for which there are no text extractors.
The content was created using code rather than the Alfresco Web app. I dont know how to set contenttype via code.

I reset the contenttype via the web app and then the content was indexed…can you tell me how I set this via code?

thanks!

andy
Champ on-the-rise
Champ on-the-rise
Hi

No problem.

There is a simple example to get going with content.
See root\projects\repository\source\java\org\alfresco\example\SimpleExampleWithContent.java

This has the basics for creating a node with content, writing content, setting mime types and encoding, reading content etc ….

Regards

Andy

nrk
Champ in-the-making
Champ in-the-making
thanks! got that to work.