AXForum  
Zurück   AXForum > Microsoft Dynamics AX > DAX Blogs
All
Kennwort vergessen?
Registrieren Forum Rules Hilfe Benutzerliste Heutige Beiträge Suchen

 
 
Themen-Optionen Thema durchsuchen Ansicht
Alt 08.08.2009, 10:05   #1  
Blog bot ist offline
Blog bot
Участник
 
25.646 / 848 (80) +++++++
Registriert seit: 28.10.2006
gatesasbait: Logging independently of transaction scope by using a separate thread in Dynamics AX (deux)
Источник: http://gatesasbait.spaces.live.com/B...B9F5!498.entry
==============

 
Good evening
 
Michal Kupczyk from this thread on the Microsoft communities proposes a much better way to log independantly of transaction scope in Dynamics Ax than what I had originally proposed here. Instead of using a separate thread to log, is uses a UserConnection object.
 
In addition to being simpler, it also has the added value of working from within batches. Batches it seems don't support multithreading.
 
void method()
{
    UserConnection conn = new UserConnection();

    yourLogTable = null;
    yourLogTable.setConnection(conn);

    ttsbegin;


    [...]

    yourLogTable.Log = 'This is tts-independent log';
    yourLogTable.insert();

    if (some_error)
    {
        throw Error('Error in processing');
    }

    ttscommit;
}



Источник: http://gatesasbait.spaces.live.com/B...B9F5!498.entry
__________________
Расскажите о новых и интересных блогах по Microsoft Dynamics, напишите личное сообщение администратору.
 

Ähnliche Themen
Thema Autor Forum Antworten Letzter Beitrag
gatesasbait: Dynamics AX 2009 SSRS and SSAS Integration Tips Blog bot DAX Blogs 3 09.07.2009 13:07
gatesasbait: Logging independently of transaction scope by using a separate thread in Dynamics AX Blog bot DAX Blogs 0 27.05.2009 23:16
Developer for Microsoft Dynamics AX Certification Roadmap Blog bot DAX Blogs 1 13.05.2009 16:17
axStart: Microsoft Dynamics AX 2009 Hot Topics Web Seminar Series Blog bot DAX Blogs 0 06.08.2008 12:05
Inside Dynamics AX 4.0: Transaction Semantics Blog bot DAX Blogs 0 31.10.2007 23:40

Forumregeln
Es ist Ihnen nicht erlaubt, neue Themen zu verfassen.
Es ist Ihnen nicht erlaubt, auf Beiträge zu antworten.
Es ist Ihnen nicht erlaubt, Anhänge hochzuladen.
Es ist Ihnen nicht erlaubt, Ihre Beiträge zu bearbeiten.

BB-Code ist an.
Smileys sind an.
[IMG] Code ist an.
HTML-Code ist aus.
Gehe zu

Рейтинг@Mail.ru
Alle Zeitangaben in WEZ +3. Es ist jetzt 12:20 Uhr.
Powered by vBulletin® Version 3.8.5 (Deutsch)
Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.