Support

Document filtering

The documents are primarily downloaded during the synchronization. Because the external storage (e.g. the SharePoint server) may contain terabytes of data,
Woodford admin has the possibility to define document filters.

<?xml version="1.0" encoding="utf-8"?>
<BlobStoreFilter>
<FilesFilter>
  <Quota>1000000000</Quota>
  <MaxFileSize>100000</MaxFileSize>
</FilesFilter>
</BlobStoreFilter>

Above is an example of a trivial cloud document filter that says:

  1. MaxFileSize: Do not download cloud documents larger than 100K.
  2. Quota: Stop downloading when b) l size of all cloud documents exceeds 1GB.

 
 
Here is a more complex example:

<?xml version="1.0" encoding="utf-8"?>
<BlobStoreFilter>
<FilesFilter>
  <Quota>1000000000</Quota>
  <Filters>
   <BlobStoreFileTypeFilter>
    <FileSuffix>jpg</FileSuffix>
    <MaxFileSize>1000000</MaxFileSize>
   </BlobStoreFileTypeFilter>
   <BlobStoreFileTypeFilter>
    <FileSuffix>*</FileSuffix>
    <MaxFileSize>100000</MaxFileSize>
   </BlobStoreFileTypeFilter>
  </Filters>
</FilesFilter>
</BlobStoreFilter>

The filter above specifies the quota and additional conditions:

a) Download jpeg images up to the 1MB size
b) Any other file type is limited to 100K size

 
 
It applies to cloud documents, however, you can filter CRM attachments (notes) as well. Here is an example:


<?xml version="1.0" encoding="utf-8"?>
<BlobStoreFilter>
<FilesFilter/>
<AttachmentsFilter>
  <MaxAttachmentSize>300000</MaxAttachmentSize>
  <NotSyncingAttachmentsFor>
   <string>contact</string>
   <string>campaign</string>
  </NotSyncingAttachmentsFor>

   <EntityFilters>
   <EntityAttachmentsFilter Entity="annotation" AttachedTo="account">
    <MaxFileSize>150000</MaxFileSize>
    <Filters>
     <BlobStoreFileTypeFilter>
      <FileSuffix>jpg</FileSuffix>
      <MaxFileSize>50000</MaxFileSize>
     </BlobStoreFileTypeFilter>
     <BlobStoreFileTypeFilter>
      <FileSuffix>doc</FileSuffix>
      <MaxFileSize>100000</MaxFileSize>
     </BlobStoreFileTypeFilter>
    </Filters>
   </EntityAttachmentsFilter>

   <EntityAttachmentsFilter Entity="annotation">
    <Quota>-1</Quota>
    <MaxFileSize>300000</MaxFileSize>
    <Filters />
   <EntityAttachmentsFilter Entity="activitymimeattachment">
  </EntityFilters>
</AttachmentsFilter>
</BlobStoreFilter>

Explanation:
– If there are multiple EntityAttachmentsFilter nodes that apply to given attachment, then all of them must be fulfilled.
– MaxAttachmentSize defines the size limit applicable to all attachments. (Same effect as MaxFileSize in the Setup form.)
– NotSyncingAttachmentsFor is used to specify entity types for which no attachments are downloaded.
– Account annotations are limited to 150K, however there is a stricter limit for *.jpg files (50K) and *.doc files (100K).
– All annotations (except account annotations) are limited to 300K.
– ActivityMimeAttachment’s use custom size limit.

 
 
Starting with Resco Mobile CRM version 11.1 (Summer Update 2018), you can also utilize a positive condition to filter selected attachments, e.g.:

<AttachmentsFilter>
<MaxAttachmentSize>100000</MaxAttachmentSize>
<OnlySyncingAttachmentsFor>
   <string>contact</string>
   <string>account</string>
</OnlySyncingAttachmentsFor>
</AttachmentsFilter>

 
 
Notes:
– Files that do not pass filter conditions are not downloaded. However, these files are listed on the screen and can be downloaded on demand.
– Size “-1” means unlimited. Size “0” means nothing allowed.
– AttachmentsFilter Quota values are ignored at the time of writing. (MCRM 10.1.0.2)
– If you do not have any explicit BlobStoreFilter, MCRM will use an implicit filter that specifies a quota of 4GB and MaxFileSize as defined in the Setup form
– Pay attention that you use one of the forms of the conditions (positive and negative; NotSyncingAttachmentsForm & OnlySyncingAttachmentsForm), but not both. (Formally allowed, but does not make sense

The document filter is the most frequent reason that causes not-downloaded documents. Other common errors are various download failures, such as web communication errors.