Set up Azure Blob file storage integration
Azure Blob file storage is a cloud-based solution by Microsoft. Learn more: official vendor documentation. Using the Azure Blob storage lets you reduce the Creatio database size. Data is stored as BLOB objects. Learn more: Wikipedia.
You can only connect Creatio to one Azure Blob storage.
If you want to develop functionality that will create, download, delete or do any other operations with files that are stored in external file storage, then use FileAPI for that. Learn more: API for file management (developer documentation)
If you use Creatio in the cloud, contact Creatio support to integrate an Azure Blob storage.
To integrate an Azure Blob file storage to Creatio on-site:
- Setup in Azure Blob. Read more >>>
- Setup in Creatio. Read more >>>
Setup in Azure Blob
-
Sign up to the Microsoft Azure portal. Learn more: official vendor documentation.
-
Enable Creatio to access the storage. To do this, generate a "Blob Service endpoint" parameter.
-
Enable authorized requests to the storage. To do this, generate the "AccountName" and "AccountKey" parameters. Learn more: official vendor documentation.
-
Create "ObjectContainerName" and "RecycleContainerName" containers that have unique names.
- "ObjectContainerName" is a container that stores files The files are stored indefinitely.
- "RecycleContainerName" is a container that stores deleted files. They are kept for database backups. Container management is based on the soft deletion principle: a file deleted from the "ObjectContainerName" container is moved to the "RecycleContainerName" container. The storage time for deleted files is controlled by the container settings of the service. For example, a file can be stored in the container for 90 days, then deleted automatically. In Creatio, the storage time for deleted files is the same as the storage time for database backups.
Learn more: official vendor documentation.
Setup in Creatio
To save new files uploaded to the Attachments detail or email attachments to the Azure Blob storage rather than the database, take the following steps in Creatio:
-
Set up a connection to the Azure Blob storage. To do this, add an Azure Blob storage connection string to the
connectionStrings
parameter of the ConnectionStrings.config configuration file:<connectionStrings>
...
<add name="azureConnection" connectionString="AccountName=SOME_ACCOUNT_NAME; AccountKey=SOME_ACCOUNT_KEY; BlobEndpoint=SOME_BLOB_ENDPOINT; ObjectContainerName=SOME_OBJECT_CONTAINER_NAME; RecycleContainerName=SOME_RECYCLE_CONTAINER_NAME;" />
</connectionStrings>where
AccountName
is the account name for making an authorized request to the Azure Blob storage.AccountKey
is the account key for making an authorized request to the Azure Blob storage.BlobEndpoint
is the endpoint for accessing the Azure Blob storage. The value of the "Blob Service endpoint" parameter obtained in the previous step.ObjectContainerName
is the name of the container that stores files.RecycleContainerName
is the name of the container that stores deleted files. They are kept for database backups.
-
Enable the "UseBaseEntityFileDeleteListener" additional feature to ensure that connected files are also moved to "RecycleContainerName" correctly when a section record is deleted. To do this, change the status of the "UseBaseEntityFileDeleteListener" additional feature. Instructions: Change the status of an additional feature for all users (developer documentation).
-
Set the Azure Blob storage as the active file storage. To do this, open the "Active File Content Storage" ("ActiveFileContentStorage" code) system setting. Select "Azure Blob storage" in the Default value field.
As a result, all files added to Creatio after connecting the Azure Blob storage will be uploaded there. Files previously added to Creatio will remain in the original storage. You can migrate previously added files from Creatio database to the "ObjectContainerName" container in the Azure Blob file storage and vice versa. Instructions: Migrate files between database and external file storages.
See also
Migrate files between database and external file storages
Set up S3 file storage integration
Manage an existing additional feature (developer documentation)
Official Azure Blob documentation
Binary large object (Wikipedia)