code: public void apply(ChangesHolder changes) throws RepositoryException, IOException
     {
        checkOpen();
        // index may not be initialized, but some operation can be performed in cluster environment
        if (indexRegister.getDefaultIndex() != null)
        {
           indexRegister.getDefaultIndex().update(changes.getRemove(), changes.getAdd());
        }
  
        //Apply the changes on all registered index related to SearchIndex component
        for(MultiIndex index : indexRegister.getIndexList())
        {
           try
           {
              index.update(changes.getRemove(), changes.getAdd());
           }
           catch (Exception e)
           {
              log.error("Error indexing changes " + e, e);
              try
              {
                 logErrorChanges(indexRegister.getErrorLogs(index), new HashSet<String>(changes.getRemove()), new HashSet<String>(changes
                         .getAddIds()));
              }
              catch (IOException ioe)
              {
                 log.warn("Exception occure when errorLog writed. Error log is not complete. " + ioe, ioe);
              }
           }
        }
  
     }
docs: {@inheritDoc}