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

 
 
Опции темы Поиск в этой теме Опции просмотра
Старый 07.10.2014, 17:11   #1  
Blog bot is offline
Blog bot
Участник
 
25,531 / 847 (80) +++++++
Регистрация: 28.10.2006
emeadaxsupport: AXRETAIL: How to control the Action flow
Источник: http://blogs.msdn.com/b/axsupport/ar...tion-flow.aspx
==============

Applies to AX 2012 R2

Description:

The purpose of this article is to provide an example, how to control the data flow concerning (preaction/action).

Retailers might have to add new catalogs, Changing prices and barcodes during opening hours. If the number of changes are huge, the processing time increases and

the locking behaviour on the store database is affected.





1. Change the code, so processed always is 2 when the data is changed/added by table methods

\Classes\RetailConnActionManagement\insertAction

preactionTable.action = _type;
preactionTable.preactionDate = systemdateget();
preactionTable.preactionTime = timenow();
preactionTable.linkDown = _linkDown;
preactionTable.userId = curuserid();
preactionTable.processed = 2;


//Default: PreactionTable.processed = NoYES::No;

2. Change the default value of Processed to 2, then data inserted from a Insert_recordset will also get the value 2 in the processed field.

Code path example

Class/RetailAssortmentSchedulerTask/deltaSync

method line 106

insert_recordset preactions (action, linkDown, locationFilter, preactionDate, preactionTime, RefRecId, RefTableId)
select
action, linkDown,
filter, preactionDate,
preactionTime, RecId, assortmentTableId
from explodedInner
where
explodedInner.createdTransactionId == currentTransId &&
explodedInner.OMOperatingUnitId == omOperatingUnitRefRecId &&
explodedInner.AssortmentRecId == assortmentRefRecId;







3. Import the two SQL agent jobs attached. (the owner id is contoso\Administrator must be changed)

The two jobs are releasing the data in two steps

  • Release Preactions non A 1040 tables
- All preactions that are not in a table list will be released every minute.



  • Release Preactions A 1040 tables
- All preactions will be released in batch of 10000 every 15 minutes



4. The create action can utilize batch worker threads

If the Create actions periodic job is run in batch processing mode, it will use the Microsoft Dynamics AX batch processing framework to scale out processing by using multi-threaded logic. For this to work, you need to update the Retail Scheduler Number of documents in the batch task parameter to a larger number. For example, the number must be in the thousands instead of 0 (zero).

Hotfix needed

Create Actions job performs daily cleanup during every batch task which slows the job down considerably

KB Article Number (s) : 2995408









5. Add the CREATE ACTIONS to batch every 5-15 minutes





6. It is possible to control the A job flow when sending the data out of AX.

In the case a table has very high number of changes, it can cause locking issue on the store database.

By setting the number of Action Counter Interval, it will look only take the specified number of lines in the RetailConnActionTable





Responsible class:

\Classes\RetailConnReplicationAJob\processActions



// There is no logging for this method as this is executed in a very tight loop. It affects the run time.

[sourceCounter, upperCounter] = this.replicationCounter(_fromTableId, _schedulerSubjobTable.ActionCounterInterval);

if (sourceCounter >= upperCounter)

{

return 0;

}



currentDeletedRecordCount = 0;

currentReadRecordCount = 0;







Author: Kim Truelsen

Date...: 7/10-2014






Источник: http://blogs.msdn.com/b/axsupport/ar...tion-flow.aspx
__________________
Расскажите о новых и интересных блогах по Microsoft Dynamics, напишите личное сообщение администратору.
 

Похожие темы
Тема Автор Раздел Ответов Посл. сообщение
atinkerersnotebook: Walkthrough & Tutorial Summary Blog bot DAX Blogs 1 09.09.2013 09:11
Axilicious:Hosting custom WPF calendar control in AX 2012 Blog bot DAX Blogs 0 20.05.2013 18:11
emeadaxsupport: AX for Retail 2012 R2: Adding a Custom User Control to the POS Blog bot DAX Blogs 0 27.02.2013 07:14
emeadaxsupport: New Content for Microsoft Dynamics AX 2012 : October 2011 Blog bot DAX Blogs 0 27.10.2011 17:11
emeadaxsupport: Documentation "How to: Add a URL Drill Through Action" confusing Blog bot DAX Blogs 0 25.02.2011 16:11

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

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

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