Are Trace execution file names random?

myndeswx

Client
Регистрация
15.05.2017
Сообщения
402
Благодарностей
89
Баллы
28
Hello, I am very interested in how are trace execution files named, and if it's possible to choose the name for it?
Or maybe it's possible to make a similar log with some shared code?

Basically I need to monitor templates work externally and trace execution log file looks great!

Also, to the same question, how do you record trace execution when running template in template?
 

VladZen

Administrator
Команда форума
Регистрация
05.11.2014
Сообщения
22 216
Благодарностей
5 843
Баллы
113
Please check the info about tracing in help docs.
 
  • Спасибо
Реакции: myndeswx

myndeswx

Client
Регистрация
15.05.2017
Сообщения
402
Благодарностей
89
Баллы
28
Please check the info about tracing in help docs.
Thank you, in the docs it says-
The files are located in the user directory: C:\Users\<USER NAME>\Documents\ZennoLab\Traces and are grouped by tasks.
But it says nothing about the file name itself? I don't know if you also have it like this, but mine seem random numbers..
And what I would like to have is threadID.txt (it would be perfect to generate the file name after starting the template)
because now how could I know which file is for which thread?

Thanks!
90297
 

myndeswx

Client
Регистрация
15.05.2017
Сообщения
402
Благодарностей
89
Баллы
28
If anyone knows how to find out which file is for which thread I would appreciate it!
OR maybe someone has same solution as 'trace execution' made in shared code somehow? )
 

VladZen

Administrator
Команда форума
Регистрация
05.11.2014
Сообщения
22 216
Благодарностей
5 843
Баллы
113
File name in traces is thread id.
You can get thread ID in template by this C# code:
C#:
return Thread.CurrentThread.ManagedThreadId.ToString();
and add this to instance title:
C#:
instance.AddToTitle(Thread.CurrentThread.ManagedThreadId.ToString());
 
  • Спасибо
Реакции: myndeswx

myndeswx

Client
Регистрация
15.05.2017
Сообщения
402
Благодарностей
89
Баллы
28
Thank you, understood, it is possible to work now!

However, I really think the naming ID is deceptive because taskID as expected is unique.
And ManagedThreadId is only a number.

So if we start a template with 3 threads there will be threadIDs - 1 ,2 3
after it completes, and we run the template again with different details, threadIDs will be 1,2,3 again

Hope that makes sense, what we really need is way to get unique running thread IDs. And traces should be also saved by that unique thread ID in my opinion.
 

hesham

Пользователь
Регистрация
15.11.2018
Сообщения
120
Благодарностей
3
Баллы
18
Thank you, understood, it is possible to work now!

However, I really think the naming ID is deceptive because taskID as expected is unique.
And ManagedThreadId is only a number.

So if we start a template with 3 threads there will be threadIDs - 1 ,2 3
after it completes, and we run the template again with different details, threadIDs will be 1,2,3 again

Hope that makes sense, what we really need is way to get unique running thread IDs. And traces should be also saved by that unique thread ID in my opinion.
yes i agree with you
 
  • Спасибо
Реакции: myndeswx

Кто просматривает тему: (Всего: 1, Пользователи: 0, Гости: 1)