Вернуться   AXForum > Microsoft Dynamics CRM > Dynamics CRM: Blogs
Забыли пароль?
Зарегистрироваться Правила Справка Пользователи Сообщения за день Поиск Все разделы прочитаны

Опции темы Поиск в этой теме Опции просмотра
Старый 16.03.2012, 00:11   #1  
Blog bot is offline
Blog bot
24,417 / 822 (76) +++++++
Регистрация: 28.10.2006
crminthefield: Dynamics CRM 2011 DeletionService Async Maintenance Operation Demystified

I recently had a customer ask me about the purpose of the DeletionService maintenance operation (AsyncOperationType = 14) executed by the AsyncService in Dynamics CRM 2011.  To provide some context from CRM 4.0, the DeletionService performed physical data cleanup on records that had been logically deleted through the application by setting the DeletionStateCode = ‘2’.  This behavior no longer occurs in CRM 2011 – when records are deleted through the application, they are physically deleted from the database.  So, why the need for a DeletionService maintenance operation?

The database maintenance performed by the DeletionService operation focuses both on organization-wide cleanup and record-specific cleanup.  For the latter cleanup to be performed it’s important to note that during the initial delete action while records are removed from the entity tables, they are also inserted to the dbo.SubscriptionTrackingDeletedObject table.  This table provides the DeletionService with specific ObjectId’s that have been removed so that further, asynchronous cleanup can be performed.

Suppose I have an existing Account:

I then delete the Account through the native application.  Notice, the record is physically deleted from AccountBase, but has now been inserted to SubscriptionTrackingDeletedObject.  The stored procedure ‘p_GetTablesForDeletion’ is called at the beginning of the DeletionService operation to gather up entity types requiring cleanup.

What type of cleanup do you say?  Primarily, Matchcode (duplicate detection) and PrincipalObjectAccess/POA (inherited and shared privileges) records left behind from deleted entity records.

Here are the general steps that the DeletionService performs when executing its maintenance routine:

  • Gather up entity tables requiring deletion cleanup by calling p_GetTablesForDeletion stored procedure
  • Perform entity specific cleanup for each table returned by joining to the SubscriptionTrackingDeletedObject table
    • Delete associated Matchcode records
    • Delete associated PrincipalObjectAccess (POA) records
  • Delete expired client sync subscriptions
  • Delete SubscriptionTrackingDeletedObject records
  • Delete PostRegarding records based on deleted Posts (activity feeds)
So now you know, the rest of the story…

Austin Jones

Microsoft Premier Field Engineer

Расскажите о новых и интересных блогах по Microsoft Dynamics, напишите личное сообщение администратору.

Похожие темы
Тема Автор Раздел Ответов Посл. сообщение
crminthefield: Podcast and Overview: Microsoft Dynamics CRM 2011 Update Rollup 4 Blog bot Dynamics CRM: Blogs 0 24.09.2011 01:16
crminthefield: Microsoft Dynamics CRM 4.0 and 2011 Update Rollup Release Dates, Build Numbers, and Collateral Blog bot Dynamics CRM: Blogs 0 24.08.2011 02:11
Microsoft Dynamics CRM Team Blog: Microsoft Dynamics CRM 2011 ~ Online Test Drive Guide Blog bot Dynamics CRM: Blogs 0 05.08.2011 20:13
Все о Microsoft Dynamics CRM: Как установить Microsoft Dynamics CRM 2011 Beta Blog bot Dynamics CRM: Blogs 0 31.10.2010 15:08
CRM DE LA CREME! Configuring Microsoft Dynamics CRM 4.0 for Internet-facing deployment Blog bot Dynamics CRM: Blogs 0 18.08.2009 11:05
Опции темы Поиск в этой теме
Поиск в этой теме:

Расширенный поиск
Опции просмотра

Ваши права в разделе
Вы не можете создавать новые темы
Вы не можете отвечать в темах
Вы не можете прикреплять вложения
Вы не можете редактировать свои сообщения

BB коды Вкл.
Смайлы Вкл.
[IMG] код Вкл.
HTML код Выкл.
Быстрый переход

Часовой пояс GMT +3, время: 06:40.
Powered by vBulletin® v3.8.5. Перевод: zCarot
Контактная информация, Реклама.