cancel
Showing results for 
Search instead for 
Did you mean: 

Selective Audit

onewnan
Champ in-the-making
Champ in-the-making
I am a newbie so if I have missed a documentation resource that answers this question, kindly just point me to it. 

The book "Alfresco Enterprise Content Management Implementation" tells us how to turn on full auditing.  However, is there a way to do so for some spaces within a repository but not others?  Audit can have a significant performance impact–and not all content requires the same level of audit.
1 REPLY 1

cbosdonnat
Champ in-the-making
Champ in-the-making
Hi,

I don't think Alfresco auditing component can filter on the key path. However you can do do it by changing the AuditComponent and adding your own filtering configuration. The bean to change is:

<bean id="auditComponent" class="xxxx.YourAuditImpl">
        <property name="personService">
            <ref bean="personService"/>
        </property>
        <property name="nodeService">
            <ref bean="nodeService"/>
        </property>
        <property name="authorityService">
            <ref bean="authorityService"/>
        </property>
        <property name="sessionFactory">
            <ref bean="sessionFactory"/>
        </property>
        <property name="publicServiceIdentifier">
            <ref bean="publicServiceIdentifier"/>
        </property>
        <property name="auditDAO">
            <ref bean="auditDao"/>
        </property>
         <property name="auditFailedDAO">
            <ref bean="auditFailedDao"/>
        </property>
        <property name="auditConfiguration">
            <ref bean="auditConfiguration"/>
        </property>
        <property name="auditModel">
            <ref bean="auditModel"/>
        </property>
        <property name="transactionService">
            <ref bean="transactionService"/>
        </property>
    </bean>

Overriding the AuditComponentImpl class cleanly is pretty hard as many methods are private.

HTH