Expand my Community achievements bar.

Don’t miss the AEM Skill Exchange in SF on Nov 14—hear from industry leaders, learn best practices, and enhance your AEM strategy with practical tips.
SOLVED

Assets do not index filename

Avatar

Level 6

Hi,

Is this possible to do not index the filename of the Asset?

The customer do not want to retrieve assets by their filenames.

Would it be possible?

I know I can exclude a property from be indexed, but didn't see anything about this.

Thanks

1 Accepted Solution

Avatar

Correct answer by
Administrator

Please have a look at this documentation link :-

//Link:- https://docs.adobe.com/docs/en/aem/6-1/deploy/platform/queries-and-indexing.html

 

Configuring the indexes

 

Indexes are configured as nodes in the repository under the oak:index node.

The type of the index node must be oak:QueryIndexDefinition. Several configuration options are available for each indexer as node properties. For more information, see the configuration details for each indexer type below.

THE PROPERTY INDEX

 

The Property Index is generally useful for queries that have property constraints but are not full-text. It can be configured by following the below procedure:

 

  • Create a new node under oak:index

  • Name the node PropertyIndex, and set the node type to oak:QueryIndexDefinition

  •  

    Set the following properties for the new node:

    • type: property (of type String)
    • propertyNames: jcr:uuid (of type Name)

    This particular example will index the jcr:uuid property, whose job is to expose the universally unique idetifier (UUID) of the node it is attached to.

  • Save the changes.

     

    The Property Index has the following configuration options:

    • The type property will specify the type of index, and in this case it must be set to property
    • The propertyNames property indicates the list of the properties that will be stored in the index. In case it is missing, the node name will be used as a property name reference value. In this example, the jcr:uuid property whose job is to expose the unique identifier (UUID) of its node is added to the index.
    • The unique flag which, if set to true adds a uniqueness constraint on the property index.
    • The declaringNodeTypes propery allows you to specify a certain node type that the index will only apply to.
    • The reindex flag which if set to true, will trigger a full content reindex.

    I hope this would act as some help to you.

    Thanks and Regards

    Kautuk Sahni



    Kautuk Sahni

    View solution in original post

    4 Replies

    Avatar

    Level 10

    which version of AEM are you using ??

    when you say do not want to retrieve assets by filenames - Is it via search in author instance ? that will do a full text search. Indexes would just help in searching faster and by removing the indexes doesnt mean to hide from searching.

    Avatar

    Level 6

    Hi @bsloki,

    I am using  6.1. 

    I see your point. In this case if it is not possible I will check with the users.

    Thanks

    Avatar

    Correct answer by
    Administrator

    Please have a look at this documentation link :-

    //Link:- https://docs.adobe.com/docs/en/aem/6-1/deploy/platform/queries-and-indexing.html

     

    Configuring the indexes

     

    Indexes are configured as nodes in the repository under the oak:index node.

    The type of the index node must be oak:QueryIndexDefinition. Several configuration options are available for each indexer as node properties. For more information, see the configuration details for each indexer type below.

    THE PROPERTY INDEX

     

    The Property Index is generally useful for queries that have property constraints but are not full-text. It can be configured by following the below procedure:

     

    • Create a new node under oak:index

    • Name the node PropertyIndex, and set the node type to oak:QueryIndexDefinition

    •  

      Set the following properties for the new node:

      • type: property (of type String)
      • propertyNames: jcr:uuid (of type Name)

      This particular example will index the jcr:uuid property, whose job is to expose the universally unique idetifier (UUID) of the node it is attached to.

    • Save the changes.

       

      The Property Index has the following configuration options:

      • The type property will specify the type of index, and in this case it must be set to property
      • The propertyNames property indicates the list of the properties that will be stored in the index. In case it is missing, the node name will be used as a property name reference value. In this example, the jcr:uuid property whose job is to expose the unique identifier (UUID) of its node is added to the index.
      • The unique flag which, if set to true adds a uniqueness constraint on the property index.
      • The declaringNodeTypes propery allows you to specify a certain node type that the index will only apply to.
      • The reindex flag which if set to true, will trigger a full content reindex.

      I hope this would act as some help to you.

      Thanks and Regards

      Kautuk Sahni



      Kautuk Sahni

      Avatar

      Level 6

      Hi Kautuk,

      Thanks for your reply.

      I saw this documentation. Do you know what would be the property name I would need to configure for this?

      As I could see the filename is the node name in JCR I didn't find How to disable this to be indexed.

      Thanks